cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Johnson Ma (JIRA)" <>
Subject [jira] Created: (CXF-450) JAXWS JavaFirst throws NPE when @WebParameter is not defined in SEP for doc/lit/wrap
Date Wed, 07 Mar 2007 03:55:24 GMT
JAXWS JavaFirst throws NPE when @WebParameter is not defined in SEP for doc/lit/wrap

                 Key: CXF-450
             Project: CXF
          Issue Type: Bug
            Reporter: Johnson Ma

*JAXWS, JAVA-First, Document/Lit/Wrapper
* test java SEI class
@WebService(targetNamespace = "", name = "Hello")

public interface Hello {

    @ResponseWrapper(targetNamespace = "", className = "com.iona.SayHiResponse",
localName = "sayHiResponse")
    @RequestWrapper(targetNamespace = "", className = "com.iona.SayHi", localName
= "sayHi")
    @WebMethod(operationName = "sayHi")
    public void sayHi(
        long l1
* got nullpoint exception as following
INFO: Creating Service {}HelloService from WSDL.
Exception in thread "main" java.lang.NullPointerException
	at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeParameter(

* reason:
In JaxWsServerFactoryBean, line number 342:
if (isIn && !isOut) {
            QName name = getInPartName(o, method, i);
            part = o.getInput().getMessagePart(name);
            initializeParameter(part, paramType, genericType);
The part is null, which caused the NPE,
In JaxWSServiceConfiguration, line number 175.
public QName getInPartName(OperationInfo op, Method method, int paramNumber) {
        if (paramNumber < 0) {
            return null;
        return getPartName(op, method, paramNumber, "arg" + paramNumber);

But the wsdl we generated from SEI is using 
<xs:element name="sayHi">
        <xs:element form="qualified" name="l1" type="xs:long"/>

  <xs:element name="sayHiResponse">
  <wsdl:message name="sayHi">
    <wsdl:part name="sayHi" element="tns:sayHi">

So it looking for arg0, but it is defined in generated wsdl as 'l1'.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message