Skip to content

Fix compilation issues after upgrade to Lucene 10#5053

Merged
cwperks merged 14 commits into
opensearch-project:mainfrom
cwperks:lucene-10
Feb 11, 2025
Merged

Fix compilation issues after upgrade to Lucene 10#5053
cwperks merged 14 commits into
opensearch-project:mainfrom
cwperks:lucene-10

Conversation

@cwperks
Copy link
Copy Markdown
Member

@cwperks cwperks commented Jan 23, 2025

Description

Adapt to Lucene 10 changes from core. Related PR: opensearch-project/OpenSearch#16366

  • Category (Enhancement, New feature, Bug fix, Test fix, Refactoring, Maintenance, Documentation)

Maintenance

Check List

  • New functionality includes testing
  • New functionality has been documented
  • New Roles/Permissions have a corresponding security dashboards plugin PR
  • API changes companion pull request created
  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
@cwperks cwperks marked this pull request as ready for review February 10, 2025 19:03
Signed-off-by: Craig Perkins <cwperx@amazon.com>
@cwperks
Copy link
Copy Markdown
Member Author

cwperks commented Feb 10, 2025

@nibix May need some insight on the failing test:

./gradlew dlicDlsFlsTest --tests FlsExistsFieldsTest.testExistsField -i

3d9abf4 is the commit that resolves compilation errors in FlsDlsFilterLeafReader for Lucene 10 upgrade

Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
reta
reta previously approved these changes Feb 10, 2025
Copy link
Copy Markdown
Collaborator

@reta reta left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks lot @cwperks !

@cwperks
Copy link
Copy Markdown
Member Author

cwperks commented Feb 10, 2025

@reta There are failing checks that I'm struggling to resolve.

The bwc test: https://github.com/opensearch-project/security/actions/runs/13251050903/job/36989972019?pr=5053

A few FLS tests: https://github.com/opensearch-project/security/actions/runs/13251050903/job/36989977628?pr=5053

Edit: BWC failures are due to running alpha1 security w/o running the respective build of the core

@reta
Copy link
Copy Markdown
Collaborator

reta commented Feb 10, 2025

The bwc test: https://github.com/opensearch-project/security/actions/runs/13251050903/job/36989972019?pr=5053

Yes, @cwperks , just looking into them as well, the first strange thing - usage of 3.0.0-SNAPSHOT artifacts, still:

 »  	at org.opensearch.bootstrap.OpenSearch.init(OpenSearch.java:185) ~[opensearch-3.0.0-SNAPSHOT.jar:3.0.0-SNAPSHOT]
»  	at org.opensearch.bootstrap.OpenSearch.execute(OpenSearch.java:172) ~[opensearch-3.0.0-SNAPSHOT.jar:3.0.0-SNAPSHOT]

Looking closely

Signed-off-by: Craig Perkins <cwperx@amazon.com>
Signed-off-by: Andriy Redko <drreta@gmail.com>
@reta
Copy link
Copy Markdown
Collaborator

reta commented Feb 11, 2025

Signed-off-by: Andriy Redko <drreta@gmail.com>
Signed-off-by: Craig Perkins <cwperx@amazon.com>
@codecov
Copy link
Copy Markdown

codecov Bot commented Feb 11, 2025

Codecov Report

Attention: Patch coverage is 33.33333% with 8 lines in your changes missing coverage. Please review.

Project coverage is 71.47%. Comparing base (2cb9f7e) to head (7921955).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
...security/configuration/DlsFlsFilterLeafReader.java 27.27% 7 Missing and 1 partial ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #5053      +/-   ##
==========================================
- Coverage   71.55%   71.47%   -0.09%     
==========================================
  Files         336      336              
  Lines       22649    22647       -2     
  Branches     3603     3603              
==========================================
- Hits        16207    16187      -20     
- Misses       4643     4660      +17     
- Partials     1799     1800       +1     
Files with missing lines Coverage Δ
.../opensearch/security/OpenSearchSecurityPlugin.java 83.79% <ø> (ø)
...ction/configupdate/ConfigUpdateRequestBuilder.java 0.00% <ø> (ø)
...y/action/onbehalf/CreateOnBehalfOfTokenAction.java 79.03% <ø> (ø)
...h/security/action/whoami/WhoAmIRequestBuilder.java 0.00% <ø> (ø)
...pensearch/security/auditlog/impl/AuditLogImpl.java 89.28% <ø> (ø)
.../security/auditlog/routing/AuditMessageRouter.java 81.60% <ø> (ø)
.../auditlog/sink/AbstractInternalOpenSearchSink.java 80.64% <ø> (ø)
...uditlog/sink/InternalOpenSearchDataStreamSink.java 84.00% <ø> (ø)
...security/auditlog/sink/InternalOpenSearchSink.java 100.00% <ø> (ø)
...pensearch/security/auditlog/sink/SinkProvider.java 83.51% <ø> (ø)
... and 28 more

... and 6 files with indirect coverage changes

@cwperks
Copy link
Copy Markdown
Member Author

cwperks commented Feb 11, 2025

Merging this with single approval to unblock the build and other components affected by security

@cwperks cwperks merged commit 63afe87 into opensearch-project:main Feb 11, 2025
@shikharj05 shikharj05 mentioned this pull request Feb 13, 2025
1 task
@nibix
Copy link
Copy Markdown
Collaborator

nibix commented Apr 1, 2025

@cwperks

May need some insight on the failing test:

Sorry, this slipped through :(

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.

4 participants