-
Notifications
You must be signed in to change notification settings - Fork 5
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
registry-api needs to use the new ancestry fields #353
Comments
Specifically, members/member-of et al. need to be updated to leverage the new metadata fields. Groom ticket later |
s.high via proxy #352 @jordanpadams @tloubrieu-jpl actually, are the membership-related API endpoints even desirable in a post-ancestry-metadata world? Seems like (for example) |
@alexdunnjpl it is redundant, but the |
@jordanpadams part of the reason I ask is because I'm not sure how user-friendly the member-of and member-of-of endpoints actually are. If we're going to keep them, I'd tentatively suggest replacing them with parent-collection(s) and parent-bundle(s), respectively. I'd question whether a user ever wants to ask "what is the aggregate product one step up in the hierarchy from this product" vs "what collection(s) contain this product" |
@alexdunnjpl it's definitely feasible your recommendation is more user-friendly, but we went back and forth about this a lot, discussed with our data modeling team, and came up with these terms to try to generalize the relationship vs. using "collections"/"bundles" which are very PDS-specific. In the end, I think we just march forward with what we have, for now, and then wait for users to tell us it's wrong. I will surely expect an "I told you so" when the community comes clamoring for those endpoints. |
When done, tell @dscholes who needs that feature. |
@tloubrieu-jpl what is implementation of this ticket blocking for their needs? The functionality exists currently, and while this ticket should improve performance, the test calls I'm making against prod seem performant. |
RefLogicAny
RefLogicBundle
RefLogicCollection
RefLogicNonAggregateProduct (may need Document/Observational as well - need to check)
The following may be broken out into additional ticket(s) to avoid completion/merge delays Post-feature cleanup
|
After initial implementation, it will be necessary to design an approach for how the API-internal pagination class ( The simplest and possibly only approach would be to enforce sorting/search-after on lidvid, and communicating this requirement to users in documentation and via explanatory HTTP400 responses in the event that unexpected values are provided in the requests. |
Thanks @alexdunnjpl , I like the idea of an explanatory HTTP400: when user use search-after parameter but sort parameter is not used we should tell the user, that it is mandatory with search-after and we can suggest lidvid or timestamp (modification_date). But I don't think we made the detailed specification for the |
@tloubrieu-jpl modification to the |
Current sticky issue: Search-after pagination is hard to work into the internal pager This is complicated by the fact that any route under It might be possible to break the application of this clause by rebuilding the @al-niessner do you have any suggestions for a better approach to implementing the behaviour in the first paragraph? |
Do you still need the pagination builder? My understanding is that we no longer need to do double lookups such that the hits returned by opensearch are the hits needed. Hence, pagination builder is no longer necessary or if removing it is a pain trivial in that it simply echoes opensearch. URIParameters implements one or more of the various interfaces/facades so that if you need a new one like lidvid just use a tiny implementation of the right interface(s) and pass it around. Nothing outside of controller should know about URIParameters. Kind of the point of the interfaces. Used it heavily in double look ups to say this is the lidvid given by user but this is the lidvid that needs worked on now. The interfaces should allow one to be the user at any stage and get what is needed as though asked by the user but without URIParameters. In other words, I am not understanding the sticky bit. |
@al-niessner The sticky bit is that when the request is being processed (i.e. when the That value is then applied as a Since that instance is immutable, it's not possible to just null out the The workaround of rebuilding a new |
Yes. It is because of the double lookup. Are you getting rid of the double lookup? If you are getting rid of the double lookup, then all of the implementations of ReferencingLogic should be rewritten anyway to where that lidvid is not required. For instance, for a bundle ID wanting its collections this is being done: registry-api/service/src/main/java/gov/nasa/pds/api/registry/model/RefLogicBundle.java Lines 65 to 71 in f1f2c92
but instead of doing that search, you will want call: Line 21 in f1f2c92
You may need the id at that point depending on what is in the new field. The pagination it would create would then just be an echo of opensearch result if pagination is set correctly through whatever interface. Again, I do not understand the sticky bit. |
💡 Description
The text was updated successfully, but these errors were encountered: