You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Rania Khalaf <rk...@watson.ibm.com> on 2002/08/02 16:06:31 UTC

help:TypeMapping null in syncOperationToClass

Hi
I am trying to deploy a service that has certain classes I have
my own serializer/deserializer for. However, when it does
syncOperationToClass, the type mapping registry is turning
up null so I get a NullPointerException.

I have included type mappings in the wsdd file alreay.
Here is an excerpt of the type mapping and the operation
from the wsdd file, as well as the method in the java class
of the service that it is trying to sync to:

FROM WSDD:
<typeMapping qname="ns:boolean" 
xmlns:ns="http://www.w3.org/2001/XMLSchema"
             type="java:com.ibm.jrom.JROMBooleanValue"      
             serializer="samples.axisBeta3.JROMAxisSerializerFactory"
            
deserializer="samples.axisBeta3.JROMAxisDeserializerFactory"
             encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>

<operation name="testBoolean" returnQName="return"            
returnType="RTypeNS:boolean"            
xmlns:RTypeNS="http://www.w3.org/2001/XMLSchema" >
             <parameter name="var"
type="tns:boolean"                         
xmlns:tns="http://www.w3.org/2001/XMLSchema"/>
</operation>

FROM JAVA SERVICE:
public JROMBooleanValue testBoolean(JROMBooleanValue var) {
    System.out.println("testBoolean:  value: " + var.getValue());
    return var;
  }


Here's the beginning of the stacktrace, with some debug
printlns I put in syncOperationToClass:

type mapping is null
synching method: testBoolean
got param type=interface com.ibm.jrom.JROMBooleanValue
got param desc =name:  var
typeEntry:  null
mode:  IN
typeQName:  {http://www.w3.org/2001/XMLSchema}boolean
javaType:  null
got param typeQName{http://www.w3.org/2001/XMLSchema}boolean
trying to match null to QName {http://www.w3.org/2001/XMLSchema}boolean
- Exception:
AxisFault
 faultCode: {http://xml.apache.org/axis/}Server.userException
 faultString: java.lang.NullPointerException
 faultActor: null
 faultDetail:
        stackTrace: java.lang.NullPointerException
        at
org.apache.axis.description.ServiceDesc.syncOperationToClass(ServiceD
esc.java:509)
        at
org.apache.axis.description.ServiceDesc.getSyncedOperationsForName(Se
rviceDesc.java:694)
        at
org.apache.axis.description.ServiceDesc.loadServiceDescByIntrospectio
n(ServiceDesc.java:581)
        at
org.apache.axis.description.ServiceDesc.loadServiceDescByIntrospectio
n(ServiceDesc.java:557)
        at
org.apache.axis.description.ServiceDesc.initQNameMap(ServiceDesc.java
:433)
        at
org.apache.axis.description.ServiceDesc.getOperationsByQName(ServiceD
esc.java:411)
        at 
org.apache.axis.MessageContext.getPossibleOperationsByQName(MessageCo
ntext.java:236)