-
Notifications
You must be signed in to change notification settings - Fork 27
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
Feature: Last Modified Filter Parameter #249
Conversation
Signed-off-by: Jordan Dubrick <[email protected]>
Signed-off-by: Jordan Dubrick <[email protected]>
Signed-off-by: Jordan Dubrick <[email protected]>
Signed-off-by: Jordan Dubrick <[email protected]>
Signed-off-by: Jordan Dubrick <[email protected]>
Signed-off-by: Jordan Dubrick <[email protected]>
Signed-off-by: Jordan Dubrick <[email protected]>
Signed-off-by: Jordan Dubrick <[email protected]>
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.
Hmm that's interesting, it shouldn't be affecting the default index that is being returned at all. Are you running it with the test data? If so then it is displaying properly as far as I can tell from the screenshot: https://github.com/Jdubrick/registry-support/tree/main/tests/registry |
Oh yes, makes sense my bad. I didn't notice your fork has less stacks :) |
Signed-off-by: Jordan Dubrick <[email protected]>
Signed-off-by: Jordan Dubrick <[email protected]>
Signed-off-by: Jordan Dubrick <[email protected]>
Signed-off-by: Jordan Dubrick <[email protected]>
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 and after merging this PR I think we should create & prioritize an issue so the non-versioned stacks can also have the lastModified field with accurate data :)
Very nice feature!
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: Jdubrick, thepetk The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Thanks Fanis! FYI I opened devfile/api#1607 and will work on it once refined |
Please specify the area for this PR
What does does this PR do / why we need it:
This PR adds an additional filter parameter for stacks/samples on the
GET /v2index
endpoint.Changes made include:
last_modified.json
andlastModified
field to test datalastModified
parameterindex.json
to containlastModified
field based off of thelast_modified.json
created through registry buildindex_main.json
to ensure last modified field is added correctlyWhich issue(s) this PR fixes:
fixes devfile/api#1327
PR acceptance criteria:
Documentation (WIP)
How to test changes / Special notes to the reviewer:
FYI to reviewers: The linked issue has notes for
GET /index
andGET /v2index
. The script that generateslast_modified.json
that was merged here currently creates this file based on the updated Schema used inv2index
where there is aVersions
field that contains[]Version
. For the/index
we would need to adjust the script to add thelastModified
field to the entire stack as a whole and not just the individual stack versions.index/generator
andindex/server
GET /v2index?lastModified=2024-04-29
to see more than 1 stack that has this dateGET /v2index?lastModified=2024-04-29&name=<name>
to filter even furtherGET /v2index/all
,GET /v2index/stack
GET/v2index/sample
to observe the new field added in the response as well