aerospike 1.0.1 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -0
- data/lib/aerospike/client.rb +21 -0
- data/lib/aerospike/cluster/cluster.rb +1 -1
- data/lib/aerospike/policy/write_policy.rb +1 -1
- data/lib/aerospike/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ecb7abe132e27049f98901edc5993ca316ea7dc5
|
4
|
+
data.tar.gz: f6e9938a22006bf8872c2e3f0caaeb1fd858da14
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 02a72230b8ddfb9b15ca2dea45bad841a3b387d124e98e8d7c20c33cf8f413b51e36fdb0dc76f808cc6a5f0b0e5ab7aefa8a6a86e1675b5cca75dc7cb6db983c
|
7
|
+
data.tar.gz: c7e581d770f82aec05ca052ba9e69dd15e41499f48478bc2ae325f581df1283d7895f7a9684c8fc5145ec142885409728d914e51d6d88bc968d03f96af672bf6
|
data/CHANGELOG.md
CHANGED
data/lib/aerospike/client.rb
CHANGED
@@ -53,6 +53,23 @@ module Aerospike
|
|
53
53
|
self
|
54
54
|
end
|
55
55
|
|
56
|
+
def self.new_many(hosts, options={})
|
57
|
+
# Don't initiualize, just instantiate
|
58
|
+
client = Client.allocate
|
59
|
+
|
60
|
+
client.default_policy = Policy.new
|
61
|
+
client.default_write_policy = WritePolicy.new
|
62
|
+
client.default_scan_policy = ScanPolicy.new
|
63
|
+
client.default_query_policy = QueryPolicy.new
|
64
|
+
client.default_admin_policy = QueryPolicy.new
|
65
|
+
|
66
|
+
policy = client.send(:opt_to_client_policy , options)
|
67
|
+
|
68
|
+
client.send(:cluster=, Cluster.new(policy, *hosts))
|
69
|
+
|
70
|
+
client
|
71
|
+
end
|
72
|
+
|
56
73
|
##
|
57
74
|
# Closes all client connections to database server nodes.
|
58
75
|
|
@@ -852,6 +869,10 @@ module Aerospike
|
|
852
869
|
end
|
853
870
|
end
|
854
871
|
|
872
|
+
def cluster=(cluster)
|
873
|
+
@cluster = cluster
|
874
|
+
end
|
875
|
+
|
855
876
|
def batch_execute(keys, &cmd_gen)
|
856
877
|
batch_nodes = BatchNode.generate_list(@cluster, keys)
|
857
878
|
threads = []
|
@@ -53,7 +53,7 @@ module Aerospike
|
|
53
53
|
# versions >= 3.1.4. Do not use -1 for older servers.
|
54
54
|
# 0: Default to namespace configuration variable "default-ttl" on the server.
|
55
55
|
# > 0: Actual expiration in seconds.
|
56
|
-
@expiration = opt[:expiration] || 0
|
56
|
+
@expiration = opt[:expiration] || opt[:ttl] || 0
|
57
57
|
|
58
58
|
# Send user defined key in addition to hash digest on a record put.
|
59
59
|
# The default is to send the user defined key.
|
data/lib/aerospike/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aerospike
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Khosrow Afroozeh
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-03-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: msgpack
|