zachfeldman / rubypress

Ruby interface for the WordPress XMLRPC API. Follows standard XML-RPC Documentation closely.
201 stars 55 forks source link

Request for convenience function: Fetch Posts in batches #57

Closed fwolfst closed 6 years ago

fwolfst commented 6 years ago

When client.getPosts would result in the wordpress hosting server consume more memory than currently allowed by its php-configuration, it will respond with a 500 Internal Server Error.

What I've done in my code is to accumulate all Posts, by fetching it in batches (parameters number and offset).

I'd understand if this does not fall into rubypress's responsibilities from a maintainers point of view - rubypress is a pure XML-wrapper without an additional big convenience layer on top afaict. And its doing its job great btw!

Feel free to close this issue if such functionality is not "welcome" here. Otherwise we could start speaking about implementation details.

zachfeldman commented 6 years ago

Hey @fwolfst , glad the gem is still working well for you!

I am actually totally down to add some convenience functions. Feel free to submit a pull request.