axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 10103] New: - invalid generated wsdl when inout parameters
Date Fri, 21 Jun 2002 08:26:26 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10103>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10103

invalid generated wsdl when inout parameters

           Summary: invalid generated wsdl when inout parameters
           Product: Axis
           Version: current (nightly)
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: WSDL processing
        AssignedTo: axis-dev@xml.apache.org
        ReportedBy: cchabanois@cognicase.fr


When I use inout parameters in methods of my web service, I don't get a correct
wsdl (from http://localhost:8080/axis/services/Hello?wsdl for my example)

I tried both with StringHolder and with a holder for a bean.

It seems that holders are not handled in a specific way : they seem to be 
considered as beans.

<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions 
targetNamespace="http://localhost:8080/axis/services/Hello/axis/services/Hello" 
[...]
  <wsdl:types>
     <schema xmlns="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://holders.rpc.xml.javax">
       <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
       <element name="StringHolder" nillable="true" type="xsd:anyType"/>
     </schema>
  </wsdl:types>
  <wsdl:message name="sayHelloRequest">
    <wsdl:part name="s" type="tns1:StringHolder"/>
  </wsdl:message>
  <wsdl:message name="sayHelloResponse">
    <wsdl:part name="return" type="xsd:string"/>
    <wsdl:part name="s" type="tns1:StringHolder"/>
  </wsdl:message>
  <wsdl:portType name="HelloImpl">
[...]
</wsdl:definitions>


Here is :

the remote interface :
========================
package hello;

import java.rmi.Remote;
import java.rmi.RemoteException;
import javax.xml.rpc.holders.*;

public interface HelloIF extends Remote {
    public String sayHello(StringHolder s) throws RemoteException;
}

the implementation
===================
package hello;
import javax.xml.rpc.holders.*;
public class HelloImpl implements HelloIF {

    public String message = "Hello ";

    public String sayHello(StringHolder s) {
	s.value = message + s.value;
        return message + s;
    }
}

deploy.wsdd
============
<deployment
    xmlns="http://xml.apache.org/axis/wsdd/"
    xmlns:java="http://xml.apache.org/axis/wsdd/providers/java">

  <service name="Hello" provider="java:RPC">
      <parameter name="className" value="hello.HelloImpl"/>
      <operation name="sayHello" qname="operNS:sayHello"
xmlns:operNS="http://hello" >
        <parameter name="s" type="tns:string"
xmlns:tns="http://www.w3.org/2001/XMLSchema" mode="INOUT"/>
      </operation>
      <parameter name="allowedMethods" value="sayHello"/>
  </service>
</deployment>

Mime
View raw message