On Sat, Aug 15, 2009 at 2:51 PM, Rui Ma<[email protected]> wrote: > > I finished a prototype to run ruote engine as a DRb server for multiprocess > deployments.
Hello Rui Ma, you're fast ! Looks very neat. > Ruote-rest is the current way to use ruote engine in a multiprocess > environment. But developers need to write code to take care of the > underlying communication between models and ruote-rest server. > > A DRb ruote server provides an alternative way to deploy ruote in a > multiprocess environment. The primary benefit of using it is that developers > can still use ruote as the way of ruote-web2 client code, without > adding/chaning client code for multiprocess depolyment. > > Another concern is that using TCP/UNIX socket might be faster than > initiating internal HTTP requests in terms of the ruote server/client > communications. > > I am not sure either ruote-rest or drb server is thread-safe. Maybe the > only way to provide ruote with a thread-safe multiprocess environment is to > implement workitem level lock. Since I'm working on ruote 2.0 and making sure multiprocess deployments do not interfere with ruote, I worked on locking access to scheduler queues (so that timeouts and such scheduled events get triggered on time and only once for the whole pack of engines) and to tracker queues (so that a listen expression (not very often used, I know) is triggered once for the whole pack of engines). For workitems themselves, thread-safe measures brought by active-record itself should suffice. > I put together DRb server/client code here: > http://github.com/ruima-nyc/ruote-web2 > > running it: > > cd ruote-web2 > ruby script/ruote_server.rb > ruby script/server > > Rui Ma > http://rui.ma Well done, John --~--~---------~--~----~------------~-------~--~----~ you received this message because you are subscribed to the "ruote users" group. to post : send email to [email protected] to unsubscribe : send email to [email protected] more options : http://groups.google.com/group/openwferu-users?hl=en -~----------~----~----~----~------~----~------~--~---
