+

Search Tips   |   Advanced Search

Web services support in EJB


WAS ND v7.0 complies with the Java EE and Enterprise Java Beans (EJB) specifications by enabling you to expose an EJB stateless session bean as a Web service.

WAS ND v7.0 supports the Java API for XML Web Services (JAX-WS) 2.0 programming model and the EJB 3.0 specification.

EJB 3.0 does not support the @WebService or @WebMethod annotations on EJB 3.0 stateless session beans, which are used to identify the stateless session bean as a JAX-WS implementation, nor does it support injection of Web services references. We can invoke EJB 3.0 beans indirectly by defining a servlet as the JAX-WS implementation and placing code in the servlet which invokes the target EJB 3.0 bean.

We can do this by declaring a link between the desired endpoint name in the Web service deployment descriptor of the EJB module. During deployment and installation of the bean into the appserver environment, the bean is linked to the specified Web service endpoint.

If writing a stateless session bean to implement a preexisting WSDL interface, remember to implement in the bean all of the methods defined on the WSDL interface.

See Implementing Web services applications with JAX-WS.



Related concepts


Enterprise beans

 

Related tasks


Develop enterprise beans

 

Related


Enterprise bean development best practices
Unknown primary-key class