users@glassfish.java.net

Auto-generated webservices.xml not found?

From: <glassfish_at_javadesktop.org>
Date: Mon, 05 Mar 2007 14:41:05 PST

I'm fairly new to J2EE, and I'm deploying a web service (JAX-WS 2.0) to SJSAS 9UR1 (JDK 1.5.0) on Solaris. I having a problem with my web service not working. I've tried it on SJSAS 9UR1 from NetBeans on my PC and it works fine.

When I deploy my WAR file, I'm using the admin tool. I'm specifying an application name of "SNet" and a context root of "/snet". Both visually and by looking at the logs, the app appears to deploy fine. I can access my JSP pages and they working fine as well. When I try to access or test my web service though, I see errors appear in the server.log file:

[#|2007-03-05T17:27:38.114-0500|WARNING|sun-appserver-pe9.0|javax.enterprise.system.tools.admin|_ThreadID=12;_ThreadName=httpWorkerThread-4848-0;_RequestID=d6d4a4fe-ed8d-4910-858f-601d2c874b0f;|Descriptors could not be loaded for module null : java.io.FileNotFoundException: /opt/javaee-5-sdk/domains/development/generated/xml/j2ee-modules/null/WEB-INF/webservices.xml (No such file or directory).|#]

[#|2007-03-05T17:27:39.080-0500|WARNING|sun-appserver-pe9.0|javax.enterprise.system.tools.admin|_ThreadID=12;_ThreadName=httpWorkerThread-4848-0;_RequestID=d6d4a4fe-ed8d-4910-858f-601d2c874b0f;|Descriptors could not be loaded for module null : java.io.FileNotFoundException: /opt/javaee-5-sdk/domains/development/generated/xml/j2ee-modules/null/WEB-INF/webservices.xml (No such file or directory).|#]

[#|2007-03-05T17:29:44.307-0500|WARNING|sun-appserver-pe9.0|javax.enterprise.system.tools.admin|_ThreadID=12;_ThreadName=httpWorkerThread-4848-0;_RequestID=d6d4a4fe-ed8d-4910-858f-601d2c874b0f;|Descriptors could not be loaded for module null : java.io.FileNotFoundException: /opt/javaee-5-sdk/domains/development/generated/xml/j2ee-modules/null/WEB-INF/webservices.xml (No such file or directory).|#]

[#|2007-03-05T17:29:45.017-0500|WARNING|sun-appserver-pe9.0|javax.enterprise.system.tools.admin|_ThreadID=15;_ThreadName=httpWorkerThread-4848-1;_RequestID=fabd2e52-ba32-4ee8-a802-8f81de5a8fff;|Descriptors could not be loaded for module null : java.io.FileNotFoundException: /opt/javaee-5-sdk/domains/development/generated/xml/j2ee-modules/null/WEB-INF/webservices.xml (No such file or directory).|#]

[#|2007-03-05T17:29:46.030-0500|WARNING|sun-appserver-pe9.0|javax.enterprise.system.tools.admin|_ThreadID=15;_ThreadName=httpWorkerThread-4848-1;_RequestID=fabd2e52-ba32-4ee8-a802-8f81de5a8fff;|Descriptors could not be loaded for module null : java.io.FileNotFoundException: /opt/javaee-5-sdk/domains/development/generated/xml/j2ee-modules/null/WEB-INF/webservices.xml (No such file or directory).|#]

[#|2007-03-05T17:30:01.363-0500|WARNING|sun-appserver-pe9.0|javax.enterprise.system.container.web|_ThreadID=18;_ThreadName=httpWorkerThread-8282-0;_RequestID=a406e62e-1b9c-4587-9527-febda452793b;|Servlet web service endpoint 'DocumentImport' failure
java.lang.NullPointerException
        at javax.xml.validation.SchemaFactory.newSchema(SchemaFactory.java:521)
        at com.nortel.is.strategynet.service.DocumentImport.<init>(DocumentImport.java:121)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
        at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
        at java.lang.Class.newInstance0(Class.java:350)
        at java.lang.Class.newInstance(Class.java:303)
        at com.sun.enterprise.webservice.JAXWSServlet.registerEndpoint(JAXWSServlet.java:315)
        at com.sun.enterprise.webservice.JAXWSServlet.doInit(JAXWSServlet.java:289)
        at com.sun.enterprise.webservice.JAXWSServlet.init(JAXWSServlet.java:110)
        at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1133)
        at org.apache.catalina.core.StandardWrapper.allocate(StandardWrapper.java:787)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:183)
        at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
        at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:536)
        at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:240)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:179)
        at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
        at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:73)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:182)
        at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
        at com.sun.enterprise.web.VirtualServerPipeline.invoke(VirtualServerPipeline.java:120)
        at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:939)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:137)
        at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
        at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:536)
        at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:939)
        at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:239)
        at com.sun.enterprise.web.connector.grizzly.ProcessorTask.invokeAdapter(ProcessorTask.java:667)
        at com.sun.enterprise.web.connector.grizzly.ProcessorTask.processNonBlocked(ProcessorTask.java:574)
        at com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:844)
        at com.sun.enterprise.web.connector.grizzly.ReadTask.executeProcessorTask(ReadTask.java:287)
        at com.sun.enterprise.web.connector.grizzly.ReadTask.doTask(ReadTask.java:212)
        at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:252)
        at com.sun.enterprise.web.connector.grizzly.WorkerThread.run(WorkerThread.java:75)
