lib/dcell/celluloid_ext.rb in dcell-0.13.0 vs lib/dcell/celluloid_ext.rb in dcell-0.14.0
- old
+ new
@@ -71,11 +71,35 @@
end
class SyncCall
def _dump(level)
uuid = DCell::RPC::Manager.register self
- payload = Marshal.dump([@caller,@method,@arguments,@block])
- "#{uuid}@#{DCell.id}:#{payload}"
+ payload = Marshal.dump([@sender,@method,@arguments,@block])
+ "#{uuid}@#{DCell.id}:rpc:#{payload}"
+ end
+
+ def self._load(string)
+ DCell::RPC._load(string)
+ end
+ end
+
+ class BlockProxy
+ def _dump(level)
+ uuid = DCell::RPC::Manager.register self
+ payload = Marshal.dump([@mailbox,@execution,@arguments])
+ "#{uuid}@#{DCell.id}:rpb:#{payload}"
+ end
+
+ def self._load(string)
+ DCell::RPC._load(string)
+ end
+ end
+
+ class BlockCall
+ def _dump(level)
+ uuid = DCell::RPC::Manager.register self
+ payload = Marshal.dump([@block_proxy,@sender,@arguments])
+ "#{uuid}@#{DCell.id}:rpbc:#{payload}"
end
def self._load(string)
DCell::RPC._load(string)
end