def received(calling_obj)
handler = nil
@handler_lock.synchronize do
handler = @handler_table[calling_obj.name]
end
if handler.nil? then
add_queue_error(calling_obj.sid,R_PROTOCOL_ERROR,
"NoSuchMethodException",
"Not found the remote method #{calling_obj.name}.","")
return
end
Thread.start(calling_obj,handler) do |cobj,hd|
dputs ": methodInvodation: Start: #{cobj.name} : #{cobj.sid}"
begin
ret = hd.call(*cobj.args)
add_queue_result(cobj.sid,ret)
rescue => evar
dputs ": exception was occured: #{evar.message}"
add_queue_error(cobj.sid,R_APP_ERROR,evar.class.to_s,
evar.message,evar.backtrace.join("\n"))
ensure
dputs ": methodInvodation: End : #{cobj.name} : #{cobj.sid}"
end
end
end