[ http://issues.apache.org/jira/browse/AXIS2-720?page=comments#action_12413915 ]
Ali Sadik Kumlali commented on AXIS2-720: ----------------------------------------- Don't know why but, mystery is changing elementFormDefault="unqualified" to elementFormDefault="qualified". I could manage to successfully run the code against the given WSDL with this change. Although I listed all the changes I made in the given WSDL, until I try changing elementFormDefault value, none of them worked. My system: WinXP Pro, j2sdk1.4.2_02, Tomcat 5.5 - Made following changes in WSDL - Changed location="http://localhost/axis2/services/TextLocService:localhost/axis2/services/TextLocService" to location="http://localhost:8080/axis2/services/TextLocService" - Since ns1 is already defined in <wsdl:definitions>, removed ns1 definition from <xs:schema>. So, it looked like <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://org.apache.axis2/xsd" elementFormDefault="unqualified" attributeFormDefault="unqualified"> - Added "TextLocService" as name attribute to <wsdl:definitions> - Changed elementFormDefault="unqualified" to elementFormDefault="qualified". - Used following command for creating skeleton and stub: WSDL2Java -uri c:/wsdl/EpiLocService.wsdl -ss -sd -g -t -d xmlbeans -o c:/wsdl/output -p compas I'll attache the service's aar, changed WSDL, skeleton and test client files. > Data binding Error after using WSDL2Java to generate xmlbeans code > ------------------------------------------------------------------ > > Key: AXIS2-720 > URL: http://issues.apache.org/jira/browse/AXIS2-720 > Project: Apache Axis 2.0 (Axis2) > Type: Bug > Components: databinding > Versions: 1.0 > Environment: Server: Axis2 1.0 inside a Tomcat 5.5.15 under Scientific > Linux, 2.6.x kernel > Client: Windows XP SP2 with JDK 1.5.0_06 > Reporter: Rincewind Wizard > Assignee: Ajith Harshana Ranabahu > Attachments: EpiLocService.wsdl, EpiLocService.wsdl, > TextLocServiceSkeleton.java, TextLocServiceTest.java > > We've used the attached WSDL to create a service & client by means of > the WSDL2Java tool (xmlbeans databinding). After implementing the > simplest of business logics in the server, we deployed the service .aar > in the axis2 install inside a tomcat server. According to the status > page, the service is running error free. > The client was also created by WSDL2Java, where we wrote a simple main() > class to test the client. We've pasted it below. > public static void main(String[] args) { > try { > PredictLocalizationRequestDocument pdoc = > PredictLocalizationRequestDocument.Factory.newInstance(); > pdoc.addNewPredictLocalizationRequest(); > pdoc.getPredictLocalizationRequest().setSequence("ASDF"); > pdoc.getPredictLocalizationRequest().setOrganism("ANIMAL"); > TextLocServiceStub sender = new > TextLocServiceStub("http://localhost/axis2/services/TextLocService"); > PredictLocalizationResponseDocument res = > sender.predictLocalization(pdoc); > System.out.println(res.toString()); > } catch (Exception e) { > e.printStackTrace(); > } > } > The client now runs up until the document is being sent, where it throws > an Exception. The stack trace is below. We think it is still a > client-side problem, although the client does complain if it is not > connected to the server and doesn't throw this exception. > Please let us know if we should change anything about our client > generation procedure, or how we can use the test client jar that is also > generated by the WSDL2Java tool. > Thanks a lot for your time! -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
