users@jax-rpc.java.net

Re: wsdeploy gives NullPointerException

From: Doug Kohlert <doug.kohlert_at_sun.com>
Date: Tue, 15 Jul 2003 11:48:43 -0700

Can you send me the stack trace?

Mark D. Hansen wrote:
> I do not get any errors with wscompile.
>
> -----Original Message-----
> From: Public discussion on JAX-RPC
> [mailto:JAXRPC-INTEREST_at_JAVA.SUN.COM]On Behalf Of Doug Kohlert
> Sent: Tuesday, July 15, 2003 1:40 PM
> To: JAXRPC-INTEREST_at_JAVA.SUN.COM
> Subject: Re: wsdeploy gives NullPointerException
>
>
> Mark,
> Can you try to run the service endpoint interface through wscompile to
> see
> if you get the same NPE?
>
> Thanks
>
> Mark D. Hansen wrote:
>
>>Using JWSDP 1.2, wsdeploy is giving me the following NPE. Detailed
>
> information is below. Any help will be greatly appreciated.
>
>>[wsdeploy] error: generator error: java.lan.NullPointerException
>>
>>Although, I get this error, wsdeploy continues on and generates a .war
>
> file. However, when the web.xml contained in the .war file looks
> incomplete. It does not contain any <servlet> ... </servlet> OR
> <servlet-mapping> ... </servlet-mapping>. Shouldn't the generated
> web.xml always contain a servlet/servlet-mapping definition ???
>
>>Here is the output from ant:
>>
>>[wsdeploy] command line: wsdeploy -classpath
>
> C:\jwsdp-1.2\jaxp\lib\endorsed\xercesImpl.jar;C:\jwsdp-1.2\jaxp\lib\jaxp
> -api.jar;C:\jwsdp-1.2\jaxp\lib\endorsed\dom.jar;C:\jwsdp-1.2\jaxp\lib\en
> dorsed\sax.jar;C:\jwsdp-1.2\jaxp\lib\endorsed\xalan.jar;C:\jwsdp-1.2\jax
> p\lib\endorsed\xsltc.jar;C:\jakarta-servletapi-4\lib\servlet.jar;C:\jwsd
> p-1.2\saaj\lib\saaj-api.jar;C:\jwsdp-1.2\saaj\lib\saaj-impl.jar;C:\jwsdp
> -1.2\jwsdp-shared\lib\activation.jar;C:\jwsdp-1.2\jwsdp-shared\lib\mail.
> jar;C:\jwsdp-1.2\jwsdp-shared\lib\commons-logging.jar;C:\jwsdp-1.2\jwsdp
> -shared\lib\namespace.jar;C:\jwsdp-1.2\jwsdp-shared\lib\providerutil.jar
> ;C:\jwsdp-1.2\jwsdp-shared\lib\jax-qname.jar;C:\jwsdp-1.2\jwsdp-shared\l
> ib\xsdlib.jar;C:\jwsdp-1.2\jwsdp-shared\lib\relaxngDatatype.jar;C:\jakar
> ta-log4j-1.2.7\dist\lib\log4j-1.2.7.jar;C:\jwsdp-1.2\apache-ant\lib\ant.
> jar;C:\jwsdp-1.2\apache-ant\lib\optional.jar;C:\jakarta-tomcat-4.1.24\se
> rver\lib\catalina.jar;C:\jakarta-tomcat-4.1.24\server\lib\catalina-ant.j
> ar;Q:\
> book\build\classes;C:\jwsdp-1.2\jaxrpc\lib\jaxrpc-api.jar;C:\jwsdp-1.2\j
> axrpc\lib\jaxrpc-impl.jar -keep -tmpdir
> Q:\book\build\classes\com\javector\chap5\sec1\server\tmp -o
> Q:\book\build\classes\com\javector\chap5\sec1\server\jaxrpc-OrderProcess
> or.war -verbose
> Q:\book\build\classes\com\javector\chap5\sec1\server\jaxrpc-OrderProcess
> or-raw.war
>
>>[wsdeploy] info: created temporary directory:
>
> Q:\book\build\classes\com\javector\chap5\sec1\server\tmp\jaxrpc-deploy-b
> 174f3
>
>>[wsdeploy] error: generator error: java.lang.NullPointerException
>>[wsdeploy] info: created output war file:
>
> Q:\book\build\classes\com\javector\chap5\sec1\server\jaxrpc-OrderProcess
> or.war
>
>>Here is the web.xml that gets generated:
>>
>><?xml version="1.0" encoding="UTF-8"?>
>><!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web
>
> Application 2.3//EN" "http://java.sun.com/j2ee/dtds/web-app_2_3.dtd">
>
>><web-app><display-name>5.1 OrderProcessor using
>
> JAX-RPC</display-name><listener><listener-class>com.sun.xml.rpc.server.h
> ttp.JAXRPCContextListener</listener-class></listener></web-app>
>
>>Here is my original jaxrpc-ri-before.xml:
>>
>><?xml version="1.0" encoding="UTF-8"?>
>>
>><webServices
>> xmlns="http://java.sun.com/xml/ns/jax-rpc/ri/dd"
>> version="1.0"
>> targetNamespaceBase="http://javector.com/5.1/wsdl"
>> typeNamespaceBase="http://javector.com/5.1/types"
>> urlPatternBase="/ws">
>>
>> <endpoint
>> name="OrderProcessor"
>> displayName="5.1 OrderProcessor using JAX-RPC"
>> description="SOAP messaging using JAX-RPC"
>> wsdl="/WEB-INF/OrderProcessor.wsdl"
>>
>
> interface="com.javector.chap5.sec1.server.jaxrpc.OrderProcessingPortType
> "
>
>> implementation="com.javector.chap5.sec1.server.OrderProcessor"
>> model="/WEB-INF/model-wsdl-rpcenc.xml.gz"/>
>>
>> <endpointMapping
>> endpointName="OrderProcessor"
>> urlPattern="/orderproc"/>
>>
>></webServices>
>
>
>
> --
> Doug Kohlert
> Java Software Division
> Sun Microsystems, Inc.
> phone: 503 345-9806


-- 
Doug Kohlert
Java Software Division
Sun Microsystems, Inc.
phone: 503 345-9806