You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Florent Georges <li...@fgeorges.org> on 2007/08/29 20:17:31 UTC

Where does Axis2 look for WSDL on "...?wsdl" URI?

  Hi

  I am looking for the way the WSDL is find (and where it
is looking for) when someone request it by a URI ending
with ?wsdl.

  Does someone can explain me or redirect me to an appropriate
source?  I did look into the manual but really I didn't find
it.

  Thanks in advance.  Regards,

--drkm






















      _____________________________________________________________________________ 
Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail 

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: Where does Axis2 look for WSDL on "...?wsdl" URI?

Posted by Florent Georges <li...@fgeorges.org>.
Amandeep Singh wrote:

  Hi

> Check this out

> http://www.developer.com/open/article.php/3589126

  Very interesting.  Thank for the link.  The point #3 in particular
interests me in the context of my problem.  Though it helped me to get
a better view of that process, it didn't help me to solve the problem.

  I am still searching...

  Thank you.  Regards,

--drkm























      _____________________________________________________________________________ 
Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail 


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


RE: Where does Axis2 look for WSDL on "...?wsdl" URI?

Posted by Amandeep Singh <as...@quark.com>.
Check this out

http://www.developer.com/open/article.php/3589126

-- Aman

-----Original Message-----
From: Florent Georges [mailto:lists@fgeorges.org] 
Sent: Wednesday, August 29, 2007 12:18 PM
To: axis-user@ws.apache.org
Subject: Where does Axis2 look for WSDL on "...?wsdl" URI?


  Hi

  I am looking for the way the WSDL is find (and where it
is looking for) when someone request it by a URI ending
with ?wsdl.

  Does someone can explain me or redirect me to an appropriate
source?  I did look into the manual but really I didn't find
it.

  Thanks in advance.  Regards,

--drkm






















 
________________________________________________________________________
_____ 
Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo!
Mail 

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: [Axis2] Enum

Posted by Sanka Samaranayake <ss...@gmail.com>.
AFAIK new Axis2 doesn't support this feature.

Best,
Sanka

On 8/30/07, Leon Hwang <hw...@mystrands.com> wrote:
>
> Can someone explain how I can return enum type object from Axis2 server?
>
> I am using Axis2 1.3 / Tomcat 6.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-dev-help@ws.apache.org
>
>


-- 
Sanka Samaranayake
WSO2 Inc.

http://www.bloglines.com/blog/sanka
http://www.wso2.org/

Re: [Axis2] Enum

Posted by Leon Hwang <hw...@mystrands.com>.
Amil,

First, please refer to the attached email.
According to Sanka, the enum type fix is on the table for the next release.
I would like to confirm with you this would be in Axis2 1.4.
By the way, when does it get released? In October?

To respond to your answer:
Yes, wsdl2java might support enum type.
But the problem is that the server spits out a complex type instead of a simple type with restrictions.
Please try it yourself.
This problem could be solved by writing a custome WSDL or a custome data locator.

However, here's the REAL main problem.
The server does NOT work with any enum type.
You will encounter a runtime exception when it returns or accepts an enum type.

I wonder if this is all solved in the nightly-build version now.

Thanks,

- Leon



