Tornado and Soap web services in python 3.x

443 views
Skip to first unread message

Abhishek Mishra

unread,
Apr 9, 2014, 6:54:17 AM4/9/14
to python-...@googlegroups.com

Hello,
I am doing a project which uses soap protocol over HTTP. I used Tornado and Inbuild soap library in Tornado WS. I am facing the following problem. Please help us.

1. Can any one tell that whether tornado along with soap web service is available for Python 3.x.
I have tried many soap libraries but found that they are not working on python 3.x, Though they are working on 2.x

2. Please share the details of soap libraries which is compatible with python 3.x and tornado.

3. Is there any pre build version available for the above.


Thanks
Abhishek Misra

Rodrigo Ancavil

unread,
Apr 14, 2014, 2:12:22 PM4/14/14
to python-...@googlegroups.com
Hi, Abhishek.

I made changes to my API tornado-webservices (https://github.com/rancavil/tornado-webservices) to work with Python 3.3.

tornado-webservices is a SOAP API to work over Tornado.

You can install with:

pip install tornado-webserver

Regards. Rodrigo


--
You received this message because you are subscribed to the Google Groups "Tornado Web Server" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python-tornad...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Shafiul Azam

unread,
Apr 15, 2014, 12:14:05 AM4/15/14
to python-...@googlegroups.com
Hi,

Can I use this to:

1. Expose web services (not consume)
2. Use complex data type for both input and output
3. Auto generate WSDL

I'm currently using Ladon but it has some bugs. Also I already have a Tornado setup with Python 3.X, so I'm heavily looking forward if I can use this instead!

Regards,
--
Shafiul Azam Chowdhury
Senior Software Engineer, AppDragon
Mozilla Rep, Mozilla

My Blog: http://bdhacker.wordpress.com
Phone: 8801717-922569
Twitter: @ishafiul
Mozilla Bangladesh: http://mozillabd.org

Rodrigo Ancavil

unread,
Apr 15, 2014, 9:47:44 AM4/15/14
to python-...@googlegroups.com
Hi, If you are talking of tornado-webservices api, Yes...

1 You can expose web service: http://tws33-rigby.rhcloud.com/CertService?wsdl
2. Yes, you can see here https://github.com/rancavil/tornado-webservices/blob/master/demos/RegisterService.py
3. Yes, the WSDL is generated automaticaly from the classes.

Regards. Rodrigo.

Ebrima Tunkara

unread,
May 18, 2014, 1:37:05 PM5/18/14
to python-...@googlegroups.com
Hi I really like your work and I think it is very useful.I have been trying to initialized  the webservice class
where i can pass in the persistent object such the domain_manager .
How can i initialize the soap webservice class and pass a parameter in the constructor  on the server side only?

example here is the code
#cloud service
class CloudService(soaphandler.SoapHandler):
        def initialize(self, domain_manager):
            self.domain = domain_manager

        @webservice(_params=str,_returns=Output)
        def test(self, input):
                output = Output()
                output.success.value  = True
                output.message.value ="Testing soap!  "
                for num in range(10,100000):
                  self.client(num)
                return output

and i want to pass the 
def run(self):
      try:
         #initialize the domain manager
          self.domain_manager = DomainManager(SERVER_CONFIG['cloud_database'])
service = [('Authenticate',Authenticate),('CloudService',CloudService,dict(domain_manager=self.domain_manager))]
app = webservices.WSGIWebService(service,**settings)
      except:
         .......


The problem is on the client  when i  try connecting the CloudService 
this is error i got on the server side
initialize() takes exactly 2 arguments (1 given)

Shafiul Azam

unread,
Jul 21, 2014, 12:50:14 PM7/21/14
to python-...@googlegroups.com
Hi Rodrigo,

Thanks a lot for your helpful package. We've been using it.
Can you tell me how do we make a field of a complex-type element optional? So that if we do not include that field of the complex-type object in request, the server will not throw faultstring?

Thanks a lot.
Reply all
Reply to author
Forward
0 new messages