Skip to content
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

Permit to set a maximum page_size #70

Closed
xdmx opened this issue May 9, 2014 · 2 comments
Closed

Permit to set a maximum page_size #70

xdmx opened this issue May 9, 2014 · 2 comments

Comments

@xdmx
Copy link

xdmx commented May 9, 2014

It would be very useful to set a maximum page_size that is allowed, especially for public APIs it would be very bad of having one loading 1000000 records.

Something like kaminari's .max_page_size. Setting it to a value it will load only up to that amount of records per page and no more.

p.s. awesome gem!

@GavinJoyce
Copy link
Contributor

Thanks, this would be a nice addition.

It should be easy to add a config option to https://github.com/RestPack/restpack_serializer/blob/master/lib/restpack_serializer/configuration.rb

@GavinJoyce
Copy link
Contributor

Based on this conversation, we plan to document use kaminari's configuration options for this:

#89 (comment)
#90

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants