Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove ORM 6.2 upgrade job since 7.0 targets 6.3+ #3746

Merged

Conversation

marko-bekhta
Copy link
Member

I'll look into other failed branches, so opening this as a draft for now

@hibernate-github-bot
Copy link

hibernate-github-bot bot commented Sep 25, 2023

Thanks for your pull request!

This pull request does not follow the contribution rules. Could you have a look?

❌ All commit messages should start with a JIRA issue key matching pattern HSEARCH-\d+
    ↳ Offending commits: [3e61ab5, 016a53c]

› This message was automatically generated.

- since this bug is not fixed we constantly need to bump the version and also the bug is in their main branch leading to failures in upgrade test runs. We are subscribed to the issue, so once it is resolved, we can change the condition.
@marko-bekhta
Copy link
Member Author

The Elasticsearch build failed with the usual error "not supporting extreme scaled numeric values" as that bug is not fixed yet.
As for the Lucene build... the error was in the area we've changed to not rely on NO_MORE_ORDS constant (or whatever the name for it was ...) but I cannot reproduce this locally 🤷🏻‍♂️ 😔

@marko-bekhta marko-bekhta marked this pull request as ready for review September 25, 2023 07:38
@yrodiere
Copy link
Member

yrodiere commented Sep 25, 2023

As for the Lucene build... the error was in the area we've changed to not rely on NO_MORE_ORDS constant (or whatever the name for it was ...) but I cannot reproduce this locally 🤷🏻‍♂️ 😔

We're talking about this one, I assume:

[ERROR] Tests run: 12, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.560 s <<< FAILURE! -- in org.hibernate.search.integrationtest.showcase.library.LibraryShowcaseSearchIT
[ERROR] org.hibernate.search.integrationtest.showcase.library.LibraryShowcaseSearchIT.searchFaceted -- Time elapsed: 0.031 s <<< ERROR!
java.lang.IndexOutOfBoundsException
	at java.base/java.nio.Buffer.checkIndex(Buffer.java:743)
	at java.base/java.nio.DirectByteBuffer.get(DirectByteBuffer.java:339)
	at org.apache.lucene.store.ByteBufferGuard.getByte(ByteBufferGuard.java:115)
	at org.apache.lucene.store.ByteBufferIndexInput$SingleBufferImpl.readByte(ByteBufferIndexInput.java:564)
	at org.apache.lucene.util.packed.DirectReader$DirectPackedReader2.get(DirectReader.java:222)
	at org.apache.lucene.codecs.lucene90.Lucene90DocValuesProducer$25.nextOrd(Lucene90DocValuesProducer.java:1468)
	at org.hibernate.search.backend.lucene.lowlevel.docvalues.impl.TextMultiValues$DocValuesTextMultiValues.nextOrd(TextMultiValues.java:122)
	at org.hibernate.search.backend.lucene.lowlevel.facet.impl.TextMultiValueFacetCounts.countOneSegment(TextMultiValueFacetCounts.java:184)
	at org.hibernate.search.backend.lucene.lowlevel.facet.impl.TextMultiValueFacetCounts.count(TextMultiValueFacetCounts.java:246)
	at org.hibernate.search.backend.lucene.lowlevel.facet.impl.TextMultiValueFacetCounts.<init>(TextMultiValueFacetCounts.java:59)
	at org.hibernate.search.backend.lucene.types.aggregation.impl.LuceneTextTermsAggregation.getTopChildren(LuceneTextTermsAggregation.java:51)
	at org.hibernate.search.backend.lucene.types.aggregation.impl.AbstractLuceneFacetsBasedTermsAggregation.getTopBuckets(AbstractLuceneFacetsBasedTermsAggregation.java:125)
	at org.hibernate.search.backend.lucene.types.aggregation.impl.AbstractLuceneFacetsBasedTermsAggregation.extract(AbstractLuceneFacetsBasedTermsAggregation.java:65)
	at org.hibernate.search.backend.lucene.types.aggregation.impl.AbstractLuceneFacetsBasedTermsAggregation.extract(AbstractLuceneFacetsBasedTermsAggregation.java:39)
	at org.hibernate.search.backend.lucene.search.query.impl.LuceneExtractableSearchResult.extractAggregations(LuceneExtractableSearchResult.java:130)
	at org.hibernate.search.backend.lucene.search.query.impl.LuceneExtractableSearchResult.extract(LuceneExtractableSearchResult.java:77)
	at org.hibernate.search.backend.lucene.search.query.impl.LuceneExtractableSearchResult.extract(LuceneExtractableSearchResult.java:58)
	at org.hibernate.search.backend.lucene.search.query.impl.LuceneSearcherImpl.search(LuceneSearcherImpl.java:75)
	at org.hibernate.search.backend.lucene.search.query.impl.LuceneSearcherImpl.search(LuceneSearcherImpl.java:32)
	at org.hibernate.search.backend.lucene.work.impl.SearchWork.execute(SearchWork.java:41)

This could be a regression in Lucene 10.0.0-SNAPSHOT, especially since there's been a change in this class recently: apache/lucene@d633c9b . Ironically, the problem that patch fixed looks a lot like the stacktrace above.

This could be also a bug in our code that happens only with a certain index fragment topology (documents spear among fragments a certain way), which could make the bug timing-sensitive. But I'd save that theory for last, because that will be very difficult to debug.

Other theory: we don't go through docvalues correctly. I see references to DocIdSetIterator.NO_MORE_DOCS throughout the code, in particularly there:

for ( int doc = docs.nextDoc(); doc != DocIdSetIterator.NO_MORE_DOCS; doc = docs.nextDoc() ) {

So I'd say https://hibernate.atlassian.net/browse/HSEARCH-4939 was not completely addressed. I'll reopen it. Could you please have another look? => Ignore this, NO_MORE_DOCS is not NO_MORE_ORDS.

@yrodiere
Copy link
Member

Other theory: we don't go through docvalues correctly. I see references to DocIdSetIterator.NO_MORE_DOCS throughout the code, in particularly there:

for ( int doc = docs.nextDoc(); doc != DocIdSetIterator.NO_MORE_DOCS; doc = docs.nextDoc() ) {

Please ignore this, I obviously can't read 😓 It's a different constant.

@marko-bekhta
Copy link
Member Author

Mooooonday 😃
yeah, that's the failed test.... I've tried to run the tests in this module a few times and also the tests from TCK (just in case) but they've passed all the attempts 😔

@yrodiere
Copy link
Member

yrodiere commented Sep 25, 2023

I think there might be a bug there (or in code that relies on this):

if ( childDocsWithValues.nextChild() != DocIdSetIterator.NO_MORE_DOCS ) {
nextOrd = values.nextOrd();
return true;
}

I'll send a PR.

See https://hibernate.atlassian.net/browse/HSEARCH-4969

@sonarcloud
Copy link

sonarcloud bot commented Sep 25, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@yrodiere yrodiere merged commit bb50fb9 into hibernate:main Sep 25, 2023
9 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants