Re: [Zope-dev] Will ZServer help me in this scenario?
Skip> Will I need to make changes to Fredrik Lundh's XML-RPC code to Skip> make this work? Amos> I don't know much about this code, but I doubt it is causing any Amos> concurrency issues or otherwise for you. I guess what I meant to say is will I need to modify the I/O that XML-RPC does to take advantage of Medusa's multi-threading I/O? Alternatively, will not making a change reduce or eliminate the multi-threading? Fredrik's xmlrpclib module uses vanilla httplib to communicate with the server. Does loading asnycore/asynchat do something to fiddle with the I/O in standard packages or do you have to explicitly modify them to use it? Thx, Skip Montanaro | Mojam: "Uniting the World of Music" http://www.mojam.com/ skip@mojam.com | Musi-Cal: http://www.musi-cal.com/ 518-372-5583
On Sat, Mar 06, 1999 at 05:01:25PM -0500, skip@mojam.com wrote:
Skip> Will I need to make changes to Fredrik Lundh's XML-RPC code to Skip> make this work?
Amos> I don't know much about this code, but I doubt it is causing any Amos> concurrency issues or otherwise for you.
I guess what I meant to say is will I need to modify the I/O that XML-RPC does to take advantage of Medusa's multi-threading I/O? Alternatively, will not making a change reduce or eliminate the multi-threading? Fredrik's xmlrpclib module uses vanilla httplib to communicate with the server. Does loading asnycore/asynchat do something to fiddle with the I/O in standard packages or do you have to explicitly modify them to use it?
You might look at some of what Sam has done in the latest releases of Medusa... it has some integration with XML-RPC in an MAJOR alpha level. It might be a good starting point though. Chris -- | Christopher Petrilli ``Television is bubble-gum for | petrilli@amber.org the mind.''-Frank Lloyd Wright
At 05:01 PM 3/6/99 -0500, you wrote:
Skip> Will I need to make changes to Fredrik Lundh's XML-RPC code to Skip> make this work?
Amos> I don't know much about this code, but I doubt it is causing any Amos> concurrency issues or otherwise for you.
I guess what I meant to say is will I need to modify the I/O that XML-RPC does to take advantage of Medusa's multi-threading I/O?
Hmm. If you want to do your I/O using async sockets, you'll need to do a little digging. As someone mentioned, I think there's a start at that in the medusa distribution, or at least in CVS.
Alternatively, will not making a change reduce or eliminate the multi-threading?
I'm not sure I completely understand, but let me pose this scenario. ZServer handles I/O between the browser and your published Python module. It uses async sockets. Your published module uses xmlrpc over vanilla httplib to get some data from another server. Then the results are sent back to the browser by ZServer. This seems like the preferred solution to me. I can't think of any reason not to do the above, and it would be much simpler than trying to figure out how to use async sockets in your published module.
Fredrik's xmlrpclib module uses vanilla httplib to communicate with the server. Does loading asnycore/asynchat do something to fiddle with the I/O in standard packages or do you have to explicitly modify them to use it?
asyncore doesn't change your sockets, it just provides a framework to handle them for you. So you won't have a problem if you decide to do some socket communication without the framework. In fact in your case I suspect that everything will flow much more sanely if you ignore asyncore and do your socketing that way you're used to. Good luck. -Amos
participants (3)
-
Amos Latteier -
Christopher G. Petrilli -
skip@mojam.com