Using memcached, new podcast with Andy Hunt
Please forgive the duplication in the RSS feed
Deploying Rails, now in print and shipping
Desktop GIS, Advanced Rails Recipes in print, new Podcast!
Rails New 3d Ed, and Hello Android!
New podcast: Programming Groovy
E-Mail Traffic Jam
Git, Groovy, FXRuby, and podcast.
Getting Started With XQuery now available
New Podcast: Core …
Curiously, memcached.gem is the fastest Ruby memcached client on every VM including JRuby. It is 70% faster than jruby-memcache-client , which wraps Whalin's Java client via JRuby's Java integration: memcached 1.3.3 remix-stash 1.1.3 jruby-memcache-client 1.7.0 dalli 1.1.2 user system total real set: dalli:bin 10.720000 7.250000 17.970000 ( 17.859000) set: libm:ascii …
Using memcached, new podcast with Andy Hunt
Please forgive the duplication in the RSS feed
Deploying Rails, now in print and shipping
Desktop GIS, Advanced Rails Recipes in print, new Podcast!
Rails New 3d Ed, and Hello Android!
New podcast: Programming Groovy
E-Mail Traffic Jam
Git, Groovy, FXRuby, and podcast.
Getting Started With XQuery now available
New Podcast: Core …
…MySQL, PostgreSQL, CouchDB, Redis), caching systems ( Memcached, Varnish), and queueing systems ( RabbitMQ, Beanstalkd), rather than the language- or framework-specific services of yesteryear (e.g. Erlang's Mnesia or Zope's Object Database ). There is even convergence on RPC protocols (e.g. REST, AMQP, ZeroMQ, Thrift, Protocol Buffers) and serialization protocols (e.g. XML, Yaml, JSON), making calls between apps written in different languages …
…without increasing hardware or making any type of crazy code change. Before you start looking into memcached, redis, cdns or whatever, consider HTTP caching and async DOM manipulation. Finally, note that if you can't use Varnish or Squid, you can very easily setup Rack-Cache locally and share the cache via memcached. It's also a great way to test locally. Update: CinemaTreasures was updated to use HTTP caching as described above. The hosting cost is now half of …
…pre-rendered pieces of html - red), and the number of connections our rails processes are making to the memcached server (blue).
What does this show me? I can see that memcache is doing its job - that the rails app is putting data in and getting it out. I can also see that the cache is filling up... based on the 'hockey stick' curve, I can see we have allocated enough memory to hold the data we are putting in there. If we hadn't allocated enough memory, I would visually be …
…blocked and the other fibers aren't running. Blocking operations are operations like database/ memcached queries, http requests... basically things you are probably triggering from your controllers. The good news is that the "only" problem to fix now is to avoid blocking IOs. Let's see how to do that.
Non blocking IOs/ Reactor pattern.
The reactor pattern is quite simple to understand really. The heavy work of making blocking IO calls is delegated to an external service …
Read/write through caching - If you specify a cache adapter (say memcached), ToyStore will write to memcached first and read from memcached first, populating the cache if it was not present.
Indexing - Need to do lookups by email? index :email and whenever a user is saved the user data is written to one key and the email is written as another key with a value of the user id.
Serialization ( XML and JSON )
Validations
Primary key factories
It pretty much has …
The new server was configured to use the cookie store and the others were using memcached store. It sounds stupid and it is, but it wasn't so easy to figure out at first. When I googled for the error I noticed that none of the issues had solutions, so thats why I decided to write this post.
In short, the session[:session_id] with the default cookie store passes both the session data and the session key into the cookie, and the memcached/db store's only put the session_id …
…mechanisms - see the ActiveSupport Cache documentation. One suggestion is to use Memcached if possible (e.g. on Heroku).
So What?
Patrick McKenzie's ABingo is a powerful A/B testing framework for Ruby apps.
ABingo makes it easy to define and execute experiments with multiple alternatives.
The ABingo Dashboard makes interpreting test results a breeze!
So hopefully this second post on ABingo (see here for the first post of the …