Return-Path: Delivered-To: apmail-ws-axis-c-user-archive@www.apache.org Received: (qmail 70526 invoked from network); 27 Mar 2008 20:57:21 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 27 Mar 2008 20:57:21 -0000 Received: (qmail 27062 invoked by uid 500); 27 Mar 2008 20:57:21 -0000 Delivered-To: apmail-ws-axis-c-user-archive@ws.apache.org Received: (qmail 26783 invoked by uid 500); 27 Mar 2008 20:57:20 -0000 Mailing-List: contact axis-c-user-help@ws.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: List-Id: "Apache AXIS C User List" Reply-To: "Apache AXIS C User List" Delivered-To: mailing list axis-c-user@ws.apache.org Received: (qmail 26772 invoked by uid 99); 27 Mar 2008 20:57:20 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 27 Mar 2008 13:57:20 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of sergiomdgomes@gmail.com designates 72.14.204.227 as permitted sender) Received: from [72.14.204.227] (HELO qb-out-0506.google.com) (72.14.204.227) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 27 Mar 2008 20:56:40 +0000 Received: by qb-out-0506.google.com with SMTP id e34so5094025qbe.6 for ; Thu, 27 Mar 2008 13:56:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=dkRLaTZ3pxS0P71IlaHiRKMdZVdtRPd3WEvPQqhyzW0=; b=GFu1J5jb7AbmouiCK9O623MQ0NxIKzv8zYh8il0SAsHOJsK6leWQXAB15du/mZUBQCcx+U41JPRVYSX7CowVevm2Q4plK0nfmceCbk55ziExA/VZ2ljJIhW4FN29osWlL2WpJzEUdpsLjfJTBmTz37XlOGKkb/OaWovr1A+A6g4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=Nji/dfFncpCzKo4NNhaJdUkTlnfGoZ4P+QBP9FP3A1AL5/roWc+fiiRu3+YZ1ozdv/wjopzlbwcwr5N7rhvs830FKWVstKAKI8fXwmFAJK5fwG0z1LY1ulaOEC4hZ7PiUhJNNVCKL1A7kVFYBbx5gN8F2o/l7LPHy4FzteO5jf8= Received: by 10.114.144.1 with SMTP id r1mr2420516wad.53.1206651411268; Thu, 27 Mar 2008 13:56:51 -0700 (PDT) Received: by 10.115.19.6 with HTTP; Thu, 27 Mar 2008 13:56:51 -0700 (PDT) Message-ID: <89fb8be00803271356s201a21f8qd49847212d8a897d@mail.gmail.com> Date: Thu, 27 Mar 2008 20:56:51 +0000 From: "=?ISO-8859-1?Q?S=E9rgio_Gomes?=" To: "Apache AXIS C User List" Subject: Re: Header parameters being ignored In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <89fb8be00803261400g3a241b15h816a9aa2b4a15357@mail.gmail.com> <89fb8be00803270326r1f47a671ndce937bb8daaf36a@mail.gmail.com> X-Virus-Checked: Checked by ClamAV on apache.org Hi Dimuthu, I looked around in the source code quite a bit and wasn't able to find any way to get the envelope node that I required to create a header node. I'd have to get the message context somehow, which I don't think makes sense from axis2_svc_client 's point of view (since presumably one svc_client can emit many messages and thus have many message contexts in its lifetime). That would indeed coincide with your analysis that an API change would be needed. Of course, my analysis may be completely wrong, since I'm an outsider to the code and I was just poking around trying to scratch my itch :) Anyway, regarding your solution for the code generator, that looks like what's needed, that is, assuming that adb_input_header_t and adb_out_header_t would be the ADB models for whatever objects we were trying to set in the header (say, a simpleType with a "string" restriction). I'll give it a try tomorrow to adapt that tentative code to the code I had generated and see how it goes. Cheers, S=E9rgio --- On Thu, Mar 27, 2008 at 6:31 PM, Dimuthu Gamage wrote: > Hi S=E9rgio, > > Hm, Actually you will face a problem if you try to add headers > manually. Because currently axis2_svc_client doesnt have a way to get > response headers. So there is an API change needed. Please correct me > if I m wrong on this. > > I was thinking implement the thing in this way. Say you have a > operation so that it has one input message, one input header one > output header, I m assuming there is a function called > get_response_header. > > > axis2_stub_op_exampleOp(axis2_stub_t *stub, adb_input_t *input, > adb_input_header_t *header_in, adb_out_header_t **header_out) > { > /* the following part should be added before send_receive call */ > axiom_node_t * header1; > header1 =3D adb_input_header_serialize(header_in, env, NULL, NULL, > AXIS2_TRUE, NULL, NULL); > svc_client =3D axis2_stub_get_svc_client(stub, env); //this is already= there > > axis2_svc_client_add_header(svc_client, env, header1); > > > /* this is after send recieve */ > axutil_array_list_t * headers =3D axis2_svc_client_get_response_header= s(..); > header_node =3D (adb_out_header_t *) axutil_array_list_get(headers, en= v, 0); > > *out_header =3D adb_output_header_create(env); > adb_output_header_deserialize(*out_header, env, &header_node, NULL, > AXIS2_FALSE ) ; > > } > > Anyway you won't be able to handle that manually since currently axis2 > api doesn't have a function to get output headers :(. I will raise a > JIRA on this. > > Thanks > Dimuthu > > > > > On Thu, Mar 27, 2008 at 3:56 PM, S=E9rgio Gomes wrote: > > Hi Dimuthu, > > > > Thanks for the update, let me know if you'd like me to do some testin= g > > once it's done. > > > > In the meantime, is there any way I can overcome this, by, say, > > providing the header part of the XML myself? > > > > Cheers, > > S=E9rgio > > > > --- > > > > > > On Thu, Mar 27, 2008 at 4:22 AM, Dimuthu Gamage w= rote: > > > Hi S=E9rgio, > > > Currently WSDL2C doesn't support picking headers from the wsdl. Th= e > > > classes are generated because it support in wsdl2java tool. Anyway= I m > > > right now working in that and the class name problem. Hope I can f= ix > > > this for the client side within this week > > > > > > Thanks > > > Dimuthu > > > > > > > > > > > > On Thu, Mar 27, 2008 at 2:30 AM, S=E9rgio Gomes wrote: > > > > Hello again, > > > > > > > > When sending my SOAP messages, I noticed that the headers were = always > > > > empty, even though the WSDL2C tool generated support for the he= ader > > > > fields: > > > > > > > > adb_getAllAdWordsCampaignsResponse_t* > > > > axis2_stub_op_CampaignService_getAllAdWordsCampaigns= ( > > > > axis2_stub_t *stub, const axutil_env_t *env, > > > > > > > > adb_getAllAdWordsCampaigns_t* _getAllAdWordsCampaigns, > > > > > > > > adb_useragent_t* _useragent22, > > > > > > > > adb_password_t* _password23, > > > > adb_emai= l_t* _email24, > > > > > > > > adb_clientEmail_t* _clientEmail25, > > > > > > > > adb_clientCustomerId_t* _clientCustomerId26, > > > > > > > > adb_developerToken_t* _developerToken27, > > > > > > > > adb_applicationToken_t* _applicationToken28); > > > > > > > > (There is also a bug that prevents the correct generation of th= e class > > > > names, but it has already been confirmed and will be fixed, acc= ording > > > > to the reply I received when I posted that issue) > > > > (WSDL can be found at > > > > https://adwords.google.com/api/adwords/v11/CampaignService?wsdl= ) > > > > > > > > As you can see, the function header has all the items that shou= ld > > > > appear on the SOAP header (useragent, password, etc), yet when = I > > > > analyzed the generated .c file, I noticed that these parameters= were > > > > being used nowhere, and thus the header would always be empty. > > > > > > > > Any tips on this issue? Also, is there an alternate way to set = the > > > > outgoing SOAP header, so that I can work around the issue? > > > > > > > > > > > > Thanks, > > > > S=E9rgio > > > > > > > > ---------------------------------------------------------------= ------ > > > > To unsubscribe, e-mail: axis-c-user-unsubscribe@ws.apache.org > > > > For additional commands, e-mail: axis-c-user-help@ws.apache.org > > > > > > > > > > > > > > ------------------------------------------------------------------= --- > > > To unsubscribe, e-mail: axis-c-user-unsubscribe@ws.apache.org > > > For additional commands, e-mail: axis-c-user-help@ws.apache.org > > > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: axis-c-user-unsubscribe@ws.apache.org > > For additional commands, e-mail: axis-c-user-help@ws.apache.org > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: axis-c-user-unsubscribe@ws.apache.org > For additional commands, e-mail: axis-c-user-help@ws.apache.org > > --------------------------------------------------------------------- To unsubscribe, e-mail: axis-c-user-unsubscribe@ws.apache.org For additional commands, e-mail: axis-c-user-help@ws.apache.org