Skip to main content

Cannot deploy web service in GlassFish using together @WebserviceProvider and @Stateless

2 replies [Last post]
silvery
Offline
Joined: 2012-01-12

I tried to deploy in GlassFish JAX-WS web service,
Here is a snippet of class were the web service is defined. Pay attention that I use @WebServiceProvider but not @WebService

@Stateless(name = "HelloWorldEJBWS")
    @WebServiceProvider(
portName = "HelloWorldWSPort",
serviceName = "HelloWorldWSService",
targetNamespace = "http://ivan.com/",
wsdlLocation ="HelloWorldEJBProvider.wsdl")

    @ServiceMode(value = Service.Mode.PAYLOAD)

    public class HelloWorldEJBWS implements Provider<Source> {

    public Source invoke(final Source inRequestMessage) {

...
}
    }

The problem is about the deploying the service in GlassFish (3.1.2.2) .

[#|2012-09-08T16:39:15.682-0400|INFO|glassfish3.1.2|javax.enterprise.system.container.ejb.com.sun.ejb.containers|_ThreadID=20;_ThreadName=Thread-2;|EJB5181:Portable JNDI names for EJB HelloWorldEJBWS: [java:global/JAX-WS_GreetingEJBMutualAuthProvider/HelloWorldEJBWS, java:global/JAX-WS_GreetingEJBMutualAuthProvider/HelloWorldEJBWS!javax.xml.ws.Provider]|#]

[#|2012-09-08T16:39:15.792-0400|INFO|glassfish3.1.2|javax.enterprise.webservices.org.glassfish.webservices|_ThreadID=20;_ThreadName=Thread-2;|WS00019: EJB Endpoint deployed
JAX-WS_GreetingEJBMutualAuthProvider listening at address at http://localhost:8088/HelloWorldWSService/com.ivan.wsejb.provider.HelloWorldEJBWS|#]

Even it shows the endpoint is deployed is not . I can't reach this endpoint and it is not shown in GlassFish console.

For comparison I provide the log when I deployed the service using @WebService but not @WebServiceProvider

[#|2012-09-08T16:41:50.514-0400|INFO|glassfish3.1.2|javax.enterprise.webservices.org.glassfish.webservices|_ThreadID=22;_ThreadName=Thread-2;|WS00019: EJB Endpoint deployed
JAX-WS_GreetingEJBMutualAuth listening at address at http://localhost:8088/HelloWorldEJBWSService/HelloWorldEJBWS|#

Here endpoint deployed correctly and everything is working fine.

Here is snipped of the code when I apply @WebService

    @Stateless(name = "HelloWorldEJBWS")
    @WebService()
    public class HelloWorldEJBWS {

public String hello(final String inMessage) {
...
}
   }

Did I do something wrong ?

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Anonymous

The issue has been resolved ... See
http://www.java.net/comment/reply/890336/825589

--

[Message sent by forum member 'silvery']

View Post: http://forums.java.net/node/889988

silvery
Offline
Joined: 2012-01-12

The issue has been resolved ... See http://www.java.net/comment/reply/890336/825589