-
Notifications
You must be signed in to change notification settings - Fork 3
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
Adding Intersection API Pagination #165
Adding Intersection API Pagination #165
Conversation
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.
This is looking slick! There's one blocking chore and a few suggestions. Once you decide how you want to address the chore and suggestions, I'll be pretty quick to approve this. Nice work!
...ntersection-api/api/src/main/java/us/dot/its/jpo/ode/api/accessors/IntersectionCriteria.java
Outdated
Show resolved
Hide resolved
...rsection-api/api/src/main/java/us/dot/its/jpo/ode/api/accessors/PaginatedQueryInterface.java
Outdated
Show resolved
Hide resolved
...rsection-api/api/src/main/java/us/dot/its/jpo/ode/api/accessors/PaginatedQueryInterface.java
Outdated
Show resolved
Hide resolved
...tifications/ConnectionOfTravelNotification/ConnectionOfTravelNotificationRepositoryImpl.java
Outdated
Show resolved
Hide resolved
...tifications/ConnectionOfTravelNotification/ConnectionOfTravelNotificationRepositoryImpl.java
Outdated
Show resolved
Hide resolved
...es/intersection-api/api/src/main/java/us/dot/its/jpo/ode/api/models/AggregationMetadata.java
Outdated
Show resolved
Hide resolved
...ices/intersection-api/api/src/main/java/us/dot/its/jpo/ode/api/models/AggregationResult.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.
great work!
...-api/api/src/test/java/us/dot/its/jpo/ode/api/accessorTests/PaginatedQueryInterfaceTest.java
Outdated
Show resolved
Hide resolved
...section-api/api/src/main/java/us/dot/its/jpo/ode/api/controllers/NotificationController.java
Outdated
Show resolved
Hide resolved
...tifications/ConnectionOfTravelNotification/ConnectionOfTravelNotificationRepositoryImpl.java
Outdated
Show resolved
Hide resolved
...tifications/ConnectionOfTravelNotification/ConnectionOfTravelNotificationRepositoryImpl.java
Show resolved
Hide resolved
...ices/intersection-api/api/src/main/java/us/dot/its/jpo/ode/api/models/AggregationResult.java
Outdated
Show resolved
Hide resolved
…/api/accessors/notifications/ConnectionOfTravelNotification/ConnectionOfTravelNotificationRepositoryImpl.java Co-authored-by: John-Wiens <jwiens3141@gmail.com>
…/api/accessors/notifications/ConnectionOfTravelNotification/ConnectionOfTravelNotificationRepositoryImpl.java Co-authored-by: John-Wiens <jwiens3141@gmail.com>
…-CV/jpo-cvmanager into intersection-api-pagination
b4c09e1
into
intersection-api-mongo-query-limits
PR Details
Description
This is a small sample PR, showing what an Intersection API custom pagination solution could look like. This implementation uses aggregation queries to complete the query and count in one operation. One concern was that these types of aggregation queries would not utilize indexes - I have confirmed that the compound index "intersectionID_-1_notificationGeneratedAt_-1" is utilized for aggregated queries to the CmConnectionOfTravel collection.
Here is a sample of the response to the /notifications/connection_of_travel?intersection_id=12109&size=1 endpoint (2 records exist):
How Has This Been Tested?
Types of changes
Checklist: