1 Reply Latest reply on Feb 28, 2015 6:48 AM by Xavier Dury

    Configuring @WebServiceRef on EJB via XML in AS7

    Xavier Dury Newbie

      Hi,

       

      I have some EJBs that call WebServices. In JBoss AS5, I had something like that:

       

      {code}@Stateless

      public class MyServiceBean implements MyService {

       

           @WebServiceRef(name = "services/MyWebService")

           MyWebPort myWebService;

       

           ...

      }{code}

       

      jboss.xml:

       

      {code:xml}<session>

           <ejb-name>MyServiceBean</ejb-name>

           <service-ref>

                <service-ref-name>services/MyWebService</service-ref-name>

                <service-impl-class>eg.MyWebService</service-impl-class>

                <port-component-ref>

                     <service-endpoint-interface>eg.MyWebPort</service-endpoint-interface>

                     <stub-property>

                          <prop-name>javax.xml.ws.service.endpoint.address</prop-name>

                          <prop-value>http://some.url.here</prop-value>

                     </stub-property>

                </port-component-ref>

           </service-ref>

      </session>{code}

       

      Now that I've migrated to JBoss AS7, jboss-ejb3.xml is used instead of jboss.xml. But it seems I can't use custom jboss elements in it.

       

      So how do I achieve this in AS7?

       

      Thanks,

       

      Xavier