Python web service

会有一股神秘感。 提交于 2019-12-10 09:39:52

问题


I'm doing server/client application similar to Ubuntu Landscape (http://www.canonical.com/enterprise-services/ubuntu-advantage/landscape) for my school project. The client part of application will send different informations (disk usage, packages etc.) to server. I know how to get informations and hot I'll handle them on the server side. But I don't know how what is the best way to exchange informations. Would SOAP be ok or is there any better way for doing this? Messages can be large (for example a list of installed packages) or very small. I was looking at Twisted but don't know where to start. I have experience with SOAP in PHP, Java and C#.

And recommnedation is welcome, thanks


回答1:


Look into XMLRPC or JSON-RPC which is likely supported in some why by all language through modules or packages.

SOAP is a complete bloat and widely considered as a failed hype.




回答2:


I recommend using flask or smisk. Both frameworks are REST based, powerful, lightweight and pythonic. Flask is probably more mature and maintained. If you go down the SOAP road, you'll regret it sooner or later.



来源:https://stackoverflow.com/questions/6642999/python-web-service

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!