| Web Service Bundles |
|
|
In Dynamic-WS, Web Service are deployed using Web Service Bundles. What differs a Web Service Bundle from any other bundle is that it contains Web Service Descriptors. Web Service Descriptor is a file that provides information needed by the Web Service Engine to run a Web Service, such information could contain Web Service's implementation class, WSDL file's location, Binding Info, etc. Usually, every Web Service Engine has its own descriptor file, in a traditional Web Application the descriptor file will mostly exist in the “/WEB-INF” directory of the Web Application, in Dynamic-WS it exists in the “/META-INF” directory of the Web Service Bundle. For instance, if you use JAX-WS RI in a traditional Web Application you will place the descriptor file “sun-jaxws.xml” in the “/WEB-INF” directory, but if you use Dynamic-WS with JAX-WS RI as your Web Service Engine then you will place the same descriptor file in the “/META-INF” directory of the Web Service Bundle. You don't need to have all the classes consumed by the descriptor (e.g., Web Service contract class, Web Service implementation class, etc.) in the Web Service Bundle as long as the bundle imports the packages that contains the used classes. Web Service Engines other than JAX-WS RI (most notable are Apache Axis2 and Apache CXF) are currently not supported, but there is intention to support these two engines as soon as possible. Some Web Service Engines like JAX-WS RI and CXF support the declaration of Web Services in Spring context files. The upcoming release of Dynamic-WS will allow the declaration of Web Services using Spring. JAX-WS Reference Implementation with Dynamic-WSFrom what mentioned above, to deploy a Web Service in a bundle with Dynamic-WS using JAX-WS RI as the Web Service Engine, all you need to do is to place the “sun-jaxws.xml” (the descriptor file that contains information about your Web Services) file in the “/META-INF” directory of the bundle and make sure that the bundle either contains Web Service's classes or imports the packages that contain them. To examine a Web Service Bundle that uses JAX-WS RI as the Web Service Engine, please, check the Examples section. |