users@glassfish.java.net

Re: _at_EJB injection for an _at_WebService object only works from the Admin Cons

From: <glassfish_at_javadesktop.org>
Date: Thu, 27 Mar 2008 07:36:22 PST

Hi,

I found out the cause of the problem, but I would still consider registering this as either a bug or an RFE.

In my web.xml file, I am defining the servlet associated to the web service as /RoamGateway:

    <servlet-mapping>
        <servlet-name>RoamGatewayService</servlet-name>
        <url-pattern>/RoamGateway</url-pattern>
    </servlet-mapping>

The web application is named ws and the, so therefore the URL that all of my client are using is "ws/RoamGateway". We have PHP, J2ME, Java and MS applications hitting this service with this URL. The web service will work, but local EJB injection fails. So the remote interface had to be called, with made for a miserable performance hit.

I then looked closer at what the Admin Console was using for a URL, and it was using a completely different URL to access the web service. It was using "ws/RoamGatewayImplService". When I rewrote my test clients to use this URL instead, injection began working.

The problem I have is that my service is accessible via 2 completely separate URLs, the later one being unconfigurable by the author and completely disassociated with the URL defined in the web.xml. In other works, I need to refer to the admin console for every WS I author in order to see what the heck the REAL endpoint URL is.

I'd be hard pressed to believe that this is functioning as designed.

David
[Message sent by forum member 'dlindsay_roamdata_com' (dlindsay_roamdata_com)]

http://forums.java.net/jive/thread.jspa?messageID=266239