10 Replies Latest reply on Apr 29, 2005 6:01 AM by thomas.diesler

    Problems by deploying the WS-Wiki-Example

    knutschik

      Hi all,
      I have a problem by deploying the wiki-WS-Example in JBoss-4.0.1. I have used the ws.war. Here is the exception:
      09:17:21,105 ERROR [ServiceDeployer] Cannot startup webservice for: ws.war
      java.lang.NoClassDefFoundError
      at org.jboss.webservice.ServiceDeployerJSE.class$(ServiceDeployerJSE.jav
      a:43)
      at org.jboss.webservice.ServiceDeployerJSE.getServiceEndpointServletName
      (ServiceDeployerJSE.java:191)
      at org.jboss.webservice.ServiceDeployer.modifyServletConfig(ServiceDeplo
      yer.java:401)
      at org.jboss.webservice.ServiceDeployerJSE.modifyWebXMLDocument(ServiceD
      eployerJSE.java:183)
      at org.jboss.webservice.ServiceDeployerJSE.modifyWebXML(ServiceDeployerJ
      SE.java:121)
      at org.jboss.webservice.ServiceDeployerJSE.createWebservice(ServiceDeplo
      yerJSE.java:95)
      at org.jboss.webservice.ServiceDeployer.handleNotification(ServiceDeploy
      er.java:109)
      at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
      sorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.notification.NotificationListenerProxy.invoke(Notificati
      onListenerProxy.java:138)
      at $Proxy31.handleNotification(Unknown Source)
      at org.jboss.mx.util.JBossNotificationBroadcasterSupport.handleNotificat
      ion(JBossNotificationBroadcasterSupport.java:112)
      at org.jboss.mx.util.JBossNotificationBroadcasterSupport.sendNotificatio
      n(JBossNotificationBroadcasterSupport.java:95)
      at org.jboss.deployment.SubDeployerSupport.create(SubDeployerSupport.jav
      a:203)
      at org.jboss.web.AbstractWebContainer.create(AbstractWebContainer.java:3
      41)
      at org.jboss.deployment.MainDeployer.create(MainDeployer.java:918)
      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:774)
      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:738)
      at sun.reflect.GeneratedMethodAccessor44.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
      sorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatch
      er.java:144)
      at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
      at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractIntercept
      or.java:122)
      at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
      at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelM
      BeanOperationInterceptor.java:131)
      at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
      at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
      java:249)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:642)
      at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
      at $Proxy8.deploy(Unknown Source)
      at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymen
      tScanner.java:305)
      at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentS
      canner.java:481)
      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.
      doScan(AbstractDeploymentScanner.java:204)
      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.
      loop(AbstractDeploymentScanner.java:215)
      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.
      run(AbstractDeploymentScanner.java:194)
      Caused by: java.lang.ClassNotFoundException: Unexpected error during load of: or
      g.jboss.webservice.server.ServiceEndpointServletJSE, msg=org/jboss/webservice/se
      rver/ServiceEndpointServlet
      at org.jboss.mx.loading.RepositoryClassLoader.loadClassImpl(RepositoryCl
      assLoader.java:501)
      at org.jboss.mx.loading.RepositoryClassLoader.loadClass(RepositoryClassL
      oader.java:374)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
      at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
      at java.lang.Class.forName0(Native Method)
      at java.lang.Class.forName(Class.java:141)
      ... 37 more
      Can somebody help me?
      caio
      rmk

        • 1. Re: Problems by deploying the WS-Wiki-Example
          jason.greene

          Do you have a type-o in your servlet-class tag? Is that class in the war?

          -Jason

          • 2. Re: Problems by deploying the WS-Wiki-Example
            sidazad

            Hi,
            I have the same exception. Did you find a solution to this? The class in the servlet-class tag is present in the war file classes directory but it is not a Servlet class since it is being used to deploy a web service, as described in the JBossWS document style web services tutorial.
            The class declaration is :

            public class SidTestWrappedImpl implements SidTestWrapped {}
            
            public interface SidTestWrapped extends Remote {}
            


            Thx, Sid.

            • 3. Re: Problems by deploying the WS-Wiki-Example
              jason.greene

              Looking at the trace again I noticed the following:

              Caused by: java.lang.ClassNotFoundException: Unexpected error during load of: org.jboss.webservice.server.ServiceEndpointServletJSE, msg=org/jboss/webservice/server/ServiceEndpointServlet

              This is very bad, and seems to indicate some kind of corruption on your jboss install. Can you try doing a fresh install, and see if this problem happens?

              -Jason

              • 4. Re: Problems by deploying the WS-Wiki-Example
                sidazad

                Hi, I did a fresh install (newly downloaded release) of JBoss 4.0.1 sp1 and still have the same problem. This is what my web.xml looks like:

                <?xml version="1.0" encoding="UTF-8"?>
                <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
                
                <web-app xmlns="http://java.sun.com/xml/ns/j2ee"
                 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                 xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
                 version="2.4">
                
                 <servlet>
                 <servlet-name>SidTest</servlet-name>
                 <servlet-class>com.sidtest.SidTestWrappedImpl</servlet-class>
                 </servlet>
                
                 <servlet-mapping>
                 <servlet-name>SidTest</servlet-name>
                 <url-pattern>/SidTest</url-pattern>
                 </servlet-mapping>
                
                </web-app>
                


                Here's the application.xml


                <?xml version="1.0" encoding="ISO-8859-1"?>
                <application>
                 <display-name>SidTest WebService</display-name>
                 <module>
                 <web>
                 <web-uri>sidtest.war</web-uri>
                 <context-root>/sidtest</context-root>
                 sidtest.wsr
                 </web>
                 </module>
                 </application>
                
                


                Please help,
                Thanks, Sid.

                • 5. Re: Problems by deploying the WS-Wiki-Example
                  jason.greene

                  I can't see how it is possible for you to get that exception, can you open a jira issue, and attach your deployment, so I can look at it in more detail.

                  http://jira.jboss.com/jira/secure/BrowseProject.jspa?id=12310050

                  You will have to login using the same login you use for forums to create an issue.

                  Thanks,
                  -Jason

                  • 6. Re: Problems by deploying the WS-Wiki-Example
                    sidazad
                    • 7. Re: Problems by deploying the WS-Wiki-Example
                      jason.greene

                      The exception you pasted in the bug is very different, the one you pasted in the bug looks like a networking problem that was occuring during validation of your web.xml file (probably while downloading a dtd).

                      Anyways i tested the war you uploaded and it worked fine, so there must be a problem on your system. I noticed the classes you sent were compiled under jdk 1.5, so I tested your deployment on the sun 1.5 vm.

                      -Jason

                      • 8. Re: Problems by deploying the WS-Wiki-Example
                        thomas.diesler

                        Jason, the JBossEntityResolver should take care of all known dtd and schema. There should not be a need to remotely fetch the dtd.

                        • 9. Re: Problems by deploying the WS-Wiki-Example
                          jason.greene

                          I thought everything was resolved localy, but take a look at his second stack trace:

                          13:40:15,244 ERROR [ServiceDeployer] Cannot startup webservice for: sidtest.war
                          org.jboss.deployment.DeploymentException: Connection timed out: connect Nested exception: Connection
                          timed out: connect; - nested throwable: (org.dom4j.DocumentException: Connection timed out: connect
                          Nested exception: Connection timed out: connect)
                          at org.jboss.webservice.ServiceDeployerJSE.modifyWebXML(ServiceDeployerJSE.java:142)
                          at org.jboss.webservice.ServiceDeployerJSE.createWebservice(ServiceDeployerJSE.java:95)
                          at org.jboss.webservice.ServiceDeployer.handleNotification(ServiceDeployer.java:109)
                          at sun.reflect.GeneratedMethodAccessor3.invoke(Unknown Source)
                          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                          at java.lang.reflect.Method.invoke(Method.java:585)
                          at org.jboss.mx.notification.NotificationListenerProxy.invoke(NotificationListenerProxy.java
                          :138)
                          at $Proxy29.handleNotification(Unknown Source)

                          • 10. Re: Problems by deploying the WS-Wiki-Example
                            thomas.diesler

                            The web.xml is mixing a DTD for web-app_2_3.dtd and a schema for web-app_2_4.xsd

                            It is probably not dom4j that is confused here.

                            <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
                            
                            <web-app xmlns="http://java.sun.com/xml/ns/j2ee"
                             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                             xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
                             version="2.4">
                            
                             <servlet>
                             <servlet-name>SidTest</servlet-name>
                             <servlet-class>com.sidtest.SidTestWrappedImpl</servlet-class>
                             </servlet>
                            
                             <servlet-mapping>
                             <servlet-name>SidTest</servlet-name>
                             <url-pattern>/SidTest</url-pattern>
                             </servlet-mapping>
                            
                            </web-app>