By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,537 Members | 1,444 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,537 IT Pros & Developers. It's quick & easy.

Python SOAP and XML-RPC performance extremely low?

P: n/a
When I try TooFPy with the SOAP and XML-RPC sample client code
provided in TooFPy tutorials, a log entry shows up quickly on web server
log window, but it takes a long time (5 seconds or longer) for the client
to output a "Hello you." It seems like the web server is fast because the
log
entry shows immieidately on web server console. But it takes Python XML/SOAP
parser a long time to parse the extremely simple result. If so, wouldn't
this
render Python SOAP and XMP-RPC implementation useless in real life?
Jul 6 '06 #1
Share this Question
Share on Google+
8 Replies


P: n/a

JackWhen I try TooFPy with the SOAP and XML-RPC sample client code
Jackprovided in TooFPy tutorials, a log entry shows up quickly on web
Jackserver log window, but it takes a long time (5 seconds or longer)
Jackfor the client to output a "Hello you."

For XML-RPC are you using sgmlop or some other accelerator? If not, you
might want to consider it.

Skip
Jul 6 '06 #2

P: n/a
Jack wrote:
When I try TooFPy with the SOAP and XML-RPC sample client code
provided in TooFPy tutorials, a log entry shows up quickly on web server
log window, but it takes a long time (5 seconds or longer) for the client
to output a "Hello you." It seems like the web server is fast because the
log
entry shows immieidately on web server console. But it takes Python XML/SOAP
parser a long time to parse the extremely simple result. If so, wouldn't
this
render Python SOAP and XMP-RPC implementation useless in real life?

5 secs looks really huge to just parse an "extremely simple" message. I'd rather
suspect some sort of timeout delay.
Jul 6 '06 #3

P: n/a
No, I'm not using any accelerator. The code is extremely simple (from
toofpy):

# XML-RPC test
import xmlrpclib
srv = xmlrpclib.Server('http://localhost:4334/RPC2/greeting')
print srv.greeting('you', 5)

# SOAP test
import SOAPpy
srv = SOAPpy.SOAPProxy('http://localhost:4334/SOAP/greeting')
print srv.greeting('you', 5)

It really surprised me that they were so slow to execute.

<sk**@pobox.comwrote in message
news:ma***************************************@pyt hon.org...
>
JackWhen I try TooFPy with the SOAP and XML-RPC sample client code
Jackprovided in TooFPy tutorials, a log entry shows up quickly on web
Jackserver log window, but it takes a long time (5 seconds or longer)
Jackfor the client to output a "Hello you."

For XML-RPC are you using sgmlop or some other accelerator? If not, you
might want to consider it.

Skip

Jul 7 '06 #4

P: n/a
Jack wrote:
When I try TooFPy with the SOAP and XML-RPC sample client code
provided in TooFPy tutorials, a log entry shows up quickly on web server
log window, but it takes a long time (5 seconds or longer)
okay, 5 seconds...
No, I'm not using any accelerator. The code is extremely simple (from
toofpy):

# XML-RPC test
import xmlrpclib
srv = xmlrpclib.Server('http://localhost:4334/RPC2/greeting')
print srv.greeting('you', 5)
and a "5" as the second argument in the greeting call. I wonder what
that does ? ;-)

(if you need a hint, look for "waits the given number of seconds" on
this page:

http://pyds.muensterland.org/wiki/to...tartguide.html

)

</F>

Jul 7 '06 #5

P: n/a
Ha! Thanks Fredrik for the big hint :) I wasn't careful when reading that
page.
Was in too much of a hurry to try the code :)
and a "5" as the second argument in the greeting call. I wonder what that
does ? ;-)

(if you need a hint, look for "waits the given number of seconds" on this
page:

http://pyds.muensterland.org/wiki/to...tartguide.html

)

</F>

Jul 7 '06 #6

P: n/a

JackNo, I'm not using any accelerator. The code is extremely simple
Jack(from toofpy):
...

To use sgmlop, just download and install it. Your code doesn't need to
change. The xmlrpclib module detects its presence and uses it
automatically.

As someone else noted though, a five-second delay for such a small example
doesn't seem to be an XML-RPC problem. A simple round-trip to my XML-RPC
server running on the localhost takes about 5 *milli*seconds. That's with
sgmlop installed, but even without it, I can't imagine it taking more than
50-100 ms.

Skip
Jul 7 '06 #7

P: n/a
sk**@pobox.com wrote:
As someone else noted though, a five-second delay for such a small example
doesn't seem to be an XML-RPC problem. A simple round-trip to my XML-RPC
server running on the localhost takes about 5 *milli*seconds.
even if the service you're connecting is waiting 5 seconds before it
sends the response ? ;-)

</F>

Jul 7 '06 #8

P: n/a
>As someone else noted though, a five-second delay for such a small
example doesn't seem to be an XML-RPC problem. A simple round-trip
to my XML-RPC server running on the localhost takes about 5
*milli*seconds.
Fredrikeven if the service you're connecting is waiting 5 seconds
Fredrikbefore it sends the response ? ;-)

Well, yeah I suppose that might have an effect. ;-) I saw your earlier
response about a minute after I responded...

Skip
Jul 7 '06 #9

This discussion thread is closed

Replies have been disabled for this discussion.