redis-dump 0.3.4 → 0.3.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data.tar.gz.sig +0 -0
- data/CHANGES.txt +4 -0
- data/Rakefile +39 -28
- data/VERSION +1 -0
- data/gem-public_cert.pem +20 -0
- data/lib/redis/dump.rb +15 -17
- data/redis-dump.gemspec +0 -63
- data/try/redis.conf +35 -0
- metadata +66 -16
- metadata.gz.sig +0 -0
- data/VERSION.yml +0 -4
- data/try/redis-server.conf +0 -197
data.tar.gz.sig
ADDED
Binary file
|
data/CHANGES.txt
CHANGED
@@ -1,5 +1,9 @@
|
|
1
1
|
REDIS-DUMP, CHANGES
|
2
2
|
|
3
|
+
#### 0.3.5 (2013-02-07) ###############################
|
4
|
+
|
5
|
+
* Array#select fix for Ruby 1.8 [TIT]
|
6
|
+
|
3
7
|
#### 0.3.4 (2012-12-19) ###############################
|
4
8
|
|
5
9
|
* ADDED: Allow loading of redis dumps with binary data (-n flag) [meekmichael]
|
data/Rakefile
CHANGED
@@ -1,48 +1,59 @@
|
|
1
1
|
require "rubygems"
|
2
2
|
require "rake"
|
3
3
|
require "rake/clean"
|
4
|
-
require
|
4
|
+
require "rdoc/task"
|
5
5
|
|
6
|
-
begin
|
7
|
-
require 'hanna/rdoctask'
|
8
|
-
rescue LoadError
|
9
|
-
require 'rake/rdoctask'
|
10
|
-
end
|
11
|
-
|
12
|
-
config = YAML.load_file("VERSION.yml")
|
13
6
|
task :default => ["build"]
|
14
|
-
CLEAN.include [ 'pkg', '
|
7
|
+
CLEAN.include [ 'pkg', 'rdoc' ]
|
15
8
|
name = "redis-dump"
|
16
9
|
|
10
|
+
$:.unshift File.join(File.dirname(__FILE__), 'lib')
|
11
|
+
require "redis/dump"
|
12
|
+
version = Redis::Dump::VERSION.to_s
|
13
|
+
|
17
14
|
begin
|
18
15
|
require "jeweler"
|
19
|
-
Jeweler::Tasks.new do |
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
16
|
+
Jeweler::Tasks.new do |s|
|
17
|
+
s.version = version
|
18
|
+
s.name = name
|
19
|
+
s.summary = "Backup and restore your Redis data to and from JSON."
|
20
|
+
s.description = s.summary
|
21
|
+
s.email = "delano@solutious.com"
|
22
|
+
s.homepage = "http://github.com/delano/redis-dump"
|
23
|
+
s.authors = ["Delano Mandelbaum"]
|
24
|
+
|
25
|
+
s.add_dependency("yajl-ruby", ">= 0.1")
|
26
|
+
s.add_dependency("redis", ">= 2.0")
|
27
|
+
s.add_dependency("uri-redis", ">= 0.4.0")
|
28
|
+
s.add_dependency("drydock", ">= 0.6.9")
|
29
|
+
|
30
|
+
s.license = "MIT"
|
31
|
+
|
32
|
+
s.signing_key = File.join('/mnt/gem/', 'gem-private_key.pem')
|
33
|
+
s.cert_chain = ['gem-public_cert.pem']
|
32
34
|
end
|
33
35
|
Jeweler::GemcutterTasks.new
|
34
36
|
rescue LoadError
|
35
37
|
puts "Jeweler (or a dependency) not available. Install it with: sudo gem install jeweler"
|
36
38
|
end
|
37
39
|
|
40
|
+
require 'rake/testtask'
|
41
|
+
Rake::TestTask.new do |t|
|
42
|
+
t.libs = ["lib", "test"]
|
43
|
+
end
|
38
44
|
|
39
|
-
|
40
|
-
|
41
|
-
rdoc.rdoc_dir = "
|
42
|
-
rdoc.title = "
|
45
|
+
extra_files = %w[LICENSE.txt THANKS.txt CHANGES.txt ]
|
46
|
+
RDoc::Task.new do |rdoc|
|
47
|
+
rdoc.rdoc_dir = "rdoc"
|
48
|
+
rdoc.title = "#{name} #{version}"
|
49
|
+
rdoc.generator = 'hanna' # gem install hanna-nouveau
|
50
|
+
rdoc.main = 'README.rdoc'
|
43
51
|
rdoc.rdoc_files.include("README*")
|
44
|
-
rdoc.rdoc_files.include("
|
45
|
-
#rdoc.rdoc_files.include("bin/*.rb")
|
52
|
+
rdoc.rdoc_files.include("bin/*.rb")
|
46
53
|
rdoc.rdoc_files.include("lib/**/*.rb")
|
54
|
+
extra_files.each { |file|
|
55
|
+
rdoc.rdoc_files.include(file) if File.exists?(file)
|
56
|
+
}
|
47
57
|
end
|
48
58
|
|
59
|
+
|
data/VERSION
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
0.3.5
|
data/gem-public_cert.pem
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
-----BEGIN CERTIFICATE-----
|
2
|
+
MIIDNjCCAh6gAwIBAgIBADANBgkqhkiG9w0BAQUFADBBMQ8wDQYDVQQDDAZkZWxh
|
3
|
+
bm8xGTAXBgoJkiaJk/IsZAEZFglzb2x1dGlvdXMxEzARBgoJkiaJk/IsZAEZFgNj
|
4
|
+
b20wHhcNMTMwMjA2MTE1NzQ1WhcNMTQwMjA2MTE1NzQ1WjBBMQ8wDQYDVQQDDAZk
|
5
|
+
ZWxhbm8xGTAXBgoJkiaJk/IsZAEZFglzb2x1dGlvdXMxEzARBgoJkiaJk/IsZAEZ
|
6
|
+
FgNjb20wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDg1hMtl0XsMuUK
|
7
|
+
AKTgYWv3gjj7vuEsE2EjT+vyBg8/LpqVVwZziiaebJT9IZiQ+sCFqbiakj0b53pI
|
8
|
+
hg1yOaBEmH6/W0L7rwzqaRV9sW1eJs9JxFYQCnd67zUnzj8nnRlOjG+hhIG+Vsij
|
9
|
+
npsGbt28pefuNZJjO5q2clAlfSniIIHfIsU7/StEYu6FUGOjnwryZ0r5yJlr9RrE
|
10
|
+
Gs+q0DW8QnZ9UpAfuDFQZuIqeKQFFLE7nMmCGaA+0BN1nLl3fVHNbLHq7Avk8+Z+
|
11
|
+
ZuuvkdscbHlO/l+3xCNQ5nUnHwq0ADAbMLOlmiYYzqXoWLjmeI6me/clktJCfN2R
|
12
|
+
oZG3UQvvAgMBAAGjOTA3MAkGA1UdEwQCMAAwHQYDVR0OBBYEFMSJOEtHzE4l0azv
|
13
|
+
M0JK0kKNToK1MAsGA1UdDwQEAwIEsDANBgkqhkiG9w0BAQUFAAOCAQEAtOdE73qx
|
14
|
+
OH2ydi9oT2hS5f9G0y1Z70Tlwh+VGExyfxzVE9XwC+iPpJxNraiHYgF/9/oky7ZZ
|
15
|
+
R9q0/tJneuhAenZdiQkX7oi4O3v9wRS6YHoWBxMPFKVRLNTzvVJsbmfpCAlp5/5g
|
16
|
+
ps4wQFy5mibElGVlOobf/ghqZ25HS9J6kd0/C/ry0AUtTogsL7TxGwT4kbCx63ub
|
17
|
+
3vywEEhsJUzfd97GCABmtQfRTldX/j7F1z/5wd8p+hfdox1iibds9ZtfaZA3KzKn
|
18
|
+
kchWN9B6zg9r1XMQ8BM2Jz0XoPanPe354+lWwjpkRKbFow/ZbQHcCLCq24+N6b6g
|
19
|
+
dgKfNDzwiDpqCA==
|
20
|
+
-----END CERTIFICATE-----
|
data/lib/redis/dump.rb
CHANGED
@@ -78,7 +78,7 @@ class Redis
|
|
78
78
|
process_chunk idx, dump_keys_size do |count|
|
79
79
|
Redis::Dump.ld " dumping #{chunk_entries.size} (#{count}) from #{redis.client.id}"
|
80
80
|
output_buffer = []
|
81
|
-
chunk_entries.select
|
81
|
+
chunk_entries = chunk_entries.select do |key|
|
82
82
|
type = Redis::Dump.type(redis, key)
|
83
83
|
if self.class.with_optimizations && type == 'string'
|
84
84
|
true
|
@@ -248,23 +248,21 @@ class Redis
|
|
248
248
|
extend Redis::Dump::ClassMethods
|
249
249
|
|
250
250
|
module VERSION
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
-
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
@info ||= YAML.load_file(path)
|
251
|
+
@path = File.join(RD_HOME, 'VERSION')
|
252
|
+
class << self
|
253
|
+
attr_reader :version, :path
|
254
|
+
def version
|
255
|
+
@version || read_version
|
256
|
+
end
|
257
|
+
def read_version
|
258
|
+
return if @version
|
259
|
+
@version = File.read(path).strip!
|
260
|
+
end
|
261
|
+
def prerelease?() false end
|
262
|
+
def to_a() version.split('.') end
|
263
|
+
def to_s() version end
|
264
|
+
def inspect() version end
|
266
265
|
end
|
267
|
-
load_config
|
268
266
|
end
|
269
267
|
|
270
268
|
class Problem < RuntimeError
|
data/redis-dump.gemspec
CHANGED
@@ -1,63 +0,0 @@
|
|
1
|
-
# Generated by jeweler
|
2
|
-
# DO NOT EDIT THIS FILE DIRECTLY
|
3
|
-
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
|
-
# -*- encoding: utf-8 -*-
|
5
|
-
|
6
|
-
Gem::Specification.new do |s|
|
7
|
-
s.name = "redis-dump"
|
8
|
-
s.version = "0.3.4"
|
9
|
-
|
10
|
-
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
|
-
s.authors = ["Delano Mandelbaum"]
|
12
|
-
s.date = "2012-01-05"
|
13
|
-
s.description = "Backup and restore your Redis data to and from JSON."
|
14
|
-
s.email = "delano@solutious.com"
|
15
|
-
s.executables = ["redis-dump", "redis-load", "redis-report"]
|
16
|
-
s.extra_rdoc_files = [
|
17
|
-
"LICENSE.txt",
|
18
|
-
"README.rdoc"
|
19
|
-
]
|
20
|
-
s.files = [
|
21
|
-
"CHANGES.txt",
|
22
|
-
"LICENSE.txt",
|
23
|
-
"README.rdoc",
|
24
|
-
"Rakefile",
|
25
|
-
"VERSION.yml",
|
26
|
-
"bin/redis-dump",
|
27
|
-
"bin/redis-load",
|
28
|
-
"bin/redis-report",
|
29
|
-
"lib/redis/dump.rb",
|
30
|
-
"redis-dump.gemspec",
|
31
|
-
"try/10_redis_dump_try.rb",
|
32
|
-
"try/20_dump_specific_keys_try.rb",
|
33
|
-
"try/db0.json",
|
34
|
-
"try/redis-server.conf"
|
35
|
-
]
|
36
|
-
s.homepage = "http://github.com/delano/redis-dump"
|
37
|
-
s.require_paths = ["lib"]
|
38
|
-
s.rubyforge_project = "redis-dump"
|
39
|
-
s.rubygems_version = "1.8.10"
|
40
|
-
s.summary = "Backup and restore your Redis data to and from JSON."
|
41
|
-
|
42
|
-
if s.respond_to? :specification_version then
|
43
|
-
s.specification_version = 3
|
44
|
-
|
45
|
-
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
46
|
-
s.add_runtime_dependency(%q<yajl-ruby>, [">= 0.1"])
|
47
|
-
s.add_runtime_dependency(%q<redis>, [">= 2.0"])
|
48
|
-
s.add_runtime_dependency(%q<uri-redis>, [">= 0.4.0"])
|
49
|
-
s.add_runtime_dependency(%q<drydock>, [">= 0.6.9"])
|
50
|
-
else
|
51
|
-
s.add_dependency(%q<yajl-ruby>, [">= 0.1"])
|
52
|
-
s.add_dependency(%q<redis>, [">= 2.0"])
|
53
|
-
s.add_dependency(%q<uri-redis>, [">= 0.4.0"])
|
54
|
-
s.add_dependency(%q<drydock>, [">= 0.6.9"])
|
55
|
-
end
|
56
|
-
else
|
57
|
-
s.add_dependency(%q<yajl-ruby>, [">= 0.1"])
|
58
|
-
s.add_dependency(%q<redis>, [">= 2.0"])
|
59
|
-
s.add_dependency(%q<uri-redis>, [">= 0.4.0"])
|
60
|
-
s.add_dependency(%q<drydock>, [">= 0.6.9"])
|
61
|
-
end
|
62
|
-
end
|
63
|
-
|
data/try/redis.conf
ADDED
@@ -0,0 +1,35 @@
|
|
1
|
+
# redis-dump redis config
|
2
|
+
# 2013-02-01
|
3
|
+
|
4
|
+
dir /tmp
|
5
|
+
pidfile redisdump-test.pid
|
6
|
+
logfile redisdump-test.log
|
7
|
+
dbfilename redisdump-test.rdb
|
8
|
+
|
9
|
+
#requirepass CHANGEME
|
10
|
+
|
11
|
+
bind 127.0.0.1
|
12
|
+
port 6371
|
13
|
+
databases 16
|
14
|
+
|
15
|
+
timeout 30
|
16
|
+
daemonize yes
|
17
|
+
loglevel notice
|
18
|
+
|
19
|
+
# FOR LIGHT TRAFFIC:
|
20
|
+
#save 300 10
|
21
|
+
#save 120 100
|
22
|
+
#save 60 1000
|
23
|
+
|
24
|
+
# NOTE: we need something here to force redis to save
|
25
|
+
# when it receives a SHUTDOWN command. 157680000 is 5 yrs.
|
26
|
+
# REMOVE IT ONLY IF YOU PLAN TO ALWAYS MOVE
|
27
|
+
# AN RDB FILE INTO PLACE EVERY RESTART!
|
28
|
+
save 157680000 1
|
29
|
+
|
30
|
+
rdbcompression yes
|
31
|
+
|
32
|
+
appendonly no
|
33
|
+
|
34
|
+
# appendfsync is one of always, everysec, no
|
35
|
+
appendfsync everysec
|
metadata
CHANGED
@@ -1,19 +1,47 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: redis-dump
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.5
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- Delano Mandelbaum
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
|
-
cert_chain:
|
12
|
-
|
11
|
+
cert_chain:
|
12
|
+
- !binary |-
|
13
|
+
LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUROakNDQWg2Z0F3SUJB
|
14
|
+
Z0lCQURBTkJna3Foa2lHOXcwQkFRVUZBREJCTVE4d0RRWURWUVFEREFaa1pX
|
15
|
+
eGgKYm04eEdUQVhCZ29Ka2lhSmsvSXNaQUVaRmdsemIyeDFkR2x2ZFhNeEV6
|
16
|
+
QVJCZ29Ka2lhSmsvSXNaQUVaRmdOagpiMjB3SGhjTk1UTXdNakEyTVRFMU56
|
17
|
+
UTFXaGNOTVRRd01qQTJNVEUxTnpRMVdqQkJNUTh3RFFZRFZRUUREQVprClpX
|
18
|
+
eGhibTh4R1RBWEJnb0praWFKay9Jc1pBRVpGZ2x6YjJ4MWRHbHZkWE14RXpB
|
19
|
+
UkJnb0praWFKay9Jc1pBRVoKRmdOamIyMHdnZ0VpTUEwR0NTcUdTSWIzRFFF
|
20
|
+
QkFRVUFBNElCRHdBd2dnRUtBb0lCQVFEZzFoTXRsMFhzTXVVSwpBS1RnWVd2
|
21
|
+
M2dqajd2dUVzRTJFalQrdnlCZzgvTHBxVlZ3WnppaWFlYkpUOUlaaVErc0NG
|
22
|
+
cWJpYWtqMGI1M3BJCmhnMXlPYUJFbUg2L1cwTDdyd3pxYVJWOXNXMWVKczlK
|
23
|
+
eEZZUUNuZDY3elVuemo4bm5SbE9qRytoaElHK1ZzaWoKbnBzR2J0MjhwZWZ1
|
24
|
+
TlpKak81cTJjbEFsZlNuaUlJSGZJc1U3L1N0RVl1NkZVR09qbndyeVowcjV5
|
25
|
+
SmxyOVJyRQpHcytxMERXOFFuWjlVcEFmdURGUVp1SXFlS1FGRkxFN25NbUNH
|
26
|
+
YUErMEJOMW5MbDNmVkhOYkxIcTdBdms4K1orClp1dXZrZHNjYkhsTy9sKzN4
|
27
|
+
Q05RNW5Vbkh3cTBBREFiTUxPbG1pWVl6cVhvV0xqbWVJNm1lL2Nsa3RKQ2ZO
|
28
|
+
MlIKb1pHM1VRdnZBZ01CQUFHak9UQTNNQWtHQTFVZEV3UUNNQUF3SFFZRFZS
|
29
|
+
ME9CQllFRk1TSk9FdEh6RTRsMGF6dgpNMEpLMGtLTlRvSzFNQXNHQTFVZER3
|
30
|
+
UUVBd0lFc0RBTkJna3Foa2lHOXcwQkFRVUZBQU9DQVFFQXRPZEU3M3F4Ck9I
|
31
|
+
MnlkaTlvVDJoUzVmOUcweTFaNzBUbHdoK1ZHRXh5Znh6VkU5WHdDK2lQcEp4
|
32
|
+
TnJhaUhZZ0YvOS9va3k3WloKUjlxMC90Sm5ldWhBZW5aZGlRa1g3b2k0TzN2
|
33
|
+
OXdSUzZZSG9XQnhNUEZLVlJMTlR6dlZKc2JtZnBDQWxwNS81ZwpwczR3UUZ5
|
34
|
+
NW1pYkVsR1ZsT29iZi9naHFaMjVIUzlKNmtkMC9DL3J5MEFVdFRvZ3NMN1R4
|
35
|
+
R3dUNGtiQ3g2M3ViCjN2eXdFRWhzSlV6ZmQ5N0dDQUJtdFFmUlRsZFgvajdG
|
36
|
+
MXovNXdkOHAraGZkb3gxaWliZHM5WnRmYVpBM0t6S24Ka2NoV045QjZ6Zzly
|
37
|
+
MVhNUThCTTJKejBYb1BhblBlMzU0K2xXd2pwa1JLYkZvdy9aYlFIY0NMQ3Ey
|
38
|
+
NCtONmI2ZwpkZ0tmTkR6d2lEcHFDQT09Ci0tLS0tRU5EIENFUlRJRklDQVRF
|
39
|
+
LS0tLS0K
|
40
|
+
date: 2013-02-07 00:00:00.000000000 Z
|
13
41
|
dependencies:
|
14
42
|
- !ruby/object:Gem::Dependency
|
15
43
|
name: yajl-ruby
|
16
|
-
requirement:
|
44
|
+
requirement: !ruby/object:Gem::Requirement
|
17
45
|
none: false
|
18
46
|
requirements:
|
19
47
|
- - ! '>='
|
@@ -21,10 +49,15 @@ dependencies:
|
|
21
49
|
version: '0.1'
|
22
50
|
type: :runtime
|
23
51
|
prerelease: false
|
24
|
-
version_requirements:
|
52
|
+
version_requirements: !ruby/object:Gem::Requirement
|
53
|
+
none: false
|
54
|
+
requirements:
|
55
|
+
- - ! '>='
|
56
|
+
- !ruby/object:Gem::Version
|
57
|
+
version: '0.1'
|
25
58
|
- !ruby/object:Gem::Dependency
|
26
59
|
name: redis
|
27
|
-
requirement:
|
60
|
+
requirement: !ruby/object:Gem::Requirement
|
28
61
|
none: false
|
29
62
|
requirements:
|
30
63
|
- - ! '>='
|
@@ -32,10 +65,15 @@ dependencies:
|
|
32
65
|
version: '2.0'
|
33
66
|
type: :runtime
|
34
67
|
prerelease: false
|
35
|
-
version_requirements:
|
68
|
+
version_requirements: !ruby/object:Gem::Requirement
|
69
|
+
none: false
|
70
|
+
requirements:
|
71
|
+
- - ! '>='
|
72
|
+
- !ruby/object:Gem::Version
|
73
|
+
version: '2.0'
|
36
74
|
- !ruby/object:Gem::Dependency
|
37
75
|
name: uri-redis
|
38
|
-
requirement:
|
76
|
+
requirement: !ruby/object:Gem::Requirement
|
39
77
|
none: false
|
40
78
|
requirements:
|
41
79
|
- - ! '>='
|
@@ -43,10 +81,15 @@ dependencies:
|
|
43
81
|
version: 0.4.0
|
44
82
|
type: :runtime
|
45
83
|
prerelease: false
|
46
|
-
version_requirements:
|
84
|
+
version_requirements: !ruby/object:Gem::Requirement
|
85
|
+
none: false
|
86
|
+
requirements:
|
87
|
+
- - ! '>='
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: 0.4.0
|
47
90
|
- !ruby/object:Gem::Dependency
|
48
91
|
name: drydock
|
49
|
-
requirement:
|
92
|
+
requirement: !ruby/object:Gem::Requirement
|
50
93
|
none: false
|
51
94
|
requirements:
|
52
95
|
- - ! '>='
|
@@ -54,7 +97,12 @@ dependencies:
|
|
54
97
|
version: 0.6.9
|
55
98
|
type: :runtime
|
56
99
|
prerelease: false
|
57
|
-
version_requirements:
|
100
|
+
version_requirements: !ruby/object:Gem::Requirement
|
101
|
+
none: false
|
102
|
+
requirements:
|
103
|
+
- - ! '>='
|
104
|
+
- !ruby/object:Gem::Version
|
105
|
+
version: 0.6.9
|
58
106
|
description: Backup and restore your Redis data to and from JSON.
|
59
107
|
email: delano@solutious.com
|
60
108
|
executables:
|
@@ -70,18 +118,20 @@ files:
|
|
70
118
|
- LICENSE.txt
|
71
119
|
- README.rdoc
|
72
120
|
- Rakefile
|
73
|
-
- VERSION
|
121
|
+
- VERSION
|
74
122
|
- bin/redis-dump
|
75
123
|
- bin/redis-load
|
76
124
|
- bin/redis-report
|
125
|
+
- gem-public_cert.pem
|
77
126
|
- lib/redis/dump.rb
|
78
127
|
- redis-dump.gemspec
|
79
128
|
- try/10_redis_dump_try.rb
|
80
129
|
- try/20_dump_specific_keys_try.rb
|
81
130
|
- try/db0.json
|
82
|
-
- try/redis
|
131
|
+
- try/redis.conf
|
83
132
|
homepage: http://github.com/delano/redis-dump
|
84
|
-
licenses:
|
133
|
+
licenses:
|
134
|
+
- MIT
|
85
135
|
post_install_message:
|
86
136
|
rdoc_options: []
|
87
137
|
require_paths:
|
@@ -99,8 +149,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
99
149
|
- !ruby/object:Gem::Version
|
100
150
|
version: '0'
|
101
151
|
requirements: []
|
102
|
-
rubyforge_project:
|
103
|
-
rubygems_version: 1.8.
|
152
|
+
rubyforge_project:
|
153
|
+
rubygems_version: 1.8.25
|
104
154
|
signing_key:
|
105
155
|
specification_version: 3
|
106
156
|
summary: Backup and restore your Redis data to and from JSON.
|
metadata.gz.sig
ADDED
Binary file
|
data/VERSION.yml
DELETED
data/try/redis-server.conf
DELETED
@@ -1,197 +0,0 @@
|
|
1
|
-
# REDIS-DUMP TEST CONFIG -- 2010-11-15
|
2
|
-
|
3
|
-
# Usage:
|
4
|
-
#
|
5
|
-
# $ redis-server try/redis-server.conf
|
6
|
-
|
7
|
-
dir /tmp
|
8
|
-
|
9
|
-
pidfile redisdump-test.pid
|
10
|
-
logfile redisdump-test.log
|
11
|
-
dbfilename redisdump-test.rdb
|
12
|
-
|
13
|
-
port 6371
|
14
|
-
bind 127.0.0.1
|
15
|
-
daemonize yes
|
16
|
-
|
17
|
-
timeout 300
|
18
|
-
|
19
|
-
#loglevel debug
|
20
|
-
#loglevel verbose
|
21
|
-
loglevel warning
|
22
|
-
|
23
|
-
databases 16
|
24
|
-
|
25
|
-
save 900 100
|
26
|
-
save 300 5000
|
27
|
-
|
28
|
-
|
29
|
-
rdbcompression yes
|
30
|
-
|
31
|
-
# requirepass foobared
|
32
|
-
# maxclients 0
|
33
|
-
|
34
|
-
appendonly no
|
35
|
-
appendfilename redisdump-test.aof
|
36
|
-
|
37
|
-
# TODO: Consider having separate configs when the usecase for Redis
|
38
|
-
# changes. For example, one for production, another for batch processing.
|
39
|
-
#
|
40
|
-
# Nothing is changed from here on out:
|
41
|
-
|
42
|
-
################################## INCLUDES ###################################
|
43
|
-
|
44
|
-
# Include one or more other config files here. This is useful if you
|
45
|
-
# have a standard template that goes to all redis server but also need
|
46
|
-
# to customize a few per-server settings. Include files can include
|
47
|
-
# other files, so use this wisely.
|
48
|
-
#
|
49
|
-
# include /path/to/local.conf
|
50
|
-
# include /path/to/other.conf
|
51
|
-
|
52
|
-
################################# REPLICATION #################################
|
53
|
-
|
54
|
-
# Master-Slave replication. Use slaveof to make a Redis instance a copy of
|
55
|
-
# another Redis server. Note that the configuration is local to the slave
|
56
|
-
# so for example it is possible to configure the slave to save the DB with a
|
57
|
-
# different interval, or to listen to another port, and so on.
|
58
|
-
#
|
59
|
-
# slaveof <masterip> <masterport>
|
60
|
-
|
61
|
-
# If the master is password protected (using the "requirepass" configuration
|
62
|
-
# directive below) it is possible to tell the slave to authenticate before
|
63
|
-
# starting the replication synchronization process, otherwise the master will
|
64
|
-
# refuse the slave request.
|
65
|
-
#
|
66
|
-
# masterauth <master-password>
|
67
|
-
|
68
|
-
|
69
|
-
# The fsync() call tells the Operating System to actually write data on disk
|
70
|
-
# instead to wait for more data in the output buffer. Some OS will really flush
|
71
|
-
# data on disk, some other OS will just try to do it ASAP.
|
72
|
-
#
|
73
|
-
# Redis supports three different modes:
|
74
|
-
#
|
75
|
-
# no: don't fsync, just let the OS flush the data when it wants. Faster.
|
76
|
-
# always: fsync after every write to the append only log . Slow, Safest.
|
77
|
-
# everysec: fsync only if one second passed since the last fsync. Compromise.
|
78
|
-
#
|
79
|
-
# The default is "everysec" that's usually the right compromise between
|
80
|
-
# speed and data safety. It's up to you to understand if you can relax this to
|
81
|
-
# "no" that will will let the operating system flush the output buffer when
|
82
|
-
# it wants, for better performances (but if you can live with the idea of
|
83
|
-
# some data loss consider the default persistence mode that's snapshotting),
|
84
|
-
# or on the contrary, use "always" that's very slow but a bit safer than
|
85
|
-
# everysec.
|
86
|
-
#
|
87
|
-
# If unsure, use "everysec".
|
88
|
-
|
89
|
-
# appendfsync always
|
90
|
-
appendfsync everysec
|
91
|
-
# appendfsync no
|
92
|
-
|
93
|
-
################################ VIRTUAL MEMORY ###############################
|
94
|
-
|
95
|
-
# Virtual Memory allows Redis to work with datasets bigger than the actual
|
96
|
-
# amount of RAM needed to hold the whole dataset in memory.
|
97
|
-
# In order to do so very used keys are taken in memory while the other keys
|
98
|
-
# are swapped into a swap file, similarly to what operating systems do
|
99
|
-
# with memory pages.
|
100
|
-
#
|
101
|
-
# To enable VM just set 'vm-enabled' to yes, and set the following three
|
102
|
-
# VM parameters accordingly to your needs.
|
103
|
-
|
104
|
-
vm-enabled no
|
105
|
-
# vm-enabled yes
|
106
|
-
|
107
|
-
# This is the path of the Redis swap file. As you can guess, swap files
|
108
|
-
# can't be shared by different Redis instances, so make sure to use a swap
|
109
|
-
# file for every redis process you are running. Redis will complain if the
|
110
|
-
# swap file is already in use.
|
111
|
-
#
|
112
|
-
# The best kind of storage for the Redis swap file (that's accessed at random)
|
113
|
-
# is a Solid State Disk (SSD).
|
114
|
-
#
|
115
|
-
# *** WARNING *** if you are using a shared hosting the default of putting
|
116
|
-
# the swap file under /tmp is not secure. Create a dir with access granted
|
117
|
-
# only to Redis user and configure Redis to create the swap file there.
|
118
|
-
vm-swap-file /tmp/redis.swap
|
119
|
-
|
120
|
-
# vm-max-memory configures the VM to use at max the specified amount of
|
121
|
-
# RAM. Everything that deos not fit will be swapped on disk *if* possible, that
|
122
|
-
# is, if there is still enough contiguous space in the swap file.
|
123
|
-
#
|
124
|
-
# With vm-max-memory 0 the system will swap everything it can. Not a good
|
125
|
-
# default, just specify the max amount of RAM you can in bytes, but it's
|
126
|
-
# better to leave some margin. For instance specify an amount of RAM
|
127
|
-
# that's more or less between 60 and 80% of your free RAM.
|
128
|
-
vm-max-memory 0
|
129
|
-
|
130
|
-
# Redis swap files is split into pages. An object can be saved using multiple
|
131
|
-
# contiguous pages, but pages can't be shared between different objects.
|
132
|
-
# So if your page is too big, small objects swapped out on disk will waste
|
133
|
-
# a lot of space. If you page is too small, there is less space in the swap
|
134
|
-
# file (assuming you configured the same number of total swap file pages).
|
135
|
-
#
|
136
|
-
# If you use a lot of small objects, use a page size of 64 or 32 bytes.
|
137
|
-
# If you use a lot of big objects, use a bigger page size.
|
138
|
-
# If unsure, use the default :)
|
139
|
-
vm-page-size 32
|
140
|
-
|
141
|
-
# Number of total memory pages in the swap file.
|
142
|
-
# Given that the page table (a bitmap of free/used pages) is taken in memory,
|
143
|
-
# every 8 pages on disk will consume 1 byte of RAM.
|
144
|
-
#
|
145
|
-
# The total swap size is vm-page-size * vm-pages
|
146
|
-
#
|
147
|
-
# With the default of 32-bytes memory pages and 134217728 pages Redis will
|
148
|
-
# use a 4 GB swap file, that will use 16 MB of RAM for the page table.
|
149
|
-
#
|
150
|
-
# It's better to use the smallest acceptable value for your application,
|
151
|
-
# but the default is large in order to work in most conditions.
|
152
|
-
vm-pages 134217728
|
153
|
-
|
154
|
-
# Max number of VM I/O threads running at the same time.
|
155
|
-
# This threads are used to read/write data from/to swap file, since they
|
156
|
-
# also encode and decode objects from disk to memory or the reverse, a bigger
|
157
|
-
# number of threads can help with big objects even if they can't help with
|
158
|
-
# I/O itself as the physical device may not be able to couple with many
|
159
|
-
# reads/writes operations at the same time.
|
160
|
-
#
|
161
|
-
# The special value of 0 turn off threaded I/O and enables the blocking
|
162
|
-
# Virtual Memory implementation.
|
163
|
-
vm-max-threads 4
|
164
|
-
|
165
|
-
############################### ADVANCED CONFIG ###############################
|
166
|
-
|
167
|
-
# Glue small output buffers together in order to send small replies in a
|
168
|
-
# single TCP packet. Uses a bit more CPU but most of the times it is a win
|
169
|
-
# in terms of number of queries per second. Use 'yes' if unsure.
|
170
|
-
glueoutputbuf yes
|
171
|
-
|
172
|
-
# Hashes are encoded in a special way (much more memory efficient) when they
|
173
|
-
# have at max a given numer of elements, and the biggest element does not
|
174
|
-
# exceed a given threshold. You can configure this limits with the following
|
175
|
-
# configuration directives.
|
176
|
-
hash-max-zipmap-entries 64
|
177
|
-
hash-max-zipmap-value 512
|
178
|
-
|
179
|
-
# Active rehashing uses 1 millisecond every 100 milliseconds of CPU time in
|
180
|
-
# order to help rehashing the main Redis hash table (the one mapping top-level
|
181
|
-
# keys to values). The hash table implementation redis uses (see dict.c)
|
182
|
-
# performs a lazy rehashing: the more operation you run into an hash table
|
183
|
-
# that is rhashing, the more rehashing "steps" are performed, so if the
|
184
|
-
# server is idle the rehashing is never complete and some more memory is used
|
185
|
-
# by the hash table.
|
186
|
-
#
|
187
|
-
# The default is to use this millisecond 10 times every second in order to
|
188
|
-
# active rehashing the main dictionaries, freeing memory when possible.
|
189
|
-
#
|
190
|
-
# If unsure:
|
191
|
-
# use "activerehashing no" if you have hard latency requirements and it is
|
192
|
-
# not a good thing in your environment that Redis can reply form time to time
|
193
|
-
# to queries with 2 milliseconds delay.
|
194
|
-
#
|
195
|
-
# use "activerehashing yes" if you don't have such hard requirements but
|
196
|
-
# want to free memory asap when possible.
|
197
|
-
activerehashing yes
|