|#]


What's puzzling me is the 'null' in the path: /opt/javaee-5-sdk/domains/development/generated/xml/j2ee-modules/null/WEB-INF/webservices.xml

The auto-generated webservices.xml is actually here instead: /opt/javaee-5-sdk/domains/development/generated/xml/j2ee-modules/SNet/WEB-INF/webservices.xml

Here's the webservices.xml:
<?xml version="1.0" encoding="UTF-8"?>
<webservices xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.2" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://www.ibm.com/webservices/xsd/javaee_web_services_1_2.xsd">
<webservice-description>
<display-name>DocumentImportService</display-name>
<webservice-description-name>DocumentImportService</webservice-description-name>
<wsdl-file>WEB-INF/wsdl/DocumentImportService.wsdl</wsdl-file>
<port-component>
<port-component-name>DocumentImport</port-component-name>
<wsdl-service xmlns="http://strategynet.is.nortel.com/import">DocumentImportService</wsdl-service>
<wsdl-port xmlns:ns1="http://strategynet.is.nortel.com/import">ns1:DocumentImportPort</wsdl-port>
<service-endpoint-interface>com.nortel.is.strategynet.service.DocumentImport</service-endpoint-interface>
<service-impl-bean>
<servlet-link>DocumentImport</servlet-link>
</service-impl-bean>
</port-component>
</webservice-description>
</webservices>


Here's the sun-web.xml:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE sun-web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Application Server 9.0 Servlet 2.5//EN" "http://www.sun.com/software/appserver/dtds/sun-web-app_2_5-0.dtd">
<sun-web-app>
<context-root>/snet</context-root>
<servlet>
<servlet-name>DocumentImport</servlet-name>
<webservice-endpoint>
<port-component-name>DocumentImport</port-component-name>
<endpoint-address-uri>/DocumentImportService</endpoint-address-uri>
<service-qname>
<namespaceURI>http://strategynet.is.nortel.com/import</namespaceURI>
<localpart>DocumentImportService</localpart>
</service-qname>
<servlet-impl-class>com.nortel.is.strategynet.service.DocumentImport</servlet-impl-class>
<debugging-enabled>true</debugging-enabled>
</webservice-endpoint>
</servlet>
<class-loader delegate="true"/>
<jsp-config>
<property name="classdebuginfo" value="true">
<description>Enable debug info compilation in the generated servlet class</description>
</property>
<property name="mappedfile" value="true">
<description>Maintain a one-to-one correspondence between static content and the generated servlet class' java code</description>
</property>
</jsp-config>
</sun-web-app>


Anybody have an idea why the path is wrong, thus causing my webservices.xml to not be found?

Thanks in advance,
Rob
[Message sent by forum member 'digithead1011' (digithead1011)]

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