aerospike 1.0.6 → 1.0.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +20 -0
- data/lib/aerospike/client.rb +3 -7
- data/lib/aerospike/command/admin_command.rb +0 -7
- data/lib/aerospike/command/batch_command.rb +1 -8
- data/lib/aerospike/ldt/large.rb +0 -12
- data/lib/aerospike/ldt/large_map.rb +8 -0
- data/lib/aerospike/ldt/large_set.rb +8 -0
- data/lib/aerospike/ldt/large_stack.rb +8 -0
- data/lib/aerospike/result_code.rb +28 -3
- 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: bd28752a0e027fc7dd83f1d37c9c3e0d4f1c41f6
|
4
|
+
data.tar.gz: 716b795cf8408e206b9e431d2279953881f4e803
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c4a311ce2f51860521457ab8a95189cc1e9f374d67e9f4ac6ca737b50c58f1d5a2ad57716bde92ab0cf9444d7d89d0259f19427924a12c2eb9e30297cf201fee
|
7
|
+
data.tar.gz: 2b9f9e709e15e14846ee131af2273570556cc4a70c8e92e8bbdcf9b3b2a9fe10583872aa7913fb6b5b2bc043c1bc6b454256183058162c985e7626b49d88ed76
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,23 @@
|
|
1
|
+
## May 15 2015 (1.0.7)
|
2
|
+
|
3
|
+
Minor fixes.
|
4
|
+
|
5
|
+
NOTICE: All LDTs on server other than LLIST have been deprecated, and will be removed in the future. As Such, all API regarding those features are considered deprecated and will be removed in tandem.
|
6
|
+
|
7
|
+
* **Improvements**:
|
8
|
+
|
9
|
+
* Removed workaround in `BatchGet`. Bins are filtered on server now.
|
10
|
+
|
11
|
+
* Added New Error Codes. Fixes Issues #17 and #18
|
12
|
+
|
13
|
+
* Node validator won't lookup hostsif an IP is passed as a seed to it.
|
14
|
+
|
15
|
+
* ** Other Changes **
|
16
|
+
|
17
|
+
* Removed deprecated `ReplaceRoles()` method.
|
18
|
+
|
19
|
+
* Removed deprecated `SetCapacity()` and `GetCapacity()` methods for LDTs.
|
20
|
+
|
1
21
|
## April 2 2015 (1.0.6)
|
2
22
|
|
3
23
|
Minor fixes.
|
data/lib/aerospike/client.rb
CHANGED
@@ -375,6 +375,7 @@ module Aerospike
|
|
375
375
|
# within a single bin.
|
376
376
|
#
|
377
377
|
# This method is only supported by Aerospike 3 servers.
|
378
|
+
# DEPRECATED. This method will be removed from the client in the future.
|
378
379
|
def get_large_map(key, bin_name, user_module=nil, options={})
|
379
380
|
LargeMap.new(self, opt_to_write_policy(options), key, bin_name, user_module)
|
380
381
|
end
|
@@ -383,6 +384,7 @@ module Aerospike
|
|
383
384
|
# within a single bin.
|
384
385
|
#
|
385
386
|
# This method is only supported by Aerospike 3 servers.
|
387
|
+
# DEPRECATED. This method will be removed from the client in the future.
|
386
388
|
def get_large_set(key, bin_name, user_module=nil, options={})
|
387
389
|
LargeSet.new(self, opt_to_write_policy(options), key, bin_name, user_module)
|
388
390
|
end
|
@@ -391,6 +393,7 @@ module Aerospike
|
|
391
393
|
# within a single bin.
|
392
394
|
#
|
393
395
|
# This method is only supported by Aerospike 3 servers.
|
396
|
+
# DEPRECATED. This method will be removed from the client in the future.
|
394
397
|
def get_large_stack(key, bin_name, user_module=nil, options={})
|
395
398
|
LargeStack.new(self, opt_to_write_policy(options), key, bin_name, user_module)
|
396
399
|
end
|
@@ -806,13 +809,6 @@ module Aerospike
|
|
806
809
|
command.revoke_roles(@cluster, policy, user, roles)
|
807
810
|
end
|
808
811
|
|
809
|
-
# Replace user's list of roles.
|
810
|
-
def replace_roles(user, roles, options={})
|
811
|
-
policy = opt_to_admin_policy(options)
|
812
|
-
command = AdminCommand.new
|
813
|
-
command.replace_roles(@cluster, policy, user, roles)
|
814
|
-
end
|
815
|
-
|
816
812
|
# Retrieve roles for a given user.
|
817
813
|
def query_user(user, options={})
|
818
814
|
policy = opt_to_admin_policy(options)
|
@@ -119,13 +119,6 @@ module Aerospike
|
|
119
119
|
execute_command(cluster, policy)
|
120
120
|
end
|
121
121
|
|
122
|
-
def replace_roles(cluster, policy, user, roles)
|
123
|
-
write_header(REPLACE_ROLES, 2)
|
124
|
-
write_field_str(USER, user)
|
125
|
-
write_roles(roles)
|
126
|
-
execute_command(cluster, policy)
|
127
|
-
end
|
128
|
-
|
129
122
|
def query_user(cluster, policy, user)
|
130
123
|
# TODO: Remove the workaround in the future
|
131
124
|
sleep(0.010)
|
@@ -112,14 +112,7 @@ module Aerospike
|
|
112
112
|
read_bytes(particle_bytes_size)
|
113
113
|
value = Aerospike.bytes_to_particle(particle_type, @data_buffer, 0, particle_bytes_size)
|
114
114
|
|
115
|
-
|
116
|
-
# the bins are requested. We have to filter it on the client side.
|
117
|
-
# TODO: Filter batch bins on server!
|
118
|
-
# if !@bin_names || @bin_names.any?{|bn| bn == name}
|
119
|
-
# if !@bin_names || (@bin_names == []) || @bin_names.any?{|bn| bn == name}
|
120
|
-
if !@bin_names || (@bin_names.empty?) || @bin_names.any?{|bn| bn == name}
|
121
|
-
bins[name] = value
|
122
|
-
end
|
115
|
+
bins[name] = value
|
123
116
|
|
124
117
|
i = i.succ
|
125
118
|
end
|
data/lib/aerospike/ldt/large.rb
CHANGED
@@ -47,18 +47,6 @@ module Aerospike
|
|
47
47
|
@client.execute_udf(@key, @PACKAGE_NAME, 'get_config', [@bin_name], @policy)
|
48
48
|
end
|
49
49
|
|
50
|
-
# Set maximum number of entries in the object.
|
51
|
-
#
|
52
|
-
# capacity max entries in set
|
53
|
-
def capacity=(capacity)
|
54
|
-
@client.execute_udf(@key, @PACKAGE_NAME, 'set_capacity', [@bin_name, capacity], @policy)
|
55
|
-
end
|
56
|
-
|
57
|
-
# Return maximum number of entries in the object.
|
58
|
-
def capacity
|
59
|
-
@client.execute_udf(@key, @PACKAGE_NAME, 'get_capacity', [@bin_name], @policy)
|
60
|
-
end
|
61
|
-
|
62
50
|
# Return list of all objects on the stack.
|
63
51
|
def scan
|
64
52
|
@client.execute_udf(@key, @PACKAGE_NAME, 'scan', [@bin_name], @policy)
|
@@ -14,6 +14,14 @@
|
|
14
14
|
# License for the specific language governing permissions and limitations under
|
15
15
|
# the License.
|
16
16
|
|
17
|
+
##############################################################
|
18
|
+
#
|
19
|
+
# NOTICE:
|
20
|
+
# THIS FEATURE HAS BEEN DEPRECATED ON SERVER.
|
21
|
+
# THE API WILL BE REMOVED FROM THE CLIENT IN THE FUTURE.
|
22
|
+
#
|
23
|
+
##############################################################
|
24
|
+
|
17
25
|
require 'aerospike/ldt/large'
|
18
26
|
|
19
27
|
module Aerospike
|
@@ -14,6 +14,14 @@
|
|
14
14
|
# License for the specific language governing permissions and limitations under
|
15
15
|
# the License.
|
16
16
|
|
17
|
+
##############################################################
|
18
|
+
#
|
19
|
+
# NOTICE:
|
20
|
+
# THIS FEATURE HAS BEEN DEPRECATED ON SERVER.
|
21
|
+
# THE API WILL BE REMOVED FROM THE CLIENT IN THE FUTURE.
|
22
|
+
#
|
23
|
+
##############################################################
|
24
|
+
|
17
25
|
require 'aerospike/ldt/large'
|
18
26
|
|
19
27
|
module Aerospike
|
@@ -14,6 +14,14 @@
|
|
14
14
|
# License for the specific language governing permissions and limitations under
|
15
15
|
# the License.
|
16
16
|
|
17
|
+
##############################################################
|
18
|
+
#
|
19
|
+
# NOTICE:
|
20
|
+
# THIS FEATURE HAS BEEN DEPRECATED ON SERVER.
|
21
|
+
# THE API WILL BE REMOVED FROM THE CLIENT IN THE FUTURE.
|
22
|
+
#
|
23
|
+
##############################################################
|
24
|
+
|
17
25
|
require 'aerospike/ldt/large'
|
18
26
|
|
19
27
|
module Aerospike
|
@@ -105,6 +105,16 @@ module Aerospike
|
|
105
105
|
# Key type mismatch.
|
106
106
|
KEY_MISMATCH = 19
|
107
107
|
|
108
|
+
# Invalid namespace.
|
109
|
+
INVALID_NAMESPACE = 20
|
110
|
+
|
111
|
+
# Sent too-long bin name (>14, should be impossible in this client) or exceeded
|
112
|
+
# namespace's bin name quota.
|
113
|
+
BIN_NAME_TOO_LONG = 21
|
114
|
+
|
115
|
+
# Operation not allowed at this time.
|
116
|
+
FAIL_FORBIDDEN = 22
|
117
|
+
|
108
118
|
# There are no more records left for query.
|
109
119
|
QUERY_END = 50
|
110
120
|
|
@@ -138,13 +148,16 @@ module Aerospike
|
|
138
148
|
FORBIDDEN_PASSWORD = 64
|
139
149
|
|
140
150
|
# Security credential is invalid.
|
141
|
-
INVALID_CREDENTIAL =
|
142
|
-
|
151
|
+
INVALID_CREDENTIAL = 65
|
143
152
|
|
144
153
|
# Role name is invalid.
|
145
154
|
INVALID_ROLE = 70
|
146
155
|
|
147
|
-
|
156
|
+
# Role Already exists
|
157
|
+
ROLE_ALREADY_EXISTS = 71
|
158
|
+
|
159
|
+
# Privilege is invalid.
|
160
|
+
INVALID_PRIVILEGE = 72
|
148
161
|
|
149
162
|
# User must be authentication before performing database operations.
|
150
163
|
NOT_AUTHENTICATED = 80
|
@@ -271,6 +284,15 @@ module Aerospike
|
|
271
284
|
when KEY_MISMATCH
|
272
285
|
"Key mismatch"
|
273
286
|
|
287
|
+
when INVALID_NAMESPACE
|
288
|
+
"Invalid namespace"
|
289
|
+
|
290
|
+
when BIN_NAME_TOO_LONG
|
291
|
+
"Sent too-long bin name or exceeded namespace's bin name quota."
|
292
|
+
|
293
|
+
when FAIL_FORBIDDEN
|
294
|
+
"Operation not allowed at this time"
|
295
|
+
|
274
296
|
when QUERY_END
|
275
297
|
"Query end"
|
276
298
|
|
@@ -313,6 +335,9 @@ module Aerospike
|
|
313
335
|
when INVALID_ROLE
|
314
336
|
"Invalid role"
|
315
337
|
|
338
|
+
when ROLE_ALREADY_EXISTS
|
339
|
+
"Role already exists"
|
340
|
+
|
316
341
|
when INVALID_PRIVILEGE
|
317
342
|
"Invalid privilege"
|
318
343
|
|
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.7
|
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-05-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: msgpack
|