[python-win32] Windows Vista slow down Python xmlrpc
caxelrud
caxelrud at pav.com
Thu Mar 6 14:06:33 CET 2008
I tried the following simple code for client-server comunication with xmlrpc
in Wiindows XP and Windows Vista (Python 2.5(r25:51908)). The Vista hardware
was classified as 2x faster then the other.
I got the following results:
Vista: 10.1 sec
XP: 0.12 sec
The XP was about 100 times faster !
Does anybody now how to seepup the Vista execution?
Server.py file:
-----------------------------------------------------------------
import SimpleXMLRPCServer
import math
def add(x,y):
"Add two numbers"
return x+y
s=SimpleXMLRPCServer.SimpleXMLRPCServer(("localhost",8080))
s.register_function(add)
s.register_instance(math)
s.register_introspection_functions()
s.serve_forever()
-----------------------------------------------------------------
Client.py file:
-----------------------------------------------------------------
import xmlrpclib
import time
s=xmlrpclib.ServerProxy("http://localhost:8080")
tinit=time.time()
for i,j in zip(xrange(10),xrange(10,20)):
print s.add(i,j)
tend=time.time()
dtime=tend-tinit
print "dtime:",dtime
raw_input("Enter")
-----------------------------------------------------------------
--
View this message in context: http://www.nabble.com/Windows-Vista-slow-down-Python-xmlrpc-tp15872996p15872996.html
Sent from the Python - python-win32 mailing list archive at Nabble.com.
More information about the python-win32
mailing list