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

25 npe when featureset not exists #49

Conversation

JohannesDaniel
Copy link
Collaborator

Description

Handling non existing features, featuresets and models more gracefully by throwing a ResourceNotFoundException + proper message instead of NullPointerException.

Issues Resolved

#25

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: JohannesDaniel <[email protected]>
* IndexFeatureStore.getAndParse returns optional instead of null
* IndexFeatureStore.load, IndexFeatureStore.loadSet, IndexFeatureStore.loadModel throw ResourceNotFoundException in case of not existing resource

Signed-off-by: JohannesDaniel <[email protected]>
Signed-off-by: JohannesDaniel <[email protected]>
Copy link

@epugh epugh left a comment

Choose a reason for hiding this comment

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

One nit, but otherwise this makes sense to me.

.gitignore Outdated
@@ -46,3 +46,4 @@ eclipse-build
!/.settings/org.eclipse.jdt.ui.prefs

bin/*
.DS_Store
Copy link

Choose a reason for hiding this comment

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

Can we confirm that other OpenSearch projects have these? I know some projects instead say "put this in your global git ignore file!"

@sstults sstults merged commit 5cf3d5f into opensearch-project:main Oct 15, 2024
5 checks passed
sstults pushed a commit to sstults/opensearch-learning-to-rank-base that referenced this pull request Oct 31, 2024
Signed-off-by: JohannesDaniel <[email protected]>
Signed-off-by: Scott Stults <[email protected]>
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.

3 participants