We released a gem built by us on the basis of material in production in a rather high Rails traffic application. It allows you to transparently split pages by adding current_page, per_page and total_entries as attributes of the root node of a serialized XML collection (and very fast if you use LibXML or Nokogiri, which I highly recommend the default REXML).
Here's a link to the GitHub project for PoxPaginate .
source share