I'm currently running python suds against a wsdl file and its corresponding 50+ xsd files. The following call to Client
takes about 90 seconds:
from suds.client import Client
url = 'http://localhost:7080/webservices/WebServiceTestBean?wsdl'
client = Client(url)
After I run the last line above, I get a Client
instance. Creating that client takes a long time. Does caching work with Python objects or is it restricted to primitives like strings and integers?
Here's what I want to do in code, the syntax is wrong but it's to convey what I want:
from suds.client import Client
if 'current_client' in cache:
client = cache.get('current_client')
else:
url = 'http://localhost:7080/webservices/WebServiceTestBean?wsdl'
client = Client(url)
cache.put('current_client', client)