aerospike_native 0.0.5 → 0.0.6
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.
- checksums.yaml +4 -4
- data/README.md +20 -3
- data/ext/aerospike_native/aerospike_native.c +1 -0
- data/ext/aerospike_native/aerospike_native.h +2 -2
- data/ext/aerospike_native/client.c +21 -62
- data/ext/aerospike_native/client.h +1 -1
- data/ext/aerospike_native/common.c +17 -0
- data/ext/aerospike_native/common.h +10 -0
- data/ext/aerospike_native/exception.c +45 -0
- data/ext/aerospike_native/exception.h +11 -0
- data/ext/aerospike_native/key.c +26 -0
- data/ext/aerospike_native/key.h +1 -1
- data/ext/aerospike_native/operation.c +4 -4
- data/ext/aerospike_native/operation.h +7 -7
- data/ext/aerospike_native/record.h +1 -1
- data/lib/aerospike_native/version.rb +1 -1
- metadata +6 -3
- data/aerospike_native.creator.user.93aa60d +0 -193
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 296cfb9cc494979027c364feb4637e48ddece680
|
4
|
+
data.tar.gz: fce6ce9af517cfe235f3c9e387ecb9816d38ba39
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8ce57e918e11980f5fbc9bc33d2db296f271be0f0d6043575d0ca1bf3cd4ba2893d416357fd1593e3269121a543868d277761787be3ee8d03493081e0fbdbef8
|
7
|
+
data.tar.gz: 4ff43fc3ec7bf72679014cce05a30efa09d5444c1c8a32ebc61122a43dd3c113eaa1aaef238fcd2e51b8678ff43dd236e7740c0e6ff74a998cfef8b27758a753
|
data/README.md
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# AerospikeNative
|
2
2
|
|
3
|
-
|
3
|
+
Ruby [aerospike](http://www.aerospike.com/) client with c extension (unstable)
|
4
4
|
|
5
5
|
## Installation
|
6
6
|
|
@@ -17,14 +17,31 @@ And then execute:
|
|
17
17
|
Or install it yourself as:
|
18
18
|
|
19
19
|
$ gem install aerospike_native
|
20
|
+
|
21
|
+
## Current status
|
22
|
+
|
23
|
+
* `operate` command with _write_, _increment_, _append_, _prepend_
|
24
|
+
* `put` command
|
25
|
+
* `get` command without digest keys support
|
26
|
+
* Raw (bytes) type is not supported
|
27
|
+
* Supported timeout for policies
|
20
28
|
|
21
29
|
## Usage
|
22
30
|
|
23
|
-
|
31
|
+
```ruby
|
32
|
+
require 'aerospike_native'
|
33
|
+
|
34
|
+
client = AerospikeNative::Client.new([{'host' => '127.0.0.1', 'port' => 3000}])
|
35
|
+
key = AerospikeNative::Key.new('test', 'test', 'sample')
|
36
|
+
client.put(key, {'bin1' => 1, 'bin2' => 'test'}, {'timeout' => 1})
|
37
|
+
client.operate(key, [AerospikeNative::Operation.write('bin3', 25), AerospikeNative::Operation.increment('bin1', 2), AerospikeNative::Operation.append('bin1', '_aerospike')], {'timeout' => 1})
|
38
|
+
|
39
|
+
record = client.get(key)
|
40
|
+
```
|
24
41
|
|
25
42
|
## Contributing
|
26
43
|
|
27
|
-
1. Fork it ( https://github.com/
|
44
|
+
1. Fork it ( https://github.com/rainlabs/aerospike_native/fork )
|
28
45
|
2. Create your feature branch (`git checkout -b my-new-feature`)
|
29
46
|
3. Commit your changes (`git commit -am 'Add some feature'`)
|
30
47
|
4. Push to the branch (`git push origin my-new-feature`)
|
@@ -27,23 +27,6 @@ static VALUE client_allocate(VALUE klass)
|
|
27
27
|
return obj;
|
28
28
|
}
|
29
29
|
|
30
|
-
static int keys_i(VALUE key, VALUE value, VALUE ary)
|
31
|
-
{
|
32
|
-
rb_ary_push(ary, key);
|
33
|
-
return ST_CONTINUE;
|
34
|
-
}
|
35
|
-
|
36
|
-
static VALUE
|
37
|
-
rb_hash_keys(VALUE hash)
|
38
|
-
{
|
39
|
-
VALUE ary;
|
40
|
-
|
41
|
-
ary = rb_ary_new_capa(RHASH_SIZE(hash));
|
42
|
-
rb_hash_foreach(hash, keys_i, ary);
|
43
|
-
|
44
|
-
return ary;
|
45
|
-
}
|
46
|
-
|
47
30
|
VALUE client_initialize(int argc, VALUE* argv, VALUE self)
|
48
31
|
{
|
49
32
|
VALUE ary = Qnil;
|
@@ -91,8 +74,7 @@ VALUE client_initialize(int argc, VALUE* argv, VALUE self)
|
|
91
74
|
aerospike_init(ptr, &config);
|
92
75
|
|
93
76
|
if ( aerospike_connect(ptr, &err) != AEROSPIKE_OK ) {
|
94
|
-
|
95
|
-
rb_raise(rb_eRuntimeError, "Aerospike error (%d) %s at [%s:%d]\n", err.code, err.message, err.file, err.line);
|
77
|
+
raise_aerospike_exception(err.code, err.message);
|
96
78
|
}
|
97
79
|
return self;
|
98
80
|
}
|
@@ -105,13 +87,11 @@ VALUE client_put(int argc, VALUE* vArgs, VALUE vSelf)
|
|
105
87
|
VALUE vHashKeys;
|
106
88
|
|
107
89
|
aerospike *ptr;
|
108
|
-
as_key key;
|
90
|
+
as_key* key;
|
109
91
|
as_error err;
|
110
92
|
as_record record;
|
111
93
|
as_policy_write policy;
|
112
94
|
|
113
|
-
VALUE vNamespace, vSet, vKeyValue;
|
114
|
-
|
115
95
|
int idx = 0, n = 0;
|
116
96
|
|
117
97
|
if (argc > 3 || argc < 2) { // there should only be 2 or 3 arguments
|
@@ -169,19 +149,15 @@ VALUE client_put(int argc, VALUE* vArgs, VALUE vSelf)
|
|
169
149
|
as_record_set_int64(&record, StringValueCStr(bin_name), NUM2LONG(bin_value));
|
170
150
|
break;
|
171
151
|
default:
|
172
|
-
rb_raise(rb_eArgError, "Incorrect input type");
|
152
|
+
rb_raise(rb_eArgError, "Incorrect input type (expected string or fixnum)");
|
173
153
|
break;
|
174
154
|
}
|
175
155
|
}
|
176
156
|
|
177
|
-
|
178
|
-
vSet = rb_iv_get(vKey, "@set");
|
179
|
-
vKeyValue = rb_iv_get(vKey, "@value");
|
180
|
-
as_key_init_str(&key, StringValueCStr( vNamespace ), StringValueCStr( vSet ), StringValueCStr( vKeyValue ));
|
157
|
+
Data_Get_Struct(vKey, as_key, key);
|
181
158
|
|
182
|
-
if (aerospike_key_put(ptr, &err, &policy,
|
183
|
-
|
184
|
-
fprintf(stderr, "err(%d) %s at [%s:%d]\n", err.code, err.message, err.file, err.line);
|
159
|
+
if (aerospike_key_put(ptr, &err, &policy, key, &record) != AEROSPIKE_OK) {
|
160
|
+
raise_aerospike_exception(err.code, err.message);
|
185
161
|
}
|
186
162
|
|
187
163
|
return Qtrue;
|
@@ -194,13 +170,12 @@ VALUE client_get(int argc, VALUE* vArgs, VALUE vSelf)
|
|
194
170
|
VALUE vParams[4];
|
195
171
|
|
196
172
|
aerospike *ptr;
|
197
|
-
as_key key;
|
173
|
+
as_key* key;
|
198
174
|
as_error err;
|
199
175
|
as_record* record = NULL;
|
200
176
|
as_policy_read policy;
|
201
177
|
as_bin bin;
|
202
178
|
|
203
|
-
VALUE vNamespace, vSet, vKeyValue;
|
204
179
|
int n = 0;
|
205
180
|
|
206
181
|
if (argc > 2 || argc < 1) { // there should only be 1 or 2 arguments
|
@@ -233,16 +208,11 @@ VALUE client_get(int argc, VALUE* vArgs, VALUE vSelf)
|
|
233
208
|
}
|
234
209
|
|
235
210
|
Data_Get_Struct(vSelf, aerospike, ptr);
|
236
|
-
|
237
|
-
|
238
|
-
|
239
|
-
|
240
|
-
|
241
|
-
if (aerospike_key_get(ptr, &err, &policy, &key, &record) != AEROSPIKE_OK) {
|
242
|
-
printf("error\n");
|
243
|
-
fprintf(stderr, "err(%d) %s at [%s:%d]\n", err.code, err.message, err.file, err.line);
|
211
|
+
Data_Get_Struct(vKey, as_key, key);
|
212
|
+
|
213
|
+
if (aerospike_key_get(ptr, &err, &policy, key, &record) != AEROSPIKE_OK) {
|
214
|
+
raise_aerospike_exception(err.code, err.message);
|
244
215
|
}
|
245
|
-
rb_iv_set(vKey, "@digest", rb_str_new( record->key.digest.value, AS_DIGEST_VALUE_SIZE));
|
246
216
|
|
247
217
|
vParams[0] = vKey;
|
248
218
|
vParams[1] = rb_hash_new();
|
@@ -276,12 +246,10 @@ VALUE client_operate(int argc, VALUE* argv, VALUE vSelf)
|
|
276
246
|
|
277
247
|
aerospike *ptr;
|
278
248
|
as_operations ops;
|
279
|
-
as_key key;
|
249
|
+
as_key* key;
|
280
250
|
as_error err;
|
281
251
|
as_policy_operate policy;
|
282
252
|
|
283
|
-
VALUE vNamespace, vSet, vKeyValue;
|
284
|
-
|
285
253
|
if (argc > 3 || argc < 2) { // there should only be 2 or 3 arguments
|
286
254
|
rb_raise(rb_eArgError, "wrong number of arguments (%d for 2..3)", argc);
|
287
255
|
}
|
@@ -328,7 +296,7 @@ VALUE client_operate(int argc, VALUE* argv, VALUE vSelf)
|
|
328
296
|
VALUE bin_value = rb_iv_get(operation, "@bin_value");
|
329
297
|
|
330
298
|
switch( op_type ) {
|
331
|
-
case
|
299
|
+
case OPERATION_WRITE:
|
332
300
|
switch( TYPE(bin_value) ) {
|
333
301
|
case T_STRING:
|
334
302
|
as_operations_add_write_str(&ops, StringValueCStr( bin_name ), StringValueCStr( bin_value ));
|
@@ -339,20 +307,20 @@ VALUE client_operate(int argc, VALUE* argv, VALUE vSelf)
|
|
339
307
|
}
|
340
308
|
|
341
309
|
break;
|
342
|
-
case
|
310
|
+
case OPERATION_READ:
|
343
311
|
break;
|
344
|
-
case
|
312
|
+
case OPERATION_INCREMENT:
|
345
313
|
as_operations_add_incr(&ops, StringValueCStr( bin_name ), NUM2INT( bin_value ));
|
346
314
|
break;
|
347
|
-
case
|
315
|
+
case OPERATION_APPEND:
|
348
316
|
Check_Type(bin_value, T_STRING);
|
349
317
|
as_operations_add_append_str(&ops, StringValueCStr( bin_name ), StringValueCStr( bin_value ));
|
350
318
|
break;
|
351
|
-
case
|
319
|
+
case OPERATION_PREPEND:
|
352
320
|
Check_Type(bin_value, T_STRING);
|
353
321
|
as_operations_add_prepend_str(&ops, StringValueCStr( bin_name ), StringValueCStr( bin_value ));
|
354
322
|
break;
|
355
|
-
case
|
323
|
+
case OPERATION_TOUCH:
|
356
324
|
as_operations_add_touch(&ops);
|
357
325
|
break;
|
358
326
|
default:
|
@@ -361,14 +329,10 @@ VALUE client_operate(int argc, VALUE* argv, VALUE vSelf)
|
|
361
329
|
}
|
362
330
|
}
|
363
331
|
|
364
|
-
|
365
|
-
vSet = rb_iv_get(vKey, "@set");
|
366
|
-
vKeyValue = rb_iv_get(vKey, "@value");
|
367
|
-
as_key_init_str(&key, StringValueCStr( vNamespace ), StringValueCStr( vSet ), StringValueCStr( vKeyValue ));
|
332
|
+
Data_Get_Struct(vKey, as_key, key);
|
368
333
|
|
369
|
-
if (aerospike_key_operate(ptr, &err, &policy,
|
370
|
-
|
371
|
-
fprintf(stderr, "err(%d) %s at [%s:%d]\n", err.code, err.message, err.file, err.line);
|
334
|
+
if (aerospike_key_operate(ptr, &err, &policy, key, &ops, NULL) != AEROSPIKE_OK) {
|
335
|
+
raise_aerospike_exception(err.code, err.message);
|
372
336
|
}
|
373
337
|
|
374
338
|
as_operations_destroy(&ops);
|
@@ -376,11 +340,6 @@ VALUE client_operate(int argc, VALUE* argv, VALUE vSelf)
|
|
376
340
|
return Qtrue;
|
377
341
|
}
|
378
342
|
|
379
|
-
// GET
|
380
|
-
// PUT
|
381
|
-
|
382
|
-
// Record
|
383
|
-
|
384
343
|
void define_client()
|
385
344
|
{
|
386
345
|
ClientClass = rb_define_class_under(AerospikeNativeClass, "Client", rb_cObject);
|
@@ -0,0 +1,17 @@
|
|
1
|
+
#include "common.h"
|
2
|
+
|
3
|
+
int keys_i(VALUE key, VALUE value, VALUE ary)
|
4
|
+
{
|
5
|
+
rb_ary_push(ary, key);
|
6
|
+
return ST_CONTINUE;
|
7
|
+
}
|
8
|
+
|
9
|
+
VALUE rb_hash_keys(VALUE hash)
|
10
|
+
{
|
11
|
+
VALUE ary;
|
12
|
+
|
13
|
+
ary = rb_ary_new_capa(RHASH_SIZE(hash));
|
14
|
+
rb_hash_foreach(hash, keys_i, ary);
|
15
|
+
|
16
|
+
return ary;
|
17
|
+
}
|
@@ -0,0 +1,45 @@
|
|
1
|
+
#include "exception.h"
|
2
|
+
|
3
|
+
VALUE ExceptionClass;
|
4
|
+
|
5
|
+
VALUE exception_initialize(VALUE vSelf, VALUE vMessage)
|
6
|
+
{
|
7
|
+
Check_Type(vMessage, T_STRING);
|
8
|
+
rb_iv_set(vSelf, "@message", vMessage);
|
9
|
+
|
10
|
+
return vSelf;
|
11
|
+
}
|
12
|
+
|
13
|
+
void define_exception()
|
14
|
+
{
|
15
|
+
ExceptionClass = rb_define_class_under(AerospikeNativeClass, "Exception", rb_eStandardError);
|
16
|
+
rb_define_method(ExceptionClass, "initialize", exception_initialize, 1);
|
17
|
+
rb_define_attr(ExceptionClass, "code", 1, 0);
|
18
|
+
rb_define_attr(ExceptionClass, "message", 1, 0);
|
19
|
+
|
20
|
+
rb_define_const(ExceptionClass, "ERR_CLIENT_ABORT", INT2FIX(AEROSPIKE_ERR_CLIENT_ABORT));
|
21
|
+
rb_define_const(ExceptionClass, "ERR_INVALID_HOST", INT2FIX(AEROSPIKE_ERR_INVALID_HOST));
|
22
|
+
rb_define_const(ExceptionClass, "NO_MORE_RECORDS", INT2FIX(AEROSPIKE_NO_MORE_RECORDS));
|
23
|
+
rb_define_const(ExceptionClass, "ERR_PARAM", INT2FIX(AEROSPIKE_ERR_PARAM));
|
24
|
+
rb_define_const(ExceptionClass, "ERR_CLIENT", INT2FIX(AEROSPIKE_ERR_CLIENT));
|
25
|
+
rb_define_const(ExceptionClass, "OK", INT2FIX(AEROSPIKE_OK));
|
26
|
+
rb_define_const(ExceptionClass, "ERR_SERVER", INT2FIX(AEROSPIKE_ERR_SERVER));
|
27
|
+
rb_define_const(ExceptionClass, "ERR_RECORD_NOT_FOUND", INT2FIX(AEROSPIKE_ERR_RECORD_NOT_FOUND)); // 2
|
28
|
+
|
29
|
+
rb_define_const(ExceptionClass, "ERR_RECORD_EXISTS", INT2FIX(AEROSPIKE_ERR_RECORD_EXISTS)); // 5
|
30
|
+
rb_define_const(ExceptionClass, "ERR_BIN_EXISTS", INT2FIX(AEROSPIKE_ERR_BIN_EXISTS)); // 6
|
31
|
+
|
32
|
+
rb_define_const(ExceptionClass, "ERR_TIMEOUT", INT2FIX(AEROSPIKE_ERR_TIMEOUT)); // 9
|
33
|
+
|
34
|
+
rb_define_const(ExceptionClass, "ERR_RECORD_TOO_BIG", INT2FIX(AEROSPIKE_ERR_RECORD_TOO_BIG)); // 13
|
35
|
+
rb_define_const(ExceptionClass, "ERR_RECORD_BUSY", INT2FIX(AEROSPIKE_ERR_RECORD_BUSY));
|
36
|
+
}
|
37
|
+
|
38
|
+
void raise_aerospike_exception(int iCode, char* sMessage)
|
39
|
+
{
|
40
|
+
VALUE vException;
|
41
|
+
|
42
|
+
vException = rb_exc_new2(ExceptionClass, sMessage);
|
43
|
+
rb_iv_set(vException, "@code", iCode);
|
44
|
+
rb_exc_raise(vException);
|
45
|
+
}
|
data/ext/aerospike_native/key.c
CHANGED
@@ -1,16 +1,41 @@
|
|
1
1
|
#include "key.h"
|
2
|
+
#include <aerospike/as_key.h>
|
2
3
|
|
3
4
|
VALUE KeyClass;
|
4
5
|
|
6
|
+
static void key_deallocate(void *p)
|
7
|
+
{
|
8
|
+
as_key* ptr = p;
|
9
|
+
as_key_destroy(ptr);
|
10
|
+
}
|
11
|
+
|
12
|
+
static VALUE key_allocate(VALUE klass)
|
13
|
+
{
|
14
|
+
VALUE obj;
|
15
|
+
as_key *ptr;
|
16
|
+
|
17
|
+
obj = Data_Make_Struct(klass, as_key, NULL, key_deallocate, ptr);
|
18
|
+
|
19
|
+
return obj;
|
20
|
+
}
|
21
|
+
|
5
22
|
VALUE key_initialize(VALUE vSelf, VALUE vNamespace, VALUE vSet, VALUE vValue)
|
6
23
|
{
|
24
|
+
as_key *ptr;
|
25
|
+
as_digest* digest;
|
26
|
+
|
7
27
|
Check_Type(vNamespace, T_STRING);
|
8
28
|
Check_Type(vSet, T_STRING);
|
9
29
|
Check_Type(vValue, T_STRING);
|
10
30
|
|
31
|
+
Data_Get_Struct(vSelf, as_key, ptr);
|
32
|
+
as_key_init_str(ptr, StringValueCStr( vNamespace ), StringValueCStr( vSet ), StringValueCStr( vValue ));
|
33
|
+
digest = as_key_digest(ptr);
|
34
|
+
|
11
35
|
rb_iv_set(vSelf, "@namespace", vNamespace);
|
12
36
|
rb_iv_set(vSelf, "@set", vSet);
|
13
37
|
rb_iv_set(vSelf, "@value", vValue);
|
38
|
+
rb_iv_set(vSelf, "@digest", rb_str_new( digest->value, AS_DIGEST_VALUE_SIZE));
|
14
39
|
|
15
40
|
return vSelf;
|
16
41
|
}
|
@@ -27,6 +52,7 @@ void check_aerospike_key(VALUE vKey)
|
|
27
52
|
void define_native_key()
|
28
53
|
{
|
29
54
|
KeyClass = rb_define_class_under(AerospikeNativeClass, "Key", rb_cObject);
|
55
|
+
rb_define_alloc_func(KeyClass, key_allocate);
|
30
56
|
rb_define_method(KeyClass, "initialize", key_initialize, 3);
|
31
57
|
rb_define_attr(KeyClass, "namespace", 1, 0);
|
32
58
|
rb_define_attr(KeyClass, "set", 1, 0);
|
data/ext/aerospike_native/key.h
CHANGED
@@ -17,7 +17,7 @@ VALUE operation_initialize(VALUE vSelf, VALUE vOpType, VALUE vBinName, VALUE vBi
|
|
17
17
|
VALUE operation_write(VALUE vSelf, VALUE vBinName, VALUE vBinValue)
|
18
18
|
{
|
19
19
|
VALUE vArgs[3];
|
20
|
-
vArgs[0] = INT2NUM(
|
20
|
+
vArgs[0] = INT2NUM(OPERATION_WRITE);
|
21
21
|
vArgs[1] = vBinName;
|
22
22
|
vArgs[2] = vBinValue;
|
23
23
|
return rb_class_new_instance(3, vArgs, vSelf);
|
@@ -29,7 +29,7 @@ VALUE operation_append(VALUE vSelf, VALUE vBinName, VALUE vBinValue)
|
|
29
29
|
|
30
30
|
Check_Type(vBinValue, T_STRING);
|
31
31
|
|
32
|
-
vArgs[0] = INT2NUM(
|
32
|
+
vArgs[0] = INT2NUM(OPERATION_APPEND);
|
33
33
|
vArgs[1] = vBinName;
|
34
34
|
vArgs[2] = vBinValue;
|
35
35
|
return rb_class_new_instance(3, vArgs, vSelf);
|
@@ -41,7 +41,7 @@ VALUE operation_prepend(VALUE vSelf, VALUE vBinName, VALUE vBinValue)
|
|
41
41
|
|
42
42
|
Check_Type(vBinValue, T_STRING);
|
43
43
|
|
44
|
-
vArgs[0] = INT2NUM(
|
44
|
+
vArgs[0] = INT2NUM(OPERATION_PREPEND);
|
45
45
|
vArgs[1] = vBinName;
|
46
46
|
vArgs[2] = vBinValue;
|
47
47
|
return rb_class_new_instance(3, vArgs, vSelf);
|
@@ -53,7 +53,7 @@ VALUE operation_increment(VALUE vSelf, VALUE vBinName, VALUE vBinValue)
|
|
53
53
|
|
54
54
|
Check_Type(vBinValue, T_FIXNUM);
|
55
55
|
|
56
|
-
vArgs[0] = INT2NUM(
|
56
|
+
vArgs[0] = INT2NUM(OPERATION_INCREMENT);
|
57
57
|
vArgs[1] = vBinName;
|
58
58
|
vArgs[2] = vBinValue;
|
59
59
|
return rb_class_new_instance(3, vArgs, vSelf);
|
@@ -3,16 +3,16 @@
|
|
3
3
|
|
4
4
|
#include "aerospike_native.h"
|
5
5
|
|
6
|
-
|
6
|
+
RUBY_EXTERN VALUE OperationClass;
|
7
7
|
void define_operation();
|
8
8
|
|
9
9
|
enum OperationType {
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
10
|
+
OPERATION_READ,
|
11
|
+
OPERATION_WRITE,
|
12
|
+
OPERATION_INCREMENT,
|
13
|
+
OPERATION_APPEND,
|
14
|
+
OPERATION_PREPEND,
|
15
|
+
OPERATION_TOUCH
|
16
16
|
};
|
17
17
|
|
18
18
|
#endif // OPERATION_H
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aerospike_native
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Vladimir Ziablitskii
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-07-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -80,12 +80,15 @@ files:
|
|
80
80
|
- LICENSE.txt
|
81
81
|
- README.md
|
82
82
|
- Rakefile
|
83
|
-
- aerospike_native.creator.user.93aa60d
|
84
83
|
- aerospike_native.gemspec
|
85
84
|
- ext/aerospike_native/aerospike_native.c
|
86
85
|
- ext/aerospike_native/aerospike_native.h
|
87
86
|
- ext/aerospike_native/client.c
|
88
87
|
- ext/aerospike_native/client.h
|
88
|
+
- ext/aerospike_native/common.c
|
89
|
+
- ext/aerospike_native/common.h
|
90
|
+
- ext/aerospike_native/exception.c
|
91
|
+
- ext/aerospike_native/exception.h
|
89
92
|
- ext/aerospike_native/extconf.rb
|
90
93
|
- ext/aerospike_native/include/.keep
|
91
94
|
- ext/aerospike_native/key.c
|
@@ -1,193 +0,0 @@
|
|
1
|
-
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
-
<!DOCTYPE QtCreatorProject>
|
3
|
-
<!-- Written by QtCreator 3.3.1, 2015-06-27T00:06:17. -->
|
4
|
-
<qtcreator>
|
5
|
-
<data>
|
6
|
-
<variable>EnvironmentId</variable>
|
7
|
-
<value type="QByteArray">{93aa60d5-4a13-46a0-a50b-d8053e37d65a}</value>
|
8
|
-
</data>
|
9
|
-
<data>
|
10
|
-
<variable>ProjectExplorer.Project.ActiveTarget</variable>
|
11
|
-
<value type="int">0</value>
|
12
|
-
</data>
|
13
|
-
<data>
|
14
|
-
<variable>ProjectExplorer.Project.EditorSettings</variable>
|
15
|
-
<valuemap type="QVariantMap">
|
16
|
-
<value type="bool" key="EditorConfiguration.AutoIndent">true</value>
|
17
|
-
<value type="bool" key="EditorConfiguration.AutoSpacesForTabs">false</value>
|
18
|
-
<value type="bool" key="EditorConfiguration.CamelCaseNavigation">true</value>
|
19
|
-
<valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.0">
|
20
|
-
<value type="QString" key="language">Cpp</value>
|
21
|
-
<valuemap type="QVariantMap" key="value">
|
22
|
-
<value type="QByteArray" key="CurrentPreferences">CppGlobal</value>
|
23
|
-
</valuemap>
|
24
|
-
</valuemap>
|
25
|
-
<valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.1">
|
26
|
-
<value type="QString" key="language">QmlJS</value>
|
27
|
-
<valuemap type="QVariantMap" key="value">
|
28
|
-
<value type="QByteArray" key="CurrentPreferences">QmlJSGlobal</value>
|
29
|
-
</valuemap>
|
30
|
-
</valuemap>
|
31
|
-
<value type="int" key="EditorConfiguration.CodeStyle.Count">2</value>
|
32
|
-
<value type="QByteArray" key="EditorConfiguration.Codec">UTF-8</value>
|
33
|
-
<value type="bool" key="EditorConfiguration.ConstrainTooltips">false</value>
|
34
|
-
<value type="int" key="EditorConfiguration.IndentSize">4</value>
|
35
|
-
<value type="bool" key="EditorConfiguration.KeyboardTooltips">false</value>
|
36
|
-
<value type="int" key="EditorConfiguration.MarginColumn">80</value>
|
37
|
-
<value type="bool" key="EditorConfiguration.MouseHiding">true</value>
|
38
|
-
<value type="bool" key="EditorConfiguration.MouseNavigation">true</value>
|
39
|
-
<value type="int" key="EditorConfiguration.PaddingMode">1</value>
|
40
|
-
<value type="bool" key="EditorConfiguration.ScrollWheelZooming">true</value>
|
41
|
-
<value type="bool" key="EditorConfiguration.ShowMargin">false</value>
|
42
|
-
<value type="int" key="EditorConfiguration.SmartBackspaceBehavior">0</value>
|
43
|
-
<value type="bool" key="EditorConfiguration.SpacesForTabs">true</value>
|
44
|
-
<value type="int" key="EditorConfiguration.TabKeyBehavior">0</value>
|
45
|
-
<value type="int" key="EditorConfiguration.TabSize">8</value>
|
46
|
-
<value type="bool" key="EditorConfiguration.UseGlobal">true</value>
|
47
|
-
<value type="int" key="EditorConfiguration.Utf8BomBehavior">1</value>
|
48
|
-
<value type="bool" key="EditorConfiguration.addFinalNewLine">true</value>
|
49
|
-
<value type="bool" key="EditorConfiguration.cleanIndentation">true</value>
|
50
|
-
<value type="bool" key="EditorConfiguration.cleanWhitespace">true</value>
|
51
|
-
<value type="bool" key="EditorConfiguration.inEntireDocument">false</value>
|
52
|
-
</valuemap>
|
53
|
-
</data>
|
54
|
-
<data>
|
55
|
-
<variable>ProjectExplorer.Project.PluginSettings</variable>
|
56
|
-
<valuemap type="QVariantMap"/>
|
57
|
-
</data>
|
58
|
-
<data>
|
59
|
-
<variable>ProjectExplorer.Project.Target.0</variable>
|
60
|
-
<valuemap type="QVariantMap">
|
61
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Desktop</value>
|
62
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Desktop</value>
|
63
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">{67e3e301-82cd-498d-a671-f86202cae2db}</value>
|
64
|
-
<value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">0</value>
|
65
|
-
<value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
|
66
|
-
<value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
|
67
|
-
<valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
|
68
|
-
<value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory">/home/rain/projects/aerospike_native</value>
|
69
|
-
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
|
70
|
-
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
71
|
-
<valuelist type="QVariantList" key="GenericProjectManager.GenericMakeStep.BuildTargets">
|
72
|
-
<value type="QString">all</value>
|
73
|
-
</valuelist>
|
74
|
-
<value type="bool" key="GenericProjectManager.GenericMakeStep.Clean">false</value>
|
75
|
-
<value type="QString" key="GenericProjectManager.GenericMakeStep.MakeArguments"></value>
|
76
|
-
<value type="QString" key="GenericProjectManager.GenericMakeStep.MakeCommand"></value>
|
77
|
-
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
78
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
|
79
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
80
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">GenericProjectManager.GenericMakeStep</value>
|
81
|
-
</valuemap>
|
82
|
-
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
83
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
|
84
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
85
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
|
86
|
-
</valuemap>
|
87
|
-
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
|
88
|
-
<valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
|
89
|
-
<valuelist type="QVariantList" key="GenericProjectManager.GenericMakeStep.BuildTargets">
|
90
|
-
<value type="QString">clean</value>
|
91
|
-
</valuelist>
|
92
|
-
<value type="bool" key="GenericProjectManager.GenericMakeStep.Clean">true</value>
|
93
|
-
<value type="QString" key="GenericProjectManager.GenericMakeStep.MakeArguments"></value>
|
94
|
-
<value type="QString" key="GenericProjectManager.GenericMakeStep.MakeCommand"></value>
|
95
|
-
<value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
|
96
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
|
97
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
98
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">GenericProjectManager.GenericMakeStep</value>
|
99
|
-
</valuemap>
|
100
|
-
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
|
101
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
|
102
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
103
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
|
104
|
-
</valuemap>
|
105
|
-
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
|
106
|
-
<value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
|
107
|
-
<valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
|
108
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Default</value>
|
109
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Default</value>
|
110
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">GenericProjectManager.GenericBuildConfiguration</value>
|
111
|
-
</valuemap>
|
112
|
-
<value type="int" key="ProjectExplorer.Target.BuildConfigurationCount">1</value>
|
113
|
-
<valuemap type="QVariantMap" key="ProjectExplorer.Target.DeployConfiguration.0">
|
114
|
-
<valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
|
115
|
-
<value type="int" key="ProjectExplorer.BuildStepList.StepsCount">0</value>
|
116
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy</value>
|
117
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
118
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Deploy</value>
|
119
|
-
</valuemap>
|
120
|
-
<value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">1</value>
|
121
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy locally</value>
|
122
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
123
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.DefaultDeployConfiguration</value>
|
124
|
-
</valuemap>
|
125
|
-
<value type="int" key="ProjectExplorer.Target.DeployConfigurationCount">1</value>
|
126
|
-
<valuemap type="QVariantMap" key="ProjectExplorer.Target.PluginSettings"/>
|
127
|
-
<valuemap type="QVariantMap" key="ProjectExplorer.Target.RunConfiguration.0">
|
128
|
-
<valuelist type="QVariantList" key="Analyzer.Valgrind.AddedSuppressionFiles"/>
|
129
|
-
<value type="bool" key="Analyzer.Valgrind.Callgrind.CollectBusEvents">false</value>
|
130
|
-
<value type="bool" key="Analyzer.Valgrind.Callgrind.CollectSystime">false</value>
|
131
|
-
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableBranchSim">false</value>
|
132
|
-
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableCacheSim">false</value>
|
133
|
-
<value type="bool" key="Analyzer.Valgrind.Callgrind.EnableEventToolTips">true</value>
|
134
|
-
<value type="double" key="Analyzer.Valgrind.Callgrind.MinimumCostRatio">0.01</value>
|
135
|
-
<value type="double" key="Analyzer.Valgrind.Callgrind.VisualisationMinimumCostRatio">10</value>
|
136
|
-
<value type="bool" key="Analyzer.Valgrind.FilterExternalIssues">true</value>
|
137
|
-
<value type="int" key="Analyzer.Valgrind.LeakCheckOnFinish">1</value>
|
138
|
-
<value type="int" key="Analyzer.Valgrind.NumCallers">25</value>
|
139
|
-
<valuelist type="QVariantList" key="Analyzer.Valgrind.RemovedSuppressionFiles"/>
|
140
|
-
<value type="int" key="Analyzer.Valgrind.SelfModifyingCodeDetection">1</value>
|
141
|
-
<value type="bool" key="Analyzer.Valgrind.Settings.UseGlobalSettings">true</value>
|
142
|
-
<value type="bool" key="Analyzer.Valgrind.ShowReachable">false</value>
|
143
|
-
<value type="bool" key="Analyzer.Valgrind.TrackOrigins">true</value>
|
144
|
-
<value type="QString" key="Analyzer.Valgrind.ValgrindExecutable">valgrind</value>
|
145
|
-
<valuelist type="QVariantList" key="Analyzer.Valgrind.VisibleErrorKinds">
|
146
|
-
<value type="int">0</value>
|
147
|
-
<value type="int">1</value>
|
148
|
-
<value type="int">2</value>
|
149
|
-
<value type="int">3</value>
|
150
|
-
<value type="int">4</value>
|
151
|
-
<value type="int">5</value>
|
152
|
-
<value type="int">6</value>
|
153
|
-
<value type="int">7</value>
|
154
|
-
<value type="int">8</value>
|
155
|
-
<value type="int">9</value>
|
156
|
-
<value type="int">10</value>
|
157
|
-
<value type="int">11</value>
|
158
|
-
<value type="int">12</value>
|
159
|
-
<value type="int">13</value>
|
160
|
-
<value type="int">14</value>
|
161
|
-
</valuelist>
|
162
|
-
<value type="int" key="PE.EnvironmentAspect.Base">2</value>
|
163
|
-
<valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
|
164
|
-
<value type="QString" key="ProjectExplorer.CustomExecutableRunConfiguration.Arguments"></value>
|
165
|
-
<value type="QString" key="ProjectExplorer.CustomExecutableRunConfiguration.Executable"></value>
|
166
|
-
<value type="bool" key="ProjectExplorer.CustomExecutableRunConfiguration.UseTerminal">false</value>
|
167
|
-
<value type="QString" key="ProjectExplorer.CustomExecutableRunConfiguration.WorkingDirectory">%{buildDir}</value>
|
168
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Custom Executable</value>
|
169
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
|
170
|
-
<value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.CustomExecutableRunConfiguration</value>
|
171
|
-
<value type="uint" key="RunConfiguration.QmlDebugServerPort">3768</value>
|
172
|
-
<value type="bool" key="RunConfiguration.UseCppDebugger">false</value>
|
173
|
-
<value type="bool" key="RunConfiguration.UseCppDebuggerAuto">true</value>
|
174
|
-
<value type="bool" key="RunConfiguration.UseMultiProcess">false</value>
|
175
|
-
<value type="bool" key="RunConfiguration.UseQmlDebugger">false</value>
|
176
|
-
<value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">true</value>
|
177
|
-
</valuemap>
|
178
|
-
<value type="int" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
|
179
|
-
</valuemap>
|
180
|
-
</data>
|
181
|
-
<data>
|
182
|
-
<variable>ProjectExplorer.Project.TargetCount</variable>
|
183
|
-
<value type="int">1</value>
|
184
|
-
</data>
|
185
|
-
<data>
|
186
|
-
<variable>ProjectExplorer.Project.Updater.FileVersion</variable>
|
187
|
-
<value type="int">18</value>
|
188
|
-
</data>
|
189
|
-
<data>
|
190
|
-
<variable>Version</variable>
|
191
|
-
<value type="int">18</value>
|
192
|
-
</data>
|
193
|
-
</qtcreator>
|