feat(search): add configurable sorting for submission results
All checks were successful
Build and Publish Docker Image / deploy (push) Successful in 1m17s
All checks were successful
Build and Publish Docker Image / deploy (push) Successful in 1m17s
Introduce a `sort` query parameter in submission search paths and pass it into store search logic. Matching results can now be ordered by `newest`, `oldest`, `score_desc`, `score_asc`, `mops_desc`, or `mops_asc`, with invalid values safely defaulting to `newest`. Update README and HTTP examples to document the new sort behavior and usage so clients can control result ordering server-side without extra post-processing.feat(search): add configurable sorting for submission results Introduce a `sort` query parameter in submission search paths and pass it into store search logic. Matching results can now be ordered by `newest`, `oldest`, `score_desc`, `score_asc`, `mops_desc`, or `mops_asc`, with invalid values safely defaulting to `newest`. Update README and HTTP examples to document the new sort behavior and usage so clients can control result ordering server-side without extra post-processing.
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
GET http://localhost:8080/api/search?text=intel&cpu=13700&thread=multi&platform=windows&intensity=10&durationSecs=30
|
||||
GET http://localhost:8080/api/search?text=intel&cpu=13700&thread=multi&platform=windows&sort=score_desc&intensity=10&durationSecs=30
|
||||
|
||||
###
|
||||
|
||||
GET http://localhost:8080/api/search?text=anonymous&thread=single&platform=linux&intensity=1&durationSecs=10
|
||||
GET http://localhost:8080/api/search?text=anonymous&thread=single&platform=linux&sort=oldest&intensity=1&durationSecs=10
|
||||
|
||||
###
|
||||
|
||||
GET http://localhost:8080/?page=1&text=lab&cpu=ryzen&thread=multi&platform=windows&intensity=10&durationSecs=20
|
||||
GET http://localhost:8080/?page=1&text=lab&cpu=ryzen&thread=multi&platform=windows&sort=mops_desc&intensity=10&durationSecs=20
|
||||
|
||||
Reference in New Issue
Block a user