Return-Path: Delivered-To: apmail-ws-axis-dev-archive@www.apache.org Received: (qmail 95126 invoked from network); 21 Aug 2007 03:33:26 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 21 Aug 2007 03:33:26 -0000 Received: (qmail 38238 invoked by uid 500); 21 Aug 2007 03:33:21 -0000 Delivered-To: apmail-ws-axis-dev-archive@ws.apache.org Received: (qmail 38192 invoked by uid 500); 21 Aug 2007 03:33:21 -0000 Mailing-List: contact axis-dev-help@ws.apache.org; run by ezmlm Precedence: bulk Reply-To: axis-dev@ws.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list axis-dev@ws.apache.org Received: (qmail 38180 invoked by uid 99); 21 Aug 2007 03:33:21 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 20 Aug 2007 20:33:21 -0700 X-ASF-Spam-Status: No, hits=4.7 required=10.0 tests=DNS_FROM_SECURITYSAGE,HTML_MESSAGE,RCVD_NUMERIC_HELO,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of zzl_5337@163.com designates 220.181.13.121 as permitted sender) Received: from [220.181.13.121] (HELO m13-121.163.com) (220.181.13.121) by apache.org (qpsmtpd/0.29) with SMTP; Tue, 21 Aug 2007 03:33:46 +0000 Received: from 210.83.210.189 ( 210.83.210.189 [210.83.210.189] ) by ajax-webmail-wmsvr121 (Coremail) ; Tue, 21 Aug 2007 11:32:42 +0800 (CST) Date: Tue, 21 Aug 2007 11:32:42 +0800 (CST) From: "Zhang zhongliang" To: axis-dev@ws.apache.org Message-ID: <839322731.216531187667162329.JavaMail.coremail@bj163app121.163.com> In-Reply-To: <60708f4b0708202021x5079fbacwb7151b3ca9c5f18e@mail.gmail.com> References: <60708f4b0708202021x5079fbacwb7151b3ca9c5f18e@mail.gmail.com> <1591849069.172751187664742011.JavaMail.coremail@bj163app121.163.com> <60708f4b0708202003v4553df97i6bb270c6639d4b3@mail.gmail.com> <1749031546.194571187665923777.JavaMail.coremail@bj163app121.163.com> Subject: Re:Re: Re: axis2:how to validate soap message against wsdl? MIME-Version: 1.0 Content-Type: multipart/Alternative; boundary="----=_Part_22894_1004219272.1187667162328" X-Originating-IP: [192.168.208.53 (210.83.210.189)] X-Priority: 3 X-Mailer: Coremail Webmail Server Version XT_070725 build 070725(3676.1195.1194) Copyright (c) 2002-2007 www.mailtech.cn 163com X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_22894_1004219272.1187667162328 Content-Type: text/plain; charset=gbk Content-Transfer-Encoding: quoted-printable Thanks a lot. I just do not want to use the wsdl2java tool to generate code for me.For I = use axis2 to develop commercial project,so I need to obey some rules,for ex= ample,the code conventions that the customer provided. For example,I have a piece of code from wsdl:types like this: =09 =09=09 =09=09=09 =09=09=09 =09=09 =09 It is a kind of search,by name or email,So I them to a xsd file,named CertS= ummarySearch.xsd,then I use the xsd to validate soap message's payload part= ,for example,the following message is valid: =09keyword and if the following message is invalid,because of it contains Name and Ema= il elements at the same time: =09keyword =09keyword That works for me,but I need to use the Schema,Validator class and related. thanks for your help. =D4=DA2007-08-21=A3=AC"Amila Suriarachchi" = =D0=B4=B5=C0=A3=BA There is no such a property. becuase to valide an soap message against a th= e schema it should complie the schema and do it accordling. But if you have problems in understanding the ADB generated code. I can hel= p you for that.=20 Amila. On 8/21/07, Zhang zhongliang wrote:=20 First of all,thanks for your advice. Do you mean use ADB data binding,but if I use the wsdl2java tool to generat= e code,it will generate too much code lines,and which are not easy to under= stand,also the method of naming variables and methods.=20 What I need is keeping the program simple,so I wonder whether there is a wa= y to set a property in the configuration file,which will enable the axis2 t= o validate the soap message(payload part) against wsdl for me.For example,i= f I put the following part:true in the services.xml in META-INF folder,then when I wa= nt to view the wsdl file,then I will view my own wsdl,not the one that axis= 2 generates automatically. So,Is there any properties that I can just configure in the configuration f= ile( axis2.xml,services.xml) to get what I wanted? Thanks a lot. =D4=DA2007-08-21=A3=AC"Amila Suriarachchi" < amilasuriarachchi@gmail.com> = =D0=B4=B5=C0=A3=BA=20 Is there any reason to deal with the OMElement directly? if you generate the data bind code for wsdl using ADB then when the request= parsing time ADB validates the request and give you the object structure.= =20 you can use wsdl2java.sh tool to generate ADB code. Amila. On 8/21/07, Zhang zhongliang < zzl_5337@163.com> wrote:=20 Hi,I am the beginner to use this mailing list,so,any mistakes that I made,I= hope I can be forgiven.=20 I have a problem when I using apache-axis2-1.1.1,the web service my team de= veloped will be accessed by other client,although we provided the wsdl to t= he client,but errors may also exist with the format of the soap message.=20 I choose the wsdl:types elements out and form the xsd schema file(.xsd),and= then use it to validate the soap message(Which is an OMElement object). Now I want to ask whether there is a flag that I can configure to make axis= 2 validate the soap message against wsdl for me automatically?=20 Thanks so much! =C8=AB =B9=FA =CD=F2 =C3=FB =D6=B0 =B3=A1 =C5=AE =D0=D4=A3=AC=C6=EB =BE=DB = =B7=C7 =B3=A3 =C3=C0 =C5=AE=A3=AC=BE=AA =D1=DE 2 0 0 7=20 --=20 Amila Suriarachchi, WSO2 Inc.=20 =CD=F8 =D2=D7 Yeah.net =D3=CA =CF=E4 =CF=C4 =C8=D5 =B4=F3 =B1=E4 =C1=B3=A3= =AC=B4=F8 =C4=E3 =B8=D0 =CA=DC =D0=C2 =D2=BB =B4=FA =D3=CA =CF=E4 =B5=C4 = =C8=AB =D0=C2 =F7=C8 =C1=A6 >>=20 --=20 Amila Suriarachchi, WSO2 Inc. ------=_Part_22894_1004219272.1187667162328 Content-Type: text/html; charset=gbk Content-Transfer-Encoding: quoted-printable Thanks a lot.
I just do not want to use the wsdl2java tool to generate c= ode for me.For I use axis2 to develop commercial project,so I need to obey = some rules,for example,the code conventions that the customer provided.
= For example,I have a piece of code from wsdl:types like this:
<xsd:el= ement name=3D"CertSummaryRequest">
=09<xsd:complexType>
=09= =09<xsd:choice>
=09=09=09<xsd:element name=3D"Name" type=3D"xsd= :string" />
=09=09=09<xsd:element name=3D"Email" type=3D"xsd:strin= g" />
=09=09</xsd:choice>
=09</xsd:complexType>
<= ;/xsd:element>
It is a kind of search,by name or email,So I them to a= xsd file,named CertSummarySearch.xsd,then I use the xsd to validate soap m= essage's payload part,for example,the following message is valid:
<tn= s:CertSummaryRequest xmlns:tns=3D"http://example/">
=09<tns:Name&g= t;keyword</tns:Name>
</tns:CertSummaryRequest>
and if the= following message is invalid,because of it contains Name and Email element= s at the same time:
<tns:CertSummaryRequest xmlns:tns=3D"http://examp= le/">
=09<tns:Name>keyword</tns:Name>
=09<tns:Email= >keyword</tns:Email>
</tns:CertSummaryRequest>

Tha= t works for me,but I need to use the Schema,Validator class and related.thanks for your help.

=D4=DA2007-08-21=A3=AC"Amila Suriarachchi" &l= t;amilasuriarachchi@gmail.com> =D0=B4=B5=C0=A3=BA

There is no suc= h a property. becuase to valide an soap message against a the schema it sho= uld complie the schema and do it accordling.

But if you have problem= s in understanding the ADB generated code. I can help you for that.
Amila.


On 8/21/07, Zhang zhongliang <zzl_5337@163.com> wr= ote:
First of all,thanks for your advice.
Do you mean use ADB data b= inding,but if I use the wsdl2java tool to generate code,it will generate to= o much code lines,and which are not easy to understand,also the method of n= aming variables and methods.
What I need is keeping the program simple,= so I wonder whether there is a way to set a property in the configuration f= ile,which will enable the axis2 to validate the soap message(payload part) = against wsdl for me.For example,if I put the following part:<parameter n= ame=3D"useOriginalwsdl" locked=3D"false">true</parameter> in the s= ervices.xml in META-INF folder,then when I want to view the wsdl file,then = I will view my own wsdl,not the one that axis2 generates automatically.
= So,Is there any properties that I can just configure in the configuration f= ile( axis2.xml,services.xml) to get what I wanted?
Thanks a lot.

=


=D4=DA2007-08-21=A3=AC"Amila Suriarachchi" < amilasuriarachc= hi@gmail.com> =D0=B4=B5=C0=A3=BA


Is there any reason to deal= with the OMElement directly?

if you generate the data bind code for= wsdl using ADB then when the request parsing time ADB validates the reques= t and give you the object structure.

you can use wsdl2java.sh tool = to generate ADB code.

Amila.


On 8/21/07, Zhang zhongliang= < zzl_5337@163.com> wrote:
Hi,I am the beginner to use this mail= ing list,so,any mistakes that I made,I hope I can be forgiven.
I have a= problem when I using apache-axis2-1.1.1,the web service my team developed = will be accessed by other client,although we provided the wsdl to the clien= t,but errors may also exist with the format of the soap message.
I choo= se the wsdl:types elements out and form the xsd schema file(.xsd),and then = use it to validate the soap message(Which is an OMElement object).
Now I= want to ask whether there is a flag that I can configure to make axis2 val= idate the soap message against wsdl for me automatically?
Thanks so muc= h!




=C8=AB =B9=FA =CD=F2 =C3=FB =D6=B0 =B3=A1 =C5=AE =D0= =D4=A3=AC=C6=EB =BE=DB =B7=C7 =B3=A3 =C3=C0 =C5=AE=A3=AC=BE=AA =D1=DE 2 0 0= 7



--
Amila Suriarachchi,
WSO2 Inc.



=

=CD=F8 =D2=D7 Yeah.net =D3=CA =CF=E4 =CF=C4 =C8=D5 =B4=F3 =B1=E4 = =C1=B3=A3=AC=B4=F8 =C4=E3 =B8=D0 =CA=DC =D0=C2 =D2=BB =B4=FA =D3=CA =CF=E4 = =B5=C4 =C8=AB =D0=C2 =F7=C8 =C1=A6 >>



--
Amila Su= riarachchi,
WSO2 Inc.



=CD=F8 =D2=D7 Yeah.net =D3=CA =CF=E4 =CF=C4 =C8=D5 =B4=F3 =B1=E4 =C1= =B3=A3=AC=B4=F8 =C4=E3 =B8=D0 =CA=DC =D0=C2 =D2=BB =B4=FA =D3=CA =CF=E4 =B5= =C4 =C8=AB =D0=C2 =F7=C8 =C1=A6 >> ------=_Part_22894_1004219272.1187667162328--