Sha256: cd4f98e2296f8958a5c054c2bd4aa3c40a129b40f4c2b5e44a14405777217851
Contents?: true
Size: 573 Bytes
Versions: 1
Compression:
Stored size: 573 Bytes
Contents
module Rinda # dirty monkey patching to retrieve unique running ID, primitiv einc beacuse touble nested tuplebag storage with symbols. class TupleSpace def initialize(period=60) super() @bag = TupleBag.new @read_waiter = TupleBag.new @take_waiter = TupleBag.new @notify_waiter = TupleBag.new @period = period @keeper = nil @id = 0 end def writeID(tuple,sec=nil) synchronize do @id =@id+1 tuple["id"] = @id write(tuple,sec) @id end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
dm-rinda-adapter-0.1.2 | lib/rinda-patch.rb |