The Axis2 Code Generation Tool Reference has a sample WSDL using soap 1.1 and doc / lit .
http://ws.apache.org/axis2/CodegenToolReference.html AFAIK, your choices are 'rpc literal' and 'doc literal' using axis2 at the present time, ie, not rpc encoded. HTH, iksrazal Em Sexta 09 Dezembro 2005 04:26, o Simon McMahon escreveu: > Hi, > > Looks to me like Axis2 is geared more for message passing than RPC > which Axis 1.x handled very well. Axis2 obviously has other features > that Axis 1.3 doesn't but my existing services work best as RPC. Well, > at least I could get it to work. It also looks like you need to know > AXIOM pretty well to use Axis 2. > > I think I have to wait for some more Axis2 examples and 1.x backwards > compatibility before I can migrate successfully. > > Thanks, > > Simon. > > > Simon McMahon > > Work: (07) 31311420 > Mobile: (043) 2294180 > > >>> [EMAIL PROTECTED] 12/08/05 03:38pm >>> > > Forwarding to the list. It was my fault to hit reply and send only to > Simon. I am not sure of the Java2WSDL satus right now. May be ajith > would know better. > Chathura > > On 12/8/05, Simon McMahon <[EMAIL PROTECTED]> wrote: > > Thanks for your time to look into it. I thought my change to the > > wsdl > > > was too dumb to work but if I keep hacking my wsdl file without > > understanding what I am doing I am most likely going to wreck it. In > > the > > > schema section I changed the "soapens:string" to "xsd:string" but I > > dont > > > know how to convert the "array" types. Is there more documentation > > that > > > I should be looking into or some other way? The only wsdl sample is > > Axis2SampleDocLit.wsdl. > > > > As I understand there is no Java2WSDL for Axis2 (yet). > > > > Sorry to keep with new questions but I'm a bit lost with what to try > > next... > > > > Surely people dont create wsdl by hand so where do Axis2 compliant > > wsdls come from? > > How do I start from just a class (.java) and build the wsdl, server > > & > > > client for Axis2 like I did with Axis 1.3 (1.2 when I started)? > > If Web Services are to be interoperable - i.e. a Axis2 client using > > an > > > Axis 1.3 server - how come the WSDL doesn't work as is? > > Is this just a question of time to finish Axis2 ? > > > > Regards, > > > > Simon. > > > > > > Simon McMahon > > > > Work: (07) 31311420 > > Mobile: (043) 2294180 > > > > >>> Chathura Herath <[EMAIL PROTECTED]> 12/08/05 02:39pm >>> > > > > I am sorry that wouldnt work. You need to get rid of all the > > soapenc: > > types in the schema section. We use xml beans for databingding it > > cannot handle soap encoding. Though you have simply change the use > > from thm encoded to literal the semantic description of your data in > > schema is still SOAP encoded. > > Chathura > > > > On 12/7/05, Simon McMahon <[EMAIL PROTECTED]> wrote: > > > Original WSDL and edited are attached. The original was generated > > by > > > > Axis 1.3. All I did was substitute "encoded" for "literal" and > > > > changed > > > > > nothing else. > > > > > > My understanding of all this is pretty limited although I got my > > > > Axis > > > > > 1.3 service and client to work OK. > > > > > > Your help is most appreciated. > > > > > > Cheers, > > > > > > Simon. > > > > > > > > > Simon McMahon > > > > > > Work: (07) 31311420 > > > Mobile: (043) 2294180 > > > > > > >>> [EMAIL PROTECTED] 12/08/05 01:56pm >>> > > > > > > Doesn't seem right. Pls attach the edited WSDL. > > > Literal means the type is fully described by schema: Encoded mean > > > > the > > > > > semantics of encoding applies. If its SOAP encoding then the > > > > semantics > > > > > of SOAP encoding is used other than xsd type. > > > Chathura > > > > > > On 12/7/05, Simon McMahon <[EMAIL PROTECTED]> wrote: > > > > Hi again, > > > > > > > > I hacked up my Axis 1.3 generated wsdl and changed all > > > > <wsdlsoap:body > > > > encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" > > > > namespace="urn:qh" use="encoded"/> > > > > to > > > > <wsdlsoap:body > > > > encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" > > > > namespace="urn:qh" use="literal"/> > > > > based on the WSDL2Java error > > > > > > > > : java.lang.RuntimeException: The use 'encoded' is not > > > > > > > > supported! > > > > > > > > I have no idea what that means but now WSDL2Java runs to > > > > completion > > > > > and > > > > > > > generates a whole bunch of files. > > > > > > > > What is the difference between "encoded" and "literal"? > > > > Why is all the standard 'databinding' source plugged into my > > > > package > > > > > ? > > > > > > > Surely this will bloat the size of every web service. > > > > > > > > Also, my original Service method: > > > > public Provider[] getProvider(String name, String > > > > > > providerId, > > > > > > > String orgName, String locationId, int maxResults) throws > > > > Exception > > > > > > became: > > > > /** > > > > * Auto generated method signatures > > > > * @param param68 > > > > */ > > > > public org.apache.axis2.om.OMElement getProvider( > > > > org.apache.axis2.om.OMElement param68) throws > > > > > > java.rmi.RemoteException; > > > > > > > The only bit that stayed the same is the method name. How can > > the > > > > > stub/skeleton for the same web service be so different? > > > > Is there more I need to do to the WSDL to make it generate a > > > > proper > > > > > > interface and skeleton service? > > > > > > > > Regards, > > > > > > > > Simon. > > > > > > > > > > > > Simon McMahon > > > > > > > > Work: (07) 31311420 > > > > Mobile: (043) 2294180 > > > > > > > > >>> [EMAIL PROTECTED] 12/07/05 04:29pm >>> > > > > > > > > That would be it - all the samples use "services.xml". The > > > > documentation > > > > is correct on this too. Must just have been M2 that got it wrong > > > > (or > > > > > > just me :). > > > > > > > > > Blind guess. Check whether the dir of the aar name is > > META-INF. > > > > > > "meta-inf" might not work > > > > > Chathura > > > > > > > > This was also correct - "meta-inf" did not work either. It was > > > > tough > > > > > > to > > > > get right because WinZip shows all UPPERCASE names in lowercase > > by > > > > > default. > > > > > > > > The Axis2 Exception does not include the "META-INF" part of the > > > > name > > > > > > that is obviously significant. The documentation looks OK > > though. > > > > > ------------- > > > > Now I get: > > > > > > > > This Web axisService has deployment faults > > > > > > > > Error: org.apache.axis2.deployment.DeploymentException: null; > > > > nested > > > > > > exception is: java.lang.ClassCastException at > > org.apache.axis2.deployment.repository.util.ArchiveReader.processServiceGro >up(ArchiveReader.java:216) > > > > > at > > org.apache.axis2.deployment.DeploymentEngine.doDeploy(DeploymentEngine.java >:510) > > > > > at > > org.apache.axis2.deployment.repository.util.WSInfoList.update(WSInfoList.ja >va:228) > > > > > at > > > > ... > > > > > > > > Full exception attached. > > > > > > > > ---------------- > > > > I have a .wsdl (as generated by Axis 1.3 - attached) so I try to > > > > run > > > > > > WSDL2Java. > > > > > > > > c:> WSDL2Java -uri ProviderService.wsdl -ss -sd -o src2 -p > > > > au.gov.qld.health.s8online.providerdir > > > > > > > > It creates 'src2' (empty) and outputs: > > > > > > > > schemaElement = [xsd:schema: null] > > > > Exception in thread "main" > > > > org.apache.axis2.wsdl.codegen.CodeGenerationException > > > > > > > > : java.lang.RuntimeException: The use 'encoded' is not > > supported! > > > > > at > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationE >ngine.java:105) > > > > > at > > org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:30) > > > > > at > > org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21) > > > > > Caused by: java.lang.RuntimeException: The use 'encoded' is not > > > > supported! > > > > at > > org.apache.axis2.wsdl.codegen.extension.XMLBeansExtension.foo(XMLBeansExten >sion.java:334) > > > > > at > > org.apache.axis2.wsdl.codegen.extension.XMLBeansExtension.checkCompat > > > > > ibility(XMLBeansExtension.java:319) > > > > at > > org.apache.axis2.wsdl.codegen.extension.XMLBeansExtension.engage(XMLBeansEx >tension.java:86) > > > > > at > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationE >ngine.java:76) > > > > > ... 2 more > > > > > > > > Any suggestions? > > > > > > > > I already tried the sample which worked OK: > > > > WSDL2Java -uri ..\samples\wsdl\Axis2SampleDocLit.wsdl -ss -sd -o > > > > ..\samples\src -p org.apache.axis2.userguide > > > > > > > > Without a Java2WSDL I dont think I can try another approach than > > > > > > using > > > > > > > the wsdl from Axis 1.3. > > > > > > > > Thanks. > > > > > > > > > > > > Simon McMahon > > > > > > > > Work: (07) 31311420 > > > > Mobile: (043) 2294180 > > > > > > > > >>> [EMAIL PROTECTED] 12/07/05 02:21pm >>> > > > > > > > > try renaming the service.xml with services.xml. This was changed > > > > in > > > > > > the > > > > last > > > > release but I'm afraid it's not provided with enough > > documentation > > > > > On 12/7/05, Chathura Herath <[EMAIL PROTECTED]> wrote: > > > > > Sorry i didnt notice that you are using M2. > > > > > Chathura > > > > > > > > > > On 12/6/05, Simon McMahon <[EMAIL PROTECTED]> > > > > wrote: > > > > > > For some reason I thought M2 was the most recent ??? > > > > > > I have now installed 0.93 so I will try again. I see already > > > > > > that > > > > > > > I > > > > > > > > > > should let the tools generate the service.xml and not try to > > > > > > write > > > > > > > it by > > > > > > > > > > hand. > > > > > > > > > > > > You obviously have been busy since M2 :-). > > > > > > > > > > > > Thanks, > > > > > > > > > > > > Simon. > > > > > > > > > > > > > > > > > > Simon McMahon > > > > > > > > > > > > Work: (07) 31311420 > > > > > > Mobile: (043) 2294180 > > > > > > > > > > > > >>> [EMAIL PROTECTED] 12/07/05 11:47am >>> > > > > > > > > > > > > I think Deepal fixed this in later releases. > > > > > > > > > > > > BTW, Simon, we have come a long long way since M2. The > > latest > > > > 0.93 > > > > > > > > > version is much more flexible, stable, feature rich and blah > > > > > > blah > > > > > > > blah > > > > > > > > > > than M2 (Obviously). > > > > > > > > > > > > So please try to play with 0.93 forgetting M2. > > > > > > > > > > > > Chathura Herath wrote: > > > > > > >Blind guess. Check whether the dir of the aar name is > > > > META-INF. > > > > > > > > >"meta-inf" might not work > > > > > > >Chathura > > > > > > > > > > > > > >On 12/6/05, Simon McMahon <[EMAIL PROTECTED]> > > > > > > > > wrote: > > > > > > >>Hi, > > > > > > >> > > > > > > >>I have previously been working with 1.3 and have some > > > > services > > > > > > > > deployed > > > > > > > > > > > > >>and working OK under that. > > > > > > >> > > > > > > >>I just installed Axis2 (axis2-M2-bin build (June 07, > > 2005)) > > > on > > > > > > XP, > > > > > > > > > > >>Tomcat 4.1.31, Java 1.4.2_08. > > > > > > >> > > > > > > >>It installed just fine and I got the Axis happiness page > > as > > > > > > > expected. > > > > > > > > > > > > >>I have my own service for Axis 1.3 but to install it for 2 > > I > > > > > need > > > > a > > > > > > > > > > >>service.xml to complete the .aar > > > > > > >>It is a pretty simple service and the wsdd is: > > > > > > >> > > > > > > >><deployment name="test" > > > > > > xmlns="http://xml.apache.org/axis/wsdd/" > > > > > > xmlns:java="http://xml.apache.org/axis/wsdd/providers/java"> > > > > > > > > > >> <service name="qh-providers" provider="java:RPC"> > > > > > > >> <parameter name="className" > > > >> > > > >>value="au.gov.qld.health.s8online.providerdir.ProviderService"/> > > > >> > > > > > > >> <parameter name="allowedMethods" value="*"/> > > > > > > >> <parameter name="wsdlServicePort" > > value="GetProvider"/> > > > > > > > >> </service> > > > > > > >></deployment> > > > > > > >> > > > > > > >>I just guessed this content for the service.xml: > > > > > > >><service name="qh-providers"> > > > > > > >> <description>Provider Search Web > > > > Service</description> > > > > > > > > >> <parameter name="ServiceClass" > > > > > > >>locked="xsd:false"> > > > > au.gov.qld.health.s8online.providerdir.ProviderService</parameter> > > > > > > > > >> <operation name="GetProvider"> > > > > > > >> <messageReceiver > > > >> > > > >>class="au.gov.qld.health.s8online.providerdir.ProviderService"/> > > > >> > > > > > > >> </operation> > > > > > > >></service> > > > > > > >> > > > > > > >>I put this into the meta-inf directory in the .aar and > > > > > > deployed > > > > > > > it > > > > > > > > > > to > > > > > > > > > > > > >>D:\Tomcat\4.1.31\webapps\axis2\WEB-INF\services > > > > > > >>It found the .aar and my service but came up as a faulty > > > > > > service > > > > > > > > > with > > > > > > > > > > > > >>This Web service has deployment faults > > > > > > >>Error: service.xml not found > > > > > > >> > > > > > > >>The service.xml is definitely in the meta-inf of the .aar > > > > but > > > > > > the > > > > > > > > > > >>content is pretty likely to be wrong. Any suggestions on > > how > > > I > > > > > > can > > > > > > > > > > >>trouble shoot this? > > > > > > >> > > > > > > >>Regards, > > > > > > >> > > > > > > >>Simon. > > > > > > >> > > > > > > >> > > > > > > >> > > > > > > >>Simon McMahon > > > > > > >> > > > > > > >>Work: (07) 31311420 > > > > > > >>Mobile: (043) 2294180 > > >> > > >>***************************************************************** > > >> > > > > > > >>This email, including any attachments sent with it, is > > > > > > >>confidential and for the sole use of the intended > > > > > > recipient(s). > > > > > > > > > >>This confidentiality is not waived or lost, if you receive > > > > it > > > > > > and > > > > > > > > > > >>you are not the intended recipient(s), or if it is > > > > > > transmitted/ > > > > > > > > > >>received in error. > > > > > > >> > > > > > > >>Any unauthorised use, alteration, disclosure, distribution > > > > or > > > > > > > > >>review of this email is strictly prohibited. The > > > > information > > > > > > > > >>contained in this email, including any attachment sent > > with > > > > > > > >>it, may be subject to a statutory duty of confidentiality > > if > > > > it > > > > > > > > > >>relates to health service matters. > > > > > > >> > > > > > > >>If you are not the intended recipient(s), or if you have > > > > > > >>received this email in error, you are asked to immediately > > > > > > >>notify the sender by telephone collect on Australia > > > > > > >>+61 1800 198 175 or by return email. You should also > > > > > > >>delete this email, and any copies, from your computer > > > > > > >>system network and destroy any hard copies produced. > > > > > > >> > > > > > > >>If not an intended recipient of this email, you must not > > > > copy, > > > > > > > > >>distribute or take any action(s) that relies on it; any > > form > > > > of > > > > > > > > > >>disclosure, modification, distribution and/or publication > > of > > > > > this > > > > > > > > > > >>email is also prohibited. > > > > > > >> > > > > > > >>Although Queensland Health takes all reasonable steps to > > > > > > >>ensure this email does not contain malicious software, > > > > > > >>Queensland Health does not accept responsibility for the > > > > > > >>consequences if any person's computer inadvertently > > suffers > > > > > > > >>any disruption to services, loss of information, harm or > > is > > > > > > > >>infected with a virus, other malicious computer programme > > or > > > > > > > >>code that may occur as a consequence of receiving this > > > > > > >>email. > > > > > > >> > > > > > > >>Unless stated otherwise, this email represents only the > > > > views > > > > > > > > >>of the sender and not the views of the Queensland > > > > Government. > > > > > >>**************************************************************** > > > >> > > > > > > >-- > > > > > > >Chathura Herath > > > > > > >http://www.bloglines.com/blog/chathurah > > > > > > ***************************************************************** > > > > > > > > > This email, including any attachments sent with it, is > > > > > > confidential and for the sole use of the intended > > > > recipient(s). > > > > > > > > This confidentiality is not waived or lost, if you receive > > it > > > > and > > > > > > > > > you are not the intended recipient(s), or if it is > > > > transmitted/ > > > > > > > > received in error. > > > > > > > > > > > > Any unauthorised use, alteration, disclosure, distribution > > or > > > > > > > review of this email is strictly prohibited. The > > information > > > > > > > contained in this email, including any attachment sent with > > > > > > it, may be subject to a statutory duty of confidentiality if > > > > it > > > > > > > > relates to health service matters. > > > > > > > > > > > > If you are not the intended recipient(s), or if you have > > > > > > received this email in error, you are asked to immediately > > > > > > notify the sender by telephone collect on Australia > > > > > > +61 1800 198 175 or by return email. You should also > > > > > > delete this email, and any copies, from your computer > > > > > > system network and destroy any hard copies produced. > > > > > > > > > > > > If not an intended recipient of this email, you must not > > copy, > > > > > > > distribute or take any action(s) that relies on it; any form > > > > of > > > > > > > > disclosure, modification, distribution and/or publication of > > > > > > this > > > > > > > > > email is also prohibited. > > > > > > > > > > > > Although Queensland Health takes all reasonable steps to > > > > > > ensure this email does not contain malicious software, > > > > > > Queensland Health does not accept responsibility for the > > > > > > consequences if any person's computer inadvertently suffers > > > > > > any disruption to services, loss of information, harm or is > > > > > > infected with a virus, other malicious computer programme or > > > > > > code that may occur as a consequence of receiving this > > > > > > email. > > > > > > > > > > > > Unless stated otherwise, this email represents only the > > views > > > > > > > of the sender and not the views of the Queensland > > Government. > > > **************************************************************** > > > > > > > -- > > > > > Chathura Herath > > > > > http://www.bloglines.com/blog/chathurah > > > > > > > > -- > > > > Ajith Ranabahu > > > > > > -- > > > Chathura Herath > > > http://www.bloglines.com/blog/chathurah > > > > -- > > Chathura Herath > > http://www.bloglines.com/blog/chathurah > > -- > Chathura Herath > http://www.bloglines.com/blog/chathurah