开发者

Best practices for an internal webservice

Experience says that using WSDL-SOAP based webservice for internal consumption is an overkill. There are too many service-based POJO classes that when let into the system complicates it way too much. One option would be use adapter pattern, map the request/response objects to internal d开发者_如何转开发omain classes. But is it even required? Is there a better approach? What are your suggestions?


Yes, WSDL/SOAP (or WS-* in general) is an overkill because it simply adds another layer to solve problems that have already been solved by Web architecture. In fact, they have been solved much better.

In the Java world, you are likely to find the simplicity you are looking in JAX-RS (RESTful Java Web service). The Jersey project is the reference implementation of JAX-RS and among other neat features comes with a very easy to use serialization/deserialization approach.

Jersey: http://jersey.java.net/ Example Applications: http://wikis.sun.com/display/Jersey/Main (scroll down)

HTH, Jan


Have a look at the CAJO project:

http://en.wikipedia.org/wiki/Cajo_project

Should allow JVM's to talk together if that is what you need.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