[jboss-user] [JBoss Web Services] New message: "Re: JBOss5.1.0-GA WS endpoint generated with wsconsume does not deploy"

Jan Uhlir do-not-reply at jboss.com
Tue Jan 12 06:49:08 EST 2010

User development,

A new message was posted in the thread "JBOss5.1.0-GA WS endpoint generated with wsconsume does not deploy":


Author  : Jan Uhlir
Profile : http://community.jboss.org/people/espinosa_cz

Is you class annotated with @WebService? That is what deployment scanner is looking for. Your service definitively does not have to be a Servlet subclass. I wonder if you need web.xml at all, in theory the annotation is all you need, everything else can be generated and defaulted reasonably for you.
Here is my working example. POJO service class, JBoss 5.1.0.GA, Maven project, WAR archive.
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5" ....>

jboss-web.xml  (not essential just to have a nice context root):
<?xml version="1.0" encoding="UTF-8"?>
    <!-- Exist here for sole reason of defining context root. There is no way how to do it in web.xml. This this JBoss specific way.
     Glassfish has a similar configuration file where you can do the same.
     - make EAR file and specify context root for the web module in standard application.xml file.
     - make it EJB JAR file. But WebService must be also an EJB3 then. Then there is no context root (?)
     see: http://docs.jboss.org/jbossas/guides/webguide/r2/en/html/ch06.html
 * Web service implementation
public class FooService {
    public static final Logger log = Logger.getLogger(FooService.class.getName());
    public void fooMethod1(String command) {
        log.info("fooMethod2: " + command);
    public String fooMethod2(String command) {
        log.info("fooMethod2: " + command);
        return "OK";


To reply to this message visit the message page: http://community.jboss.org/message/519483#519483

More information about the jboss-user mailing list