Skip to content

Instantly share code, notes, and snippets.

@dvliman
Created May 7, 2013 16:12
Show Gist options
  • Save dvliman/5533852 to your computer and use it in GitHub Desktop.
Save dvliman/5533852 to your computer and use it in GitHub Desktop.
redis memory consumption for 1 million key value pairs
require 'rubygems'
require 'redis'
require 'faker'
r = Redis.new
(0..1000000).each do
name = Faker::Name.name
content = Faker::Lorem.sentence
puts "Name: #{name}, Content: #{content}"
r.set(name, content)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment