From: m_seki@... Date: 2002-03-03T05:34:16+09:00 Subject: Re: druby question (bug?) Hi, I'm poor at English. I may not understand correctly what you say. > 1) Is there a way to force DRb to always pass methods back to the server > and let the server decide on the method's validity? Or, to put it a > different way, is there a way to force DRb to only pass object ids back > and forth across the wire instead of the stringified object? You have two methods. * DRbUndumped Mixin. DRbUndumped is the module in which dump is made to fail. class Proxy include DRbUndumped .... end * DRbObject.new Implementation of pass by reference is pass by copy of DRbObject. You can use DRbObject.new for pass by reference. class Server def authenticate proxy = Proxy.new return DRbObject.new(proxy) end end Note: In pass by reference, You have to protect original object from GC. There are some methods. An easy method is shown below. class Proxy include DRbUndumped .... end class Server def initialize @proxy = Proxy.new # keep a proxy end def authenticate return @proxy end end > 2) Does my sample code below work as expected? Should DRb really raise > an error "undefined method 'serverName'" ? Your client.rb does not know Proxy class. Client.rb can't load Proxy object. dRuby system changes into DRbUnknown the object which cannot be loaded. DRbUnknown#serveName is not defined. Please define Proxy class in client.rb and try once again. You will find a different. Thanks.