Java Tutorial - Java Scipt : Architectural Considerations

Java Tutorial - Java Scipt :

Architectural Considerations


The primary function of Web services is to facilitate interaction with external systems and clients. For this reason, Java Web services are at the edges of the J2EE architecture. Web services need to be accessible and understandable by those external systems and clients at the very least. These issues are addressed by SOAP and WSDL, respectively. These two World Wide Web Consortium (W3C) standards are the basic building blocks of platform-independent Web services today. The JAX/RPC API and the Apache Axis implementation of that
API are used to expose those Web services according to standards.

Existing components, such as EJBs, can be wrapped and made accessible as Java Web services. The procedure for doing so is exactly the same as writing any other EJB client. On the other side of the fence, almost any Java component, from servlets to EJBs, can consume Web services. This process is made much easier by Apache Axis’s Java stub generator. We will examine this in more detail in the examples in this chapter.

Java Web services are typically deployed in the servlet engine. In fact, Axis itself is commonly deployed as a Web application, with Web services processed via JSP. Architecturally, the comparison is very valid and a useful analogy for thinking about how the pieces fit together.