Amila Suriarachchi wrote:
> 
> 
> On 9/3/07, *Mark Nüßler* <mark.nuessler@9elements.com 
> <ma...@9elements.com>> wrote:
> 
>     hello leon,
> 
>     it seems to me, that java2wsdl and wsdl2java does not support enums.
> 
> 
> wsdl2java support this.  in a wsdl enumeration is represented by a 
> simple type restriction enumeration.
> eg.
> <simpletype name="test">
>   <restriction base = "xs:string">
>      <enumeration value="testvalue"/>
>   </restriction>
> </simpletype>
> 
> and this type of xsd are supported in wsdl2java.
> 
>     a workaround that works 4 me is to replace the enum with a String
>     before generating anything.
> 
>     on the serverside convert your enum to String
> 
>     Gender g = Gender.MALE;
>     String g_send = g.toString();
> 
>     an on clientside test, if the String is a valid enum
> 
>     try {
>             Gender g_test = Gender.valueOf (g_send.toUpperCase());
>             System.out.println("valid Gender");
>     } catch(Exception e) {
>             System.out.println("invalid Gender");
>     }
> 
>     i know its just a workaround
> 
>     mfg derMark
> 
> 
> 
> 
> 
> 
> 
>     Leon Hwang schrieb:
>      > Can someone explain how I can return enum type object from Axis2
>     server?
>      >
>      > I am using Axis2 1.3 / Tomcat 6.
>      >
>      >
>     ---------------------------------------------------------------------
>      > To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
>     <ma...@ws.apache.org>
>      > For additional commands, e-mail: axis-user-help@ws.apache.org
>     <ma...@ws.apache.org>
>      >
>      >
>      >
> 
>     ---------------------------------------------------------------------
>     To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
>     <ma...@ws.apache.org>
>     For additional commands, e-mail: axis-user-help@ws.apache.org
>     <ma...@ws.apache.org>
> 
> 
> 
> 
> -- 
> Amila Suriarachchi,
> WSO2 Inc.

-- 
Leon Hwang
MyStrands, Inc.

work: 1.541.753.4426
mobile: 1.541.740.7511
fax: 1.541.754.6416
email: hwang@MyStrands.com

Re: [Axis2] Enum

Posted by Amila Suriarachchi <am...@gmail.com>.
On 9/3/07, Mark Nüßler <ma...@9elements.com> wrote:
>
> hello leon,
>
> it seems to me, that java2wsdl and wsdl2java does not support enums.


wsdl2java support this.  in a wsdl enumeration is represented by a simple
type restriction enumeration.
eg.
<simpletype name="test">
  <restriction base = "xs:string">
     <enumeration value="testvalue"/>
  </restriction>
</simpletype>

and this type of xsd are supported in wsdl2java.

a workaround that works 4 me is to replace the enum with a String
> before generating anything.
>
> on the serverside convert your enum to String
>
> Gender g = Gender.MALE;
> String g_send = g.toString();
>
> an on clientside test, if the String is a valid enum
>
> try {
>         Gender g_test = Gender.valueOf(g_send.toUpperCase());
>         System.out.println("valid Gender");
> } catch(Exception e) {
>         System.out.println("invalid Gender");
> }
>
> i know its just a workaround
>
> mfg derMark
>
>
>
>
>
>
>
> Leon Hwang schrieb:
> > Can someone explain how I can return enum type object from Axis2 server?
> >
> > I am using Axis2 1.3 / Tomcat 6.
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> > For additional commands, e-mail: axis-user-help@ws.apache.org
> >
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>


-- 
Amila Suriarachchi,
WSO2 Inc.

Re: [Axis2] Enum

Posted by Mark Nüßler <ma...@9elements.com>.
hello leon,

it seems to me, that java2wsdl and wsdl2java does not support enums.

a workaround that works 4 me is to replace the enum with a String
before generating anything.

on the serverside convert your enum to String

Gender g = Gender.MALE;
String g_send = g.toString();

an on clientside test, if the String is a valid enum

try {
	Gender g_test = Gender.valueOf(g_send.toUpperCase());
	System.out.println("valid Gender");
} catch(Exception e) {
	System.out.println("invalid Gender");
}

i know its just a workaround

mfg derMark







Leon Hwang schrieb:
> Can someone explain how I can return enum type object from Axis2 server?
> 
> I am using Axis2 1.3 / Tomcat 6.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
> 
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


[Axis2] Enum

Posted by Leon Hwang <hw...@mystrands.com>.
Can someone explain how I can return enum type object from Axis2 server?

I am using Axis2 1.3 / Tomcat 6.

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: Rampart sample/tutorial

Posted by Ruchith Fernando <ru...@gmail.com>.
Please see this :

http://wso2.org/library/240

Thanks,
Ruchith

On 8/31/07, Todd Allen <tb...@copart.com> wrote:
> I need to implement user name/password authentication in an Axis2 1.1
> web service.  Can someone point me to a useful set of samples or a
> good tutorial on Rampart and the user name token?
>
> Thanks,
> Todd
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>


