This project is archived and is in readonly mode.

#1248 ✓wontfix
Timur Vafin

Rails cache with splitting into chunks

Reported by Timur Vafin | October 22nd, 2008 @ 02:01 PM | in 2.x

This patch allows to store in the memcache very big arrays. We can store in the memcache only objects less then 1Mb, I've implement Rails.cache.fetch_splitted method which splits array in to chunks and store all data separately.


Rails.cache.fetch_splitted('Users.all', :split => 1000) do
  users = Users.all
end

I've just added write_splitted, read_splitted and fetch_splitted to the Rails::Cache::Store, so you can use splitted methods for all kind of storages.

Comments and changes to this ticket

  • Pratik

    Pratik March 6th, 2009 @ 05:00 PM

    • State changed from “new” to “wontfix”

    I am not sure this belongs in Core. But you might want to drop an email to the core mailing list. If other people find this useful, we can roll this in.

    Thanks !

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

Attachments

Pages