Branch: refs/heads/master
Home: https://github.com/openSUSE/open-build-service
Commit: d0cc36570991d79eb64b8a91c463e8d64263f5aa
https://github.com/openSUSE/open-build-service/commit/d0cc36570991d79eb64b8a...
Author: Eduardo Navarro
Date: 2023-03-21 (Tue, 21 Mar 2023)
Changed paths:
M src/api/app/controllers/search_controller.rb
M src/api/config/options.yml.example
M src/api/spec/controllers/search_controller_spec.rb
Log Message:
-----------
Introduce limiting results for /search/... endpoints
Add the `limit_for_search_results` configuration variable, to limit the
results returned by calls to API endpoints starting by `/search/...` and
not ending in `.../id`.
Not defining the configuration variable results in not changing the
behaviour of the endpoints. That is, the results are not limited.
If the number of results surpases the value of the configuration
variable, an 403 error is thrown, with a text advising of the possible
alternatives to consider:
- retrieve only the ids by using an '/search/.../id' API endpoint, or
- reduce the number of matches of your search:
- paginating your results, through the 'limit' and 'offset' parameters, or
- adjusting your `match` expression.
Commit: b0569a3a2902a29a36d37da2c50a13ad5bcaaf0a
https://github.com/openSUSE/open-build-service/commit/b0569a3a2902a29a36d37d...
Author: Eduardo Navarro
Date: 2023-03-21 (Tue, 21 Mar 2023)
Changed paths:
M src/api/public/apidocs-new/paths/search_request.yaml
Log Message:
-----------
Document search_results_exceed_configured_limit
... 403 error with OpenAPI
Commit: 6daa0b5f3f17db4015e408054a016a4d69f884d0
https://github.com/openSUSE/open-build-service/commit/6daa0b5f3f17db4015e408...
Author: Eduardo J
Date: 2023-04-03 (Mon, 03 Apr 2023)
Changed paths:
M src/api/app/controllers/search_controller.rb
M src/api/config/options.yml.example
M src/api/public/apidocs-new/paths/search_request.yaml
M src/api/spec/controllers/search_controller_spec.rb
Log Message:
-----------
Merge pull request #13964 from eduardoj/feature/introduce_search_with_configured_limit
Introduce limiting results for /search/... endpoints
Compare: https://github.com/openSUSE/open-build-service/compare/c1bc9c7d281d...6daa0b...