cancel
Showing results for 
Search instead for 
Did you mean: 

error calling a web service with multiple input data

ajeje93
Confirmed Champ
Confirmed Champ

I am using the Web Service from the book Activiti in Action (book-sales-app), modified a little bit adding two parameters more in input, and it is correctly running on address http://localhost:8080/book-sales-app/services/address?wsdl.

The WSDL is the following:

<wsdl:definitions name="AddressServiceService" targetNamespace="http://ws.chapter11.bpmnwithactiviti.org/">
    <wsdl:types>
        <xs:schema elementFormDefault="unqualified" targetNamespace="http://ws.chapter11.bpmnwithactiviti.org/" version="1.0">
            <xs:element name="findCustomerAddress" type="tns:findCustomerAddress"/>
            <xs:element name="findCustomerAddressResponse" type="tns:findCustomerAddressResponse"/>
            <xs:complexType name="findCustomerAddress">
                <xs:sequence>
                    <xs:element minOccurs="0" name="customerName" type="xs:string"/>
                    <xs:element minOccurs="0" name="load" type="xs:string"/>
                    <xs:element minOccurs="0" name="duration" type="xs:string"/>
                </xs:sequence>
            </xs:complexType>
            <xs:complexType name="findCustomerAddressResponse">
                <xs:sequence>
                    <xs:element minOccurs="0" name="address" type="xs:string"/>
                </xs:sequence>
            </xs:complexType>
        </xs:schema>
    </wsdl:types>
    <wsdl:message name="findCustomerAddress">
        <wsdlSmiley Tongueart element="tns:findCustomerAddress" name="parameters"></wsdlSmiley Tongueart>
    </wsdl:message>
    <wsdl:message name="findCustomerAddressResponse">
        <wsdlSmiley Tongueart element="tns:findCustomerAddressResponse" name="parameters"></wsdlSmiley Tongueart>
    </wsdl:message>
    <wsdlSmiley TongueortType name="AddressService">
        <wsdlSmiley Surprisedperation name="findCustomerAddress">
            <wsdl:input message="tns:findCustomerAddress" name="findCustomerAddress"></wsdl:input>
            <wsdlSmiley Surprisedutput message="tns:findCustomerAddressResponse" name="findCustomerAddressResponse"></wsdlSmiley Surprisedutput>
        </wsdlSmiley Surprisedperation>
    </wsdlSmiley TongueortType>
    <wsdl:binding name="AddressServiceServiceSoapBinding" type="tns:AddressService">
        <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
        <wsdlSmiley Surprisedperation name="findCustomerAddress">
            <soapSmiley Surprisedperation soapAction="" style="document"/>
            <wsdl:input name="findCustomerAddress">
                <soap:body use="literal"/>
            </wsdl:input>
            <wsdlSmiley Surprisedutput name="findCustomerAddressResponse">
                <soap:body use="literal"/>
            </wsdlSmiley Surprisedutput>
        </wsdlSmiley Surprisedperation>
    </wsdl:binding>
    <wsdl:service name="AddressServiceService">
        <wsdlSmiley Tongueort binding="tns:AddressServiceServiceSoapBinding" name="AddressServicePort">
            <soap:address location="http://localhost:8080/book-sales-app/services/address"/>
        </wsdlSmiley Tongueort>
    </wsdl:service>
</wsdl:definitions>

I am trying to call it using this unit test GitHub - ajeje93/activiti-unit-test-webservice

If I called it when it got only one input everything worked, but noew every time that I call it I get the error:

test(org.activiti.MyUnitTest): cvc-id.1: There is no ID/IDREF binding for IDREF "loadVar".
test(org.activiti.MyUnitTest): no processes deployed with key 'customer'

What can I do to solve this problem?

1 ACCEPTED ANSWER

ajeje93
Confirmed Champ
Confirmed Champ

I soved by myself. I missed two itemDefinition in the process definition:


    <itemDefinition id="loadVar" structureRef="string" />
    <itemDefinition id="durationVar" structureRef="string" />

View answer in original post

1 REPLY 1

ajeje93
Confirmed Champ
Confirmed Champ

I soved by myself. I missed two itemDefinition in the process definition:


    <itemDefinition id="loadVar" structureRef="string" />
    <itemDefinition id="durationVar" structureRef="string" />