-- 
www.ruchith.org
www.wso2.org

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Rampart sample/tutorial

Posted by Todd Allen <tb...@copart.com>.
I need to implement user name/password authentication in an Axis2 1.1 
web service.  Can someone point me to a useful set of samples or a 
good tutorial on Rampart and the user name token?

Thanks,
Todd


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


[Axis2] Enum

Posted by Leon Hwang <hw...@mystrands.com>.
Can someone explain how I can return enum type object from Axis2 server?

I am using Axis2 1.3 / Tomcat 6.

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


Re: Where does Axis2 look for WSDL on "...?wsdl" URI?

Posted by Florent Georges <li...@fgeorges.org>.
Florent Georges wrote:

> I don't understand how the WSDLConstants.WSDL_4_J_DEFINITION
> parameter is set on the service (if I understand correctly,
> that's that parameter the WSDL is taken from).

  sorry, it seems to be the "WSDLSupplier" parameter instead, accessed
within AxisService.printWSDL().

  Regards,

--drkm




















      ______________________________________________________________________________ 
Stockage illimité de vos mails avec Yahoo! Mail. Changez aujourd'hui de mail !


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: Where does Axis2 look for WSDL on "...?wsdl" URI?

Posted by Florent Georges <li...@fgeorges.org>.
keith chapman wrote:

  Hi

> Checkout the doGet method in the AxisServlet. It intercepts
> these special request and route it appropriately. Its the
> axisService that ultimately prints out its WSDL using the
> printWSDL, printWSDL2 and printUserWSDL methods.

  Thank you for this useful info.  I spent a few time reading
AxisServlet, AxisService and AxisDescription.  Unfortunately
I don't understand how the WSDLConstants.WSDL_4_J_DEFINITION
parameter is set on the service (if I understand correctly,
that's that parameter the WSDL is taken from).

  Who's set this parameter on the service?

  To be a little bit more precise, the project I am working
on doesn't deploy with AAR files, and the WSDL returned
by ?wsdl is really weird.  The WSDL stuff is ok, except the
schema in wsdl:types.  There are only two types, named after
the operation name, which are intended to represent its
request and the response I guess, and whose the content is
xs:anyType:

    <wsdl:types>
       <xs:schema ... targetNamespace="...">
          <xs:element name="OperationXXX">
             <xs:complexType>
                <xs:sequence>
                   <xs:element name="OperationXXX"
                               nillable="true"
                               type="xs:anyType"/>
                </xs:sequence>
             </xs:complexType>
          </xs:element>
          <xs:element name="OperationXXXResponse">
             <xs:complexType>
                <xs:sequence>
                   <xs:element name="return"
                               nillable="true"
                               type="xs:anyType"/>
                </xs:sequence>
             </xs:complexType>
          </xs:element>
       </xs:schema>
    </wsdl:types>

  I looked into the manual to find how the WSDL is found
(generated?), to be able to fix the problem.  But I must
admit that I am a little bit lost here.

  Any clue would be welcome.

  Thanks for your help.

  Regards,

--drkm






















      ______________________________________________________________________________ 
Stockage illimité de vos mails avec Yahoo! Mail. Changez aujourd'hui de mail !


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: Where does Axis2 look for WSDL on "...?wsdl" URI?

Posted by keith chapman <ke...@gmail.com>.
Checkout the doGet method in the AxisServlet. It intercepts these special
request and route it appropriately. Its the axisService that ultimately
prints out its WSDL using  the  printWSDL, printWSDL2 and printUserWSDL
methods.

Thanks,
Keith.

On 8/29/07, Florent Georges <li...@fgeorges.org> wrote:
>
>   Hi
>
>   I am looking for the way the WSDL is find (and where it
> is looking for) when someone request it by a URI ending
> with ?wsdl.
>
>   Does someone can explain me or redirect me to an appropriate
> source?  I did look into the manual but really I didn't find
> it.
>
>   Thanks in advance.  Regards,
>
> --drkm
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>       _____________________________________________________________________________
> Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo!
> Mail
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>


-- 
Keith Chapman
WSO2 Inc.
Oxygen for Web Services Developers.
http://wso2.org/