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
SOLR-16442: upgrade to Lucene 9.4 (do and document) #1056
Conversation
solr/test-framework/src/java/org/apache/solr/schema/SortableBinaryField.java
Outdated
Show resolved
Hide resolved
* LockFactory, int)} | ||
* LockFactory, long)} | ||
* </ul> | ||
*/ | ||
public class MMapDirectoryFactory extends StandardDirectoryFactory { | ||
private static final Logger log = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass()); | ||
boolean unmapHack; | ||
boolean preload; | ||
private int maxChunk; | ||
private long maxChunk; | ||
|
||
@Override | ||
public void init(NamedList<?> args) { | ||
super.init(args); | ||
SolrParams params = args.toSolrParams(); | ||
maxChunk = params.getInt("maxChunkSize", MMapDirectory.DEFAULT_MAX_CHUNK_SIZE); | ||
maxChunk = params.getLong("maxChunkSize", MMapDirectory.DEFAULT_MAX_CHUNK_SIZE); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Override | ||
public VectorEncoding vectorEncoding() { | ||
return VectorEncoding.BYTE; | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -522,6 +522,7 @@ private static class ReaderWrapper extends FilterLeafReader { | |||
fieldInfo.getPointIndexDimensionCount(), | |||
fieldInfo.getPointNumBytes(), | |||
fieldInfo.getVectorDimension(), | |||
fieldInfo.getVectorEncoding(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
import org.apache.lucene.search.FieldComparator; | ||
import org.apache.lucene.search.FieldComparatorSource; | ||
import org.apache.lucene.search.SortField; | ||
import org.apache.lucene.search.comparators.TermOrdValComparator; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
solr/test-framework/src/java/org/apache/solr/schema/SortableBinaryField.java
Outdated
Show resolved
Hide resolved
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. One thought on the docs, would it make sense to reference back to this PR and SOLR-16442 for the next person to see an example? For repetitive tasks, it's great to have a nice model to follow that shows all the types of changes required....
``` | ||
|
||
## Code | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets read upgrading notes provided by Lucene first; ehh?
https://lucene.apache.org/core/9_4_0/MIGRATE.html
I'd broken up the change into distinctive commits with that sort of use and potentially review ease in mind. In terms of explicitly referencing back to the PR and/or JIRA issue, I'm not so convinced on that for two reasons:
|
### `solr/licenses` update | ||
|
||
``` | ||
git rm lucene-*-9.3.0.jar.sha1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
./gradlew updateLicenses
will handle this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks! #1087 to simplify the docs (and I'll leave that PR open for a few days in case of additional documentation feedback)
(cherry picked from commit 4ab7f4b) Resolved Conflicts: solr/solr-ref-guide/antora.yml
https://issues.apache.org/jira/browse/SOLR-16442
Collaboration welcome e.g. open questions:
sortMissingLast
logic in theSortableBinaryField
class?SchemaCodecFactory
lucene93 vs. lucene94 use?