I think the problem is that you are not importing your schemas. Even though you are defining three schemas in one WSDL definition, you cannot reference elements and types from one schema in another unless you explicitly import the referenced namespace into the schema.
Your <types> section should look like this: <wsdl:types> <schema elementFormDefault="qualified" targetNamespace="http://localhost:8080/axis/services/OrderProcessor" xmlns="http://www.w3.org/2001/XMLSchema"> <-- Import tns1 namespace --> <import namespace="urn:BeanService" /> <complexType name="ArrayOf_xsd_string"> <sequence> <element maxOccurs="unbounded" minOccurs="0" name="item" type="xsd:string"/> </sequence> </complexType> <complexType name="ArrayOf_tns1_OrderDetails"> <sequence> <element maxOccurs="unbounded" minOccurs="0" name="item" type="tns1:OrderDetails"/> </sequence> </complexType> <element name="processOrderReturn" type="xsd:string"/> </schema> <schema elementFormDefault="qualified" targetNamespace="urn:BeanService" xmlns="http://www.w3.org/2001/XMLSchema"> <-- Import impl namespace --> <import namespace="http://localhost:8080/axis/services/OrderProcessor" /> <complexType name="OrderDetails"> <sequence> <element name="customerName" nillable="true" type="xsd:string"/> <element name="itemCodes" nillable="true" type="impl:ArrayOf_xsd_string"/> <element name="pinCode" type="xsd:int"/> <element name="quantities" nillable="true" type="impl:ArrayOf_xsd_string"/> <element name="shippingAddress" nillable="true" type="xsd:string"/> </sequence> </complexType> <complexType name="Order"> <sequence> <element name="orderDetails" nillable="true" type="impl:ArrayOf_tns1_OrderDetails"/> </sequence> </complexType> </schema> <schema elementFormDefault="qualified" targetNamespace="http://example5.userguide.samples" xmlns="http://www.w3.org/2001/XMLSchema"> <-- Import tns1 namespace --> <import namespace="urn:BeanService" /> <element name="in0" type="tns1:Order"/> </schema> </wsdl:types> -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Friday, April 30, 2004 4:38 AM To: [EMAIL PROTECTED] Cc: Anne Thomas Manes Subject: RE: Axis :: Input parameter namespace ! ['Watchdog': checked] ['Watchdog': Virus checked] Hi I have attached my wsdl and wsdd file along with this mail. Anne: I managed to write a sample wsdl files that creates the same problem. I tried sending entire the zip file with all the contents, but user group rejects executable code. Please go through it, This wsdl is a file that Axis throws an error when I send a SOAP request. I really dont know why Axis is forcing me to give a namespace in its own manner. Attached files are: 1. OrderProcessor.wsdl (Exception) 2. OrderProcessor_valid.wsdl (No exception) 3. deploy.wsdd. The difference between these two wsdl files are: 1. <schema elementFormDefault="qualified" targetNamespace="http://example5.userguide.samples" xmlns=" http://www.w3.org/2001/XMLSchema"> <element name="in0" type="tns1:Order"/> </schema> 2. <schema elementFormDefault="qualified" targetNamespace="http://example6.userguide.samples" xmlns=" http://www.w3.org/2001/XMLSchema"> <element name="in0" type="tns1:Order"/> </schema> I dont know why Axis forces me to use this namespace " http://example5.userguide.samples", I want to define all the namespace according to my company needs. Please give me ur thoughts. Notes: 1.I know this wsdl file doesn't conforms to WS-I, no problem that was not my question. thanks, -kannan (See attached file: OrderProcessor.wsdl)(See attached file: OrderProcessor_valid.wsdl)(See attached file: deploy.wsdd) "Anne Thomas Manes" To: <[EMAIL PROTECTED]> <[EMAIL PROTECTED]> cc: Subject: RE: Axis :: Input parameter namespace ! ['Watchdog': checked] ['Watchdog': 29/04/04 18:04 Virus checked] Please respond to axis-user Please send us your WSDL file. -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Thursday, April 29, 2004 11:40 AM To: [EMAIL PROTECTED] Subject: Axis :: Input parameter namespace ! ['Watchdog': checked] ['Watchdog': Virus checked] Hi All, I am using Axis 1.2 beta, I facing a strange problem now: What I have done: 1. Created all the complex types in a separate XML Schema ( Created all the related java beans as well) 2. Created another xml schema, which defines the elements of type described in Step 1. 3. Wrote a WSDL file, which imports XML Schema in step 2. 4. Generated the deployment descriptors (deploy.wsdd, undeploy.wsdd) from WSDL (added <wsdlFile> as well) 5. Packed everything and Deployed. 6. Queried the wsdl file from Axis (?wsdl), it returns. 7. Generated a SOAP request against the wsdl. 9. Sent the SOAP request. 10. Exception !!!!!!! For example: Webservice class name: Class name = com.examples.webservice.document.BeanService Assume that my complex types are fine. Namespace = http://www.samples.com/schema/customDataTypes.xsd Complex type = "PurchaseOrderType" (which contains all the sequence of elements) Element that represents a complex type is : Import = http://www.samples.com/schema/customDataTypes.xsd prefix = cdt Namespace = http://www.samples.com/schema/purchaseOrder.xsd Element = <xsd:element name="PurchaseOrder" type="cdt:PurchaseOrderType"/> SOAP request: Namespace and Prefix = http://www.samples.com/schema/purchaseOrder.xsd Prefix = po soap body = <po:PurchaseOrder>...............</po:PurchaseOrder> After sending the request, Exception: SAXException: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize. I MODIFIED MY SOAP REQUEST LIKE THIS: Added another namespace, which is not defined in any namespace or any schema. xmlns:tns8="http://document.webservice.examples.com" soap body = <tns8:in0>...................</tns8:in0> Every thing works fine !!! Questions : 1. Why is it not accepting the input element defined by my schema ?. 2. When Axis is reading my wsdl and all the schemas imported, How is it accepting a request from different namespace (which is a package structure for my implementation class) "http://document.webservice.examples.com" ? 3. I have not defined the element, "in0" any where in my xml schema, how can Axis accept this ? 4. Is it like All the input elements for a method to invoke should have a namespace related to implementation class (namespace is in reverse order of my package structure) ?? Your thoughts please. Iam very sorry that I can't give my wsdl or schemas. If my questions are not clear please ask me, I shall explain in detail. thanks, -kannan This email and any attachments to it may contain confidential information intended for the addressee only. If you are not the intended addressee, you are strictly prohibited from disclosing, copying, distributing or using this email in any way. Unauthorised use of the information contained in this email is unlawful. If you have received this email in error please notify us on [EMAIL PROTECTED] and delete the email from your system. Information contained in this email can not be disclosed, copied, distributed or used in any way without the prior consent of the sender. Any opinions, advice or facts given in this email are given without warranty or the intention to enter into an agreement unless specifically stated and confirmed by agreement, letter or such other documentation signed by an authorised signatory of BCA Holdings Limited or any of its subsidiary companies. Any personal information contained in this email is strictly the view of the sender and is in no way authorised or attributable to BCA Holdings Limited or any of its subsidiary companies in any way. All emails through the company gateway are subject to monitoring. The company cannot be held liable for any errors or viruses contained in this message. This email and any attachments to it may contain confidential information intended for the addressee only. If you are not the intended addressee, you are strictly prohibited from disclosing, copying, distributing or using this email in any way. Unauthorised use of the information contained in this email is unlawful. If you have received this email in error please notify us on [EMAIL PROTECTED] and delete the email from your system. Information contained in this email can not be disclosed, copied, distributed or used in any way without the prior consent of the sender. Any opinions, advice or facts given in this email are given without warranty or the intention to enter into an agreement unless specifically stated and confirmed by agreement, letter or such other documentation signed by an authorised signatory of BCA Holdings Limited or any of its subsidiary companies. Any personal information contained in this email is strictly the view of the sender and is in no way authorised or attributable to BCA Holdings Limited or any of its subsidiary companies in any way. All emails through the company gateway are subject to monitoring. The company cannot be held liable for any errors or viruses contained in this message.
