tupelo 0.20 → 0.21
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 +15 -3
- data/bench/{tuplespace.rb → tuplestore.rb} +3 -3
- data/bin/tspy +2 -2
- data/bin/tup +20 -3
- data/example/multi-tier/{kvspace.rb → kvstore.rb} +2 -2
- data/example/multi-tier/memo2.rb +4 -4
- data/example/riemann/v2/event-sql.rb +56 -0
- data/example/riemann/v2/expirer.rb +4 -1
- data/example/riemann/v2/hash-store.rb +6 -6
- data/example/riemann/v2/ordered-event-store.rb +1 -1
- data/example/riemann/v2/riemann.rb +7 -4
- data/example/riemann/v2/sqlite-event-store.rb +174 -0
- data/example/sqlite/poi-client.rb +11 -0
- data/example/sqlite/poi-store.rb +38 -56
- data/example/sqlite/poi-template.rb +61 -0
- data/example/sqlite/poi-v2.rb +63 -33
- data/example/sqlite/poi.rb +13 -25
- data/example/sqlite/tmp/poi-sqlite.rb +10 -8
- data/example/subspaces/addr-book.rb +2 -2
- data/example/subspaces/{sorted-set-space.rb → sorted-set-store.rb} +4 -4
- data/example/wip/complex-tags.rb +45 -0
- data/lib/tupelo/app/trace.rb +1 -1
- data/lib/tupelo/app.rb +3 -3
- data/lib/tupelo/archiver/{persistent-tuplespace.rb → persistent-tuplestore.rb} +1 -1
- data/lib/tupelo/archiver/{tuplespace.rb → tuplestore.rb} +2 -2
- data/lib/tupelo/archiver/worker.rb +12 -12
- data/lib/tupelo/archiver.rb +7 -5
- data/lib/tupelo/client/reader.rb +13 -10
- data/lib/tupelo/client/subspace.rb +12 -4
- data/lib/tupelo/client/transaction.rb +98 -95
- data/lib/tupelo/client/{tuplespace.rb → tuplestore.rb} +4 -4
- data/lib/tupelo/client/worker.rb +44 -35
- data/lib/tupelo/client.rb +4 -4
- data/lib/tupelo/version.rb +1 -1
- data/test/lib/mock-client.rb +1 -1
- data/test/lib/testable-worker.rb +1 -1
- data/test/unit/test-ops.rb +1 -1
- metadata +13 -9
- data/example/map-reduce/ex.rb +0 -32
@@ -108,6 +108,7 @@ class Tupelo::Client
|
|
108
108
|
attr_reader :granted_tuples
|
109
109
|
attr_reader :missing
|
110
110
|
attr_reader :tags
|
111
|
+
attr_reader :read_only
|
111
112
|
|
112
113
|
STATES = [
|
113
114
|
OPEN = :open, # initial state
|
@@ -149,14 +150,15 @@ class Tupelo::Client
|
|
149
150
|
@tags = nil
|
150
151
|
@_take_nowait = nil
|
151
152
|
@_read_nowait = nil
|
153
|
+
@read_only = false
|
152
154
|
|
155
|
+
open!
|
156
|
+
|
153
157
|
if deadline
|
154
158
|
worker.at deadline do
|
155
159
|
cancel(TimeoutError) if open?
|
156
160
|
end
|
157
161
|
end
|
158
|
-
|
159
|
-
open!
|
160
162
|
end
|
161
163
|
|
162
164
|
def client_id
|
@@ -175,10 +177,6 @@ class Tupelo::Client
|
|
175
177
|
end
|
176
178
|
end
|
177
179
|
|
178
|
-
def read_only?
|
179
|
-
@writes.empty? && @pulses.empty? && @take_templates.empty?
|
180
|
-
end
|
181
|
-
|
182
180
|
def inspect
|
183
181
|
stat_extra =
|
184
182
|
case
|
@@ -304,7 +302,7 @@ class Tupelo::Client
|
|
304
302
|
# this causes transaction to be re-executed.
|
305
303
|
def fail!
|
306
304
|
raise if in_worker_thread?
|
307
|
-
|
305
|
+
check_open
|
308
306
|
failed!
|
309
307
|
raise TransactionFailure
|
310
308
|
end
|
@@ -312,17 +310,11 @@ class Tupelo::Client
|
|
312
310
|
# idempotent
|
313
311
|
def commit
|
314
312
|
if open?
|
315
|
-
|
316
|
-
|
317
|
-
@
|
318
|
-
|
319
|
-
|
320
|
-
log.info {"not committing empty transaction"}
|
321
|
-
else
|
322
|
-
closed!
|
323
|
-
log.info {"committing #{inspect}"}
|
324
|
-
worker_push self
|
325
|
-
end
|
313
|
+
closed!
|
314
|
+
@read_only = @writes.empty? && @pulses.empty? &&
|
315
|
+
@take_tuples_for_remote.all? {|t| t.nil?}
|
316
|
+
log.info {"committing #{inspect}"}
|
317
|
+
worker_push self
|
326
318
|
else
|
327
319
|
raise exception if failed?
|
328
320
|
end
|
@@ -369,7 +361,7 @@ class Tupelo::Client
|
|
369
361
|
|
370
362
|
def async &block
|
371
363
|
raise ArgumentError, "must provide block" unless block
|
372
|
-
TransactionThread.new(self) do
|
364
|
+
TransactionThread.new(self) do
|
373
365
|
begin
|
374
366
|
val =
|
375
367
|
if block.arity == 0
|
@@ -394,100 +386,112 @@ class Tupelo::Client
|
|
394
386
|
worker.in_thread?
|
395
387
|
end
|
396
388
|
|
397
|
-
|
398
|
-
|
389
|
+
# Further prepare this open transaction after the arrival of a new tuple.
|
390
|
+
def prepare new_tuple
|
391
|
+
return false if closed? or failed?
|
399
392
|
raise unless in_worker_thread?
|
400
393
|
|
401
|
-
if
|
402
|
-
return true if take_tuples_for_local.all? and read_tuples_for_local.all?
|
394
|
+
return true if take_tuples_for_local.all? and read_tuples_for_local.all?
|
403
395
|
|
404
|
-
|
405
|
-
|
406
|
-
|
407
|
-
|
408
|
-
|
409
|
-
|
410
|
-
end
|
396
|
+
take_tuples_for_local.each_with_index do |tuple, i|
|
397
|
+
if not tuple and take_templates[i] === new_tuple
|
398
|
+
take_tuples_for_local[i] = new_tuple
|
399
|
+
take_tuples_for_remote[i] = new_tuple
|
400
|
+
log.debug {"prepared #{inspect} with #{new_tuple}"}
|
401
|
+
break
|
411
402
|
end
|
403
|
+
end
|
412
404
|
|
413
|
-
|
414
|
-
|
415
|
-
|
416
|
-
|
417
|
-
|
418
|
-
end
|
405
|
+
read_tuples_for_local.each_with_index do |tuple, i|
|
406
|
+
if not tuple and read_templates[i] === new_tuple
|
407
|
+
read_tuples_for_local[i] = new_tuple
|
408
|
+
read_tuples_for_remote[i] = new_tuple
|
409
|
+
log.debug {"prepared #{inspect} with #{new_tuple}"}
|
419
410
|
end
|
411
|
+
end
|
420
412
|
|
421
|
-
|
422
|
-
|
423
|
-
|
424
|
-
(take_tuples_for_local.size...take_templates.size).each do |i|
|
425
|
-
template = take_templates[i]
|
426
|
-
|
427
|
-
if wt = @writes.find {|tuple| template === tuple}
|
428
|
-
take_tuples_for_remote[i] = nil
|
429
|
-
take_tuples_for_local[i] = wt.dup
|
430
|
-
@writes.delete wt
|
431
|
-
next
|
432
|
-
end
|
413
|
+
wake_client_if_ready
|
414
|
+
return true
|
415
|
+
end
|
433
416
|
|
434
|
-
|
435
|
-
|
436
|
-
|
437
|
-
|
438
|
-
|
439
|
-
|
440
|
-
|
441
|
-
|
442
|
-
|
443
|
-
|
417
|
+
# Further prepare this open transaction after new operations are added.
|
418
|
+
def prepare_ops
|
419
|
+
return false if closed? or failed?
|
420
|
+
raise unless in_worker_thread?
|
421
|
+
|
422
|
+
## optimization: use tuple cache
|
423
|
+
skip = nil
|
424
|
+
(take_tuples_for_local.size...take_templates.size).each do |i|
|
425
|
+
template = take_templates[i]
|
426
|
+
|
427
|
+
if wt = @writes.find {|tuple| template === tuple}
|
428
|
+
take_tuples_for_remote[i] = nil
|
429
|
+
take_tuples_for_local[i] = wt.dup
|
430
|
+
@writes.delete wt
|
431
|
+
next
|
432
|
+
end
|
433
|
+
|
434
|
+
take_tuples_for_local[i] = take_tuples_for_remote[i] =
|
435
|
+
worker.tuplestore.find_match_for(template,
|
436
|
+
distinct_from: take_tuples_for_local)
|
437
|
+
|
438
|
+
if take_tuples_for_local[i]
|
439
|
+
log.debug {"prepared #{inspect} with #{take_tuples_for_local[i]}"}
|
440
|
+
else
|
441
|
+
if @_take_nowait and @_take_nowait[i]
|
442
|
+
(skip ||= []) << i
|
444
443
|
end
|
445
444
|
end
|
445
|
+
end
|
446
|
+
|
447
|
+
skip and skip.reverse_each do |i|
|
448
|
+
take_tuples_for_local.delete_at i
|
449
|
+
take_tuples_for_remote.delete_at i
|
450
|
+
take_templates.delete_at i
|
451
|
+
@_take_nowait.delete i
|
452
|
+
end
|
446
453
|
|
447
|
-
|
448
|
-
|
449
|
-
|
450
|
-
|
451
|
-
|
454
|
+
skip = nil
|
455
|
+
(read_tuples_for_local.size...read_templates.size).each do |i|
|
456
|
+
template = read_templates[i]
|
457
|
+
|
458
|
+
if wt = @writes.find {|tuple| template === tuple}
|
459
|
+
read_tuples_for_remote[i] = nil
|
460
|
+
read_tuples_for_local[i] = wt.dup
|
461
|
+
next
|
452
462
|
end
|
453
|
-
|
454
|
-
skip = nil
|
455
|
-
(read_tuples_for_local.size...read_templates.size).each do |i|
|
456
|
-
template = read_templates[i]
|
457
|
-
|
458
|
-
if wt = @writes.find {|tuple| template === tuple}
|
459
|
-
read_tuples_for_remote[i] = nil
|
460
|
-
read_tuples_for_local[i] = wt.dup
|
461
|
-
next
|
462
|
-
end
|
463
463
|
|
464
|
-
|
465
|
-
|
466
|
-
|
467
|
-
|
468
|
-
|
469
|
-
|
470
|
-
|
471
|
-
|
472
|
-
|
473
|
-
end
|
464
|
+
read_tuples_for_local[i] = read_tuples_for_remote[i] =
|
465
|
+
worker.tuplestore.find_match_for(template,
|
466
|
+
distinct_from: take_tuples_for_local)
|
467
|
+
|
468
|
+
if read_tuples_for_local[i]
|
469
|
+
log.debug {"prepared #{inspect} with #{read_tuples_for_local[i]}"}
|
470
|
+
else
|
471
|
+
if @_read_nowait and @_read_nowait[i]
|
472
|
+
(skip ||= []) << i
|
474
473
|
end
|
475
474
|
end
|
475
|
+
end
|
476
476
|
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
|
481
|
-
|
482
|
-
end
|
477
|
+
skip and skip.reverse_each do |i|
|
478
|
+
read_tuples_for_local.delete_at i
|
479
|
+
read_tuples_for_remote.delete_at i
|
480
|
+
read_templates.delete_at i
|
481
|
+
@_read_nowait.delete i
|
483
482
|
end
|
484
|
-
|
483
|
+
|
485
484
|
## convert cancelling write/take to pulse
|
486
485
|
## convert cancelling take/write to read
|
487
486
|
## remove redundant pulse after read
|
488
487
|
## remove redundant read before take
|
489
488
|
## remove redundant read after write
|
490
|
-
|
489
|
+
|
490
|
+
wake_client_if_ready
|
491
|
+
return true
|
492
|
+
end
|
493
|
+
|
494
|
+
def wake_client_if_ready
|
491
495
|
if take_tuples_for_local.all? and read_tuples_for_local.all?
|
492
496
|
@queue << true
|
493
497
|
log.debug {
|
@@ -495,8 +499,6 @@ class Tupelo::Client
|
|
495
499
|
"take tuples: #{take_tuples_for_local}, " +
|
496
500
|
"read tuples: #{read_tuples_for_local}"}
|
497
501
|
end
|
498
|
-
|
499
|
-
return true
|
500
502
|
end
|
501
503
|
|
502
504
|
def unprepare missing_tuple
|
@@ -531,8 +533,9 @@ class Tupelo::Client
|
|
531
533
|
end
|
532
534
|
|
533
535
|
def done global_tick, granted_tuples
|
534
|
-
|
535
|
-
pending
|
536
|
+
unless pending? or (closed? and read_only)
|
537
|
+
raise TransactionStateError, "must be pending or closed+read_only"
|
538
|
+
end
|
536
539
|
raise unless in_worker_thread?
|
537
540
|
raise if @global_tick or @exception
|
538
541
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
class Tupelo::Client
|
2
|
-
# Simplest fully functional
|
3
|
-
class
|
2
|
+
# Simplest fully functional tuplestore. Not efficient for large stores.
|
3
|
+
class SimpleTupleStore < Array
|
4
4
|
alias insert <<
|
5
5
|
|
6
6
|
def delete_once elt
|
@@ -32,12 +32,12 @@ class Tupelo::Client
|
|
32
32
|
end
|
33
33
|
end
|
34
34
|
|
35
|
-
#
|
35
|
+
# Tuplestore that stores nothing. Very efficient for large stores!
|
36
36
|
# Useful for clients that don't need to take or read the stored tuples.
|
37
37
|
# The write, pulse, and blocking read operations all work correctly.
|
38
38
|
# The client is essentially a pub/sub client, then. See the
|
39
39
|
# --pubsub switch in tup for an example.
|
40
|
-
class
|
40
|
+
class NullTupleStore
|
41
41
|
include Enumerable
|
42
42
|
def each(*); end
|
43
43
|
def delete_once(*); end
|
data/lib/tupelo/client/worker.rb
CHANGED
@@ -17,7 +17,7 @@ class Tupelo::Client
|
|
17
17
|
attr_reader :msg_reader_thread
|
18
18
|
attr_reader :worker_thread
|
19
19
|
attr_reader :cmd_queue
|
20
|
-
attr_reader :
|
20
|
+
attr_reader :tuplestore
|
21
21
|
attr_reader :message_class
|
22
22
|
attr_reader :blobber
|
23
23
|
attr_reader :read_waiters
|
@@ -26,7 +26,7 @@ class Tupelo::Client
|
|
26
26
|
attr_reader :notify_waiters
|
27
27
|
attr_reader :subspaces
|
28
28
|
|
29
|
-
|
29
|
+
GET_TUPLESTORE = "get tuplestore"
|
30
30
|
|
31
31
|
class Operation
|
32
32
|
attr_reader :writes, :pulses, :takes, :reads
|
@@ -50,14 +50,16 @@ class Tupelo::Client
|
|
50
50
|
end
|
51
51
|
|
52
52
|
class Subspace
|
53
|
-
attr_reader :tag
|
53
|
+
attr_reader :tag, :spec, :pot
|
54
|
+
alias template pot
|
54
55
|
|
55
56
|
def initialize metatuple, worker
|
56
57
|
@metatuple = metatuple
|
57
|
-
@tag = metatuple["tag"]
|
58
|
+
@tag = metatuple["tag"] || metatuple[:tag]
|
58
59
|
|
59
|
-
|
60
|
-
@
|
60
|
+
template = metatuple["template"] || metatuple[:template]
|
61
|
+
@spec = Marshal.load(Marshal.dump(template)).freeze
|
62
|
+
@pot = worker.pot_for(spec).optimize!.freeze
|
61
63
|
end
|
62
64
|
|
63
65
|
def === tuple
|
@@ -79,7 +81,7 @@ class Tupelo::Client
|
|
79
81
|
@delta = 0
|
80
82
|
|
81
83
|
@cmd_queue = client.make_queue
|
82
|
-
@
|
84
|
+
@tuplestore = nil
|
83
85
|
@message_class = client.message_class
|
84
86
|
@blobber = nil
|
85
87
|
|
@@ -99,15 +101,15 @@ class Tupelo::Client
|
|
99
101
|
end
|
100
102
|
end
|
101
103
|
|
102
|
-
def
|
103
|
-
@
|
104
|
-
if client.
|
105
|
-
client.
|
106
|
-
elsif client.
|
107
|
-
tsclass, *args = client.
|
108
|
-
tsclass.new(*args)
|
104
|
+
def tuplestore
|
105
|
+
@tuplestore ||= begin
|
106
|
+
if client.tuplestore.respond_to? :new
|
107
|
+
client.tuplestore.new
|
108
|
+
elsif client.tuplestore.class == Array # but not subclass of Array
|
109
|
+
tsclass, *args = client.tuplestore
|
110
|
+
tsclass.new(*args, client: client)
|
109
111
|
else
|
110
|
-
client.
|
112
|
+
client.tuplestore
|
111
113
|
end
|
112
114
|
end
|
113
115
|
end
|
@@ -239,17 +241,17 @@ class Tupelo::Client
|
|
239
241
|
return
|
240
242
|
end
|
241
243
|
|
242
|
-
log.info "requesting
|
244
|
+
log.info "requesting tuplestore from arc"
|
243
245
|
subscription_delta = {
|
244
246
|
request_all: all,
|
245
247
|
request_tags: tags,
|
246
248
|
subscribed_all: client.subscribed_all,
|
247
249
|
subscribed_tags: client.subscribed_tags
|
248
250
|
}
|
249
|
-
arc << [
|
251
|
+
arc << [GET_TUPLESTORE, subscription_delta, tick]
|
250
252
|
|
251
253
|
begin
|
252
|
-
|
254
|
+
tuplestore.clear
|
253
255
|
## In some cases, we can keep some of it, but the current
|
254
256
|
## archiver is not smart enough to send exactly the delta.
|
255
257
|
## Also, might need to abort some current transactions.
|
@@ -265,15 +267,15 @@ class Tupelo::Client
|
|
265
267
|
else
|
266
268
|
raise "bad object stream from archiver" if done
|
267
269
|
sniff_meta_tuple tuple
|
268
|
-
|
270
|
+
tuplestore.insert tuple
|
269
271
|
count += 1
|
270
272
|
end
|
271
273
|
end
|
272
274
|
unless done
|
273
|
-
raise "did not get all of
|
275
|
+
raise "did not get all of tuplestore from archiver" ## roll back?
|
274
276
|
end
|
275
277
|
|
276
|
-
log.info "received
|
278
|
+
log.info "received tuplestore from arc: #{count} tuples"
|
277
279
|
|
278
280
|
@global_tick = arc_tick
|
279
281
|
log.info "global_tick = #{global_tick}"
|
@@ -332,8 +334,8 @@ class Tupelo::Client
|
|
332
334
|
waiter << [:attempt, msg.global_tick, msg.client_id, op, msg.tags]
|
333
335
|
end
|
334
336
|
|
335
|
-
take_tuples =
|
336
|
-
read_tuples = op.reads.map {|t|
|
337
|
+
take_tuples = tuplestore.find_distinct_matches_for(op.takes)
|
338
|
+
read_tuples = op.reads.map {|t| tuplestore.find_match_for(t,
|
337
339
|
distinct_from: take_tuples)}
|
338
340
|
succeeded = take_tuples.all? && read_tuples.all?
|
339
341
|
|
@@ -349,7 +351,7 @@ class Tupelo::Client
|
|
349
351
|
|
350
352
|
if succeeded
|
351
353
|
log.debug {"inserting #{op.writes}; deleting #{take_tuples}"}
|
352
|
-
|
354
|
+
tuplestore.transaction inserts: write_tuples, deletes: take_tuples,
|
353
355
|
tick: @global_tick
|
354
356
|
|
355
357
|
op.writes.each do |tuple|
|
@@ -359,7 +361,8 @@ class Tupelo::Client
|
|
359
361
|
take_tuples.each do |tuple|
|
360
362
|
if is_meta_tuple? tuple
|
361
363
|
## do some error checking
|
362
|
-
|
364
|
+
tag = tuple["tag"] || tuple[:tag]
|
365
|
+
subspaces.delete_if {|sp| sp.tag == tag}
|
363
366
|
end
|
364
367
|
end
|
365
368
|
end
|
@@ -452,8 +455,8 @@ class Tupelo::Client
|
|
452
455
|
meta_subspace === tuple
|
453
456
|
else
|
454
457
|
# meta_subspace hasn't arrived yet, so use approximation
|
455
|
-
tuple.kind_of? Hash and tuple.key?
|
456
|
-
tuple[
|
458
|
+
tuple.kind_of? Hash and tuple.key? client.tupelo_meta_key and
|
459
|
+
tuple[client.tupelo_meta_key] == "subspace"
|
457
460
|
end
|
458
461
|
end
|
459
462
|
|
@@ -504,10 +507,10 @@ class Tupelo::Client
|
|
504
507
|
def handle_transaction t
|
505
508
|
case
|
506
509
|
when t.open?
|
507
|
-
t.
|
510
|
+
t.prepare_ops
|
508
511
|
prep_waiters << t unless prep_waiters.include? t
|
509
512
|
when t.closed?
|
510
|
-
if t.read_only
|
513
|
+
if t.read_only
|
511
514
|
t.done global_tick, nil
|
512
515
|
else
|
513
516
|
t.submit
|
@@ -529,26 +532,32 @@ class Tupelo::Client
|
|
529
532
|
|
530
533
|
def handle_waiter waiter
|
531
534
|
if waiter.once
|
532
|
-
tuple =
|
535
|
+
tuple = tuplestore.find_match_for waiter.template
|
533
536
|
if tuple
|
534
537
|
waiter.peek tuple
|
535
538
|
else
|
536
539
|
read_waiters << waiter
|
537
540
|
end
|
538
541
|
else
|
539
|
-
|
542
|
+
tuplestore.each {|tuple| waiter.gloms tuple}
|
540
543
|
read_waiters << waiter
|
541
544
|
end
|
542
545
|
end
|
543
546
|
|
544
547
|
def handle_matcher matcher
|
545
548
|
if matcher.all
|
546
|
-
|
547
|
-
|
548
|
-
|
549
|
+
if defined? tuplestore.find_all_matches_for
|
550
|
+
tuplestore.find_all_matches_for matcher.template do |tuple|
|
551
|
+
matcher.peek tuple
|
552
|
+
end
|
553
|
+
else
|
554
|
+
tuplestore.each do |tuple|
|
555
|
+
matcher.gloms tuple
|
556
|
+
end
|
557
|
+
end
|
549
558
|
matcher.fails
|
550
559
|
else
|
551
|
-
tuple =
|
560
|
+
tuple = tuplestore.find_match_for matcher.template
|
552
561
|
if tuple
|
553
562
|
matcher.peek tuple
|
554
563
|
else
|
data/lib/tupelo/client.rb
CHANGED
@@ -7,14 +7,14 @@ module Tupelo
|
|
7
7
|
include Api
|
8
8
|
|
9
9
|
require 'tupelo/client/worker'
|
10
|
-
require 'tupelo/client/
|
10
|
+
require 'tupelo/client/tuplestore'
|
11
11
|
|
12
12
|
attr_reader :worker
|
13
|
-
attr_reader :
|
13
|
+
attr_reader :tuplestore
|
14
14
|
|
15
|
-
def initialize(
|
15
|
+
def initialize(tuplestore: SimpleTupleStore, subscribe: :all, **opts)
|
16
16
|
super **opts
|
17
|
-
@
|
17
|
+
@tuplestore = tuplestore
|
18
18
|
@worker = make_worker
|
19
19
|
@initial_subscriptions = subscribe || []
|
20
20
|
end
|
data/lib/tupelo/version.rb
CHANGED
data/test/lib/mock-client.rb
CHANGED
data/test/lib/testable-worker.rb
CHANGED
data/test/unit/test-ops.rb
CHANGED
@@ -30,7 +30,7 @@ class TestOps < Minitest::Test
|
|
30
30
|
log.formatter = MiniFormatter.new
|
31
31
|
end
|
32
32
|
c.blobber = Marshal
|
33
|
-
c.
|
33
|
+
c.tuplestore = Tupelo::Client::SimpleTupleStore
|
34
34
|
c.message_class = MockMessage
|
35
35
|
c.seq = seq.stream
|
36
36
|
c.worker = TestableWorker.new(c)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tupelo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '0.
|
4
|
+
version: '0.21'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Joel VanderWerf
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-03-
|
11
|
+
date: 2014-03-19 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: atdo
|
@@ -81,7 +81,7 @@ files:
|
|
81
81
|
- README.md
|
82
82
|
- Rakefile
|
83
83
|
- bench/pipeline.rb
|
84
|
-
- bench/
|
84
|
+
- bench/tuplestore.rb
|
85
85
|
- bin/tspy
|
86
86
|
- bin/tup
|
87
87
|
- bugs/read-take.rb
|
@@ -126,7 +126,6 @@ files:
|
|
126
126
|
- example/load-balancer.rb
|
127
127
|
- example/lock-mgr-with-queue.rb
|
128
128
|
- example/lock-mgr.rb
|
129
|
-
- example/map-reduce/ex.rb
|
130
129
|
- example/map-reduce/map-reduce-v2.rb
|
131
130
|
- example/map-reduce/map-reduce.rb
|
132
131
|
- example/map-reduce/prime-factor-balanced.rb
|
@@ -136,7 +135,7 @@ files:
|
|
136
135
|
- example/message-bus.rb
|
137
136
|
- example/multi-tier/drb.rb
|
138
137
|
- example/multi-tier/http.rb
|
139
|
-
- example/multi-tier/
|
138
|
+
- example/multi-tier/kvstore.rb
|
140
139
|
- example/multi-tier/memo.rb
|
141
140
|
- example/multi-tier/memo2.rb
|
142
141
|
- example/multi-tier/multi-sinatras.rb
|
@@ -160,15 +159,19 @@ files:
|
|
160
159
|
- example/riemann/producer.rb
|
161
160
|
- example/riemann/v1/expirer.rb
|
162
161
|
- example/riemann/v1/riemann.rb
|
162
|
+
- example/riemann/v2/event-sql.rb
|
163
163
|
- example/riemann/v2/expirer.rb
|
164
164
|
- example/riemann/v2/hash-store.rb
|
165
165
|
- example/riemann/v2/http-mode.rb
|
166
166
|
- example/riemann/v2/ordered-event-store.rb
|
167
167
|
- example/riemann/v2/riemann.rb
|
168
|
+
- example/riemann/v2/sqlite-event-store.rb
|
168
169
|
- example/small-simplified.rb
|
169
170
|
- example/small.rb
|
170
171
|
- example/socket-broker.rb
|
172
|
+
- example/sqlite/poi-client.rb
|
171
173
|
- example/sqlite/poi-store.rb
|
174
|
+
- example/sqlite/poi-template.rb
|
172
175
|
- example/sqlite/poi-v2.rb
|
173
176
|
- example/sqlite/poi.rb
|
174
177
|
- example/sqlite/tmp/poi-sqlite.rb
|
@@ -181,7 +184,7 @@ files:
|
|
181
184
|
- example/subspaces/shop/shop-v2.rb
|
182
185
|
- example/subspaces/simple.rb
|
183
186
|
- example/subspaces/sorted-set-space-OLD.rb
|
184
|
-
- example/subspaces/sorted-set-
|
187
|
+
- example/subspaces/sorted-set-store.rb
|
185
188
|
- example/take-many.rb
|
186
189
|
- example/take-nowait-caution.rb
|
187
190
|
- example/take-nowait.rb
|
@@ -193,6 +196,7 @@ files:
|
|
193
196
|
- example/transaction-logic.rb
|
194
197
|
- example/uniq-id.rb
|
195
198
|
- example/wait-interrupt.rb
|
199
|
+
- example/wip/complex-tags.rb
|
196
200
|
- example/wip/fish.rb
|
197
201
|
- example/wip/fish1.rb
|
198
202
|
- example/wip/fish2.rb
|
@@ -204,9 +208,9 @@ files:
|
|
204
208
|
- lib/tupelo/app/remote.rb
|
205
209
|
- lib/tupelo/app/trace.rb
|
206
210
|
- lib/tupelo/archiver.rb
|
207
|
-
- lib/tupelo/archiver/persistent-
|
211
|
+
- lib/tupelo/archiver/persistent-tuplestore.rb
|
208
212
|
- lib/tupelo/archiver/persister.rb
|
209
|
-
- lib/tupelo/archiver/
|
213
|
+
- lib/tupelo/archiver/tuplestore.rb
|
210
214
|
- lib/tupelo/archiver/worker.rb
|
211
215
|
- lib/tupelo/client.rb
|
212
216
|
- lib/tupelo/client/common.rb
|
@@ -214,7 +218,7 @@ files:
|
|
214
218
|
- lib/tupelo/client/scheduler.rb
|
215
219
|
- lib/tupelo/client/subspace.rb
|
216
220
|
- lib/tupelo/client/transaction.rb
|
217
|
-
- lib/tupelo/client/
|
221
|
+
- lib/tupelo/client/tuplestore.rb
|
218
222
|
- lib/tupelo/client/worker.rb
|
219
223
|
- lib/tupelo/tuplets/persistent-archiver.rb
|
220
224
|
- lib/tupelo/tuplets/persistent-archiver/tuplespace.rb
|