You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-user@axis.apache.org by Mark Nüßler <ma...@9elements.com> on 2007/06/23 17:37:52 UTC
Re: [AXIS2C] codegen - SOAPAction
hello users,
i have a problem, i will try to explain.
background is that i want to generate
c and java for both sides server and client,
that act and react the same way from a wsdl-file.
in WS-I-Basic
[http://www.ws-i.org/Profiles/BasicProfile-1.1.html
3.4.3 SOAPAction HTTP Header]
it says, when you define : <soapbind:operation soapAction="foo" />
in your wsdl, there has to be a field : SOAPAction: "foo"
in the header
my method "foo" doesn't take any input-parameters and sends
back a simple type.
when i generate the java server and client and take a
look with tcpmon i can see this header and the communication
works fine. the env-header, and env-body i both empty.
now i want my generated c-client to call the same
method "foo" at the java-server, but it sends
SOAPAction = "" in the header, so the value is empty
and the server sends back a fault.
in the generated method "axis2_stub_<servicename>_foo"
on c-client side, the following was generated :
soap_action = axis2_options_get_action(options, env);
if (NULL == soap_action)
{
soap_action = "foo";
axis2_options_set_action(options, env, soap_action);
}
with a breakpoint i found out that the client really
runs the method axis2_options_set_action, so i think
the value of the SOAPAction in the header could be set.
is this thought right ?
otherwise, when my java-client sends the request with the
SOAPAction="foo" in the header, the c-server could not
find the method and replies with the fault :
"Operation Not Found"
[i think this was my problem in the mail from 21.6.2007]
at the c-server side in the method "axis2_svc_skel_<servicename>_invoke"
i implemented the buissness-logic as following :
if (axutil_strcmp(op_name, "foo") == 0)
{
ret_val2 = axis2_skel_<servicename>_foo(env);
ret_node = axis2_DeviceInfo_serialize(ret_val2, env, NULL, 0);
return ret_node;
}
with a breakpoint in the invoke method i found out, that the server
didn't reach this method, when calling with the java-client, but the
java-client sends the SOAPAction="foo".
otherwise when i set up a request with SOAPUI 1.7.1 and
send the methodname "foo" as first element in the soap-body,
the c-server response is fine (the breakpoint was reached).
so what do i have to do, to set the SOAPAction accurately ?
mfg derMark
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-user-help@ws.apache.org
Re: [AXIS2C] codegen - SOAPAction
Posted by Mark Nüßler <ma...@9elements.com>.
hello user,
i have createtd the issue AXIS2C-625,
tried to explain step by step - hope this is helpful.
thx derMark
Milinda Pathirage schrieb:
> Hi Mark,
>
> Can you please create a jira and attach the wsdl. It will be easy to track
> the progress of the solution for this problem. We will look in to this
> problem ASAP.
>
> On 6/23/07, Dr. Florian Steinborn <fp...@gmx.de> wrote:
>>
>> Hi Mark,
>>
>> > otherwise, when my java-client sends the request with the
>> > SOAPAction="foo" in the header, the c-server could not
>> > find the method and replies with the fault :
>> > "Operation Not Found"
>> > [i think this was my problem in the mail from 21.6.2007]
>>
>> And this is exactly what I reported here on June 20th (codegen problem).
>>
>> >
>> > at the c-server side in the method
>> "axis2_svc_skel_<servicename>_invoke"
>> >
>> > i implemented the buissness-logic as following :
>> >
>> > if (axutil_strcmp(op_name, "foo") == 0)
>> > {
>> > ret_val2 = axis2_skel_<servicename>_foo(env);
>> > ret_node = axis2_DeviceInfo_serialize(ret_val2, env, NULL, 0);
>> > return ret_node;
>> > }
>>
>> And this is probably what Milinda suggested...
>>
>>
>> >
>> > with a breakpoint in the invoke method i found out, that the server
>> > didn't reach this method,
>
>
> but in my experience axis2/c engine must execute the invoke method. Also
> please attach the your service implementation if possible.
>
> when calling with the java-client, but the
>> > java-client sends the SOAPAction="foo".
>> >
>> > otherwise when i set up a request with SOAPUI 1.7.1 and
>> > send the methodname "foo" as first element in the soap-body,
>> > the c-server response is fine (the breakpoint was reached).
>> >
>> > so what do i have to do, to set the SOAPAction accurately ?
>>
>> I am sorry - I do not know... I am still thinking about the exception
>> thing from yesterday.... (and can't find a solution...)
>>
>> Flori
>
>
> Thanks in advance
> Milinda
>
> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: axis-c-user-unsubscribe@ws.apache.org
>> For additional commands, e-mail: axis-c-user-help@ws.apache.org
>>
>>
>
>
>
> ------------------------------------------------------------------------
>
> No virus found in this incoming message.
> Checked by AVG Free Edition.
> Version: 7.5.472 / Virus Database: 269.9.6/863 - Release Date: 23.06.2007 11:08
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-user-help@ws.apache.org
Re: [AXIS2C] codegen - SOAPAction
Posted by Milinda Pathirage <mi...@gmail.com>.
Hi Mark,
Can you please create a jira and attach the wsdl. It will be easy to track
the progress of the solution for this problem. We will look in to this
problem ASAP.
On 6/23/07, Dr. Florian Steinborn <fp...@gmx.de> wrote:
>
> Hi Mark,
>
> > otherwise, when my java-client sends the request with the
> > SOAPAction="foo" in the header, the c-server could not
> > find the method and replies with the fault :
> > "Operation Not Found"
> > [i think this was my problem in the mail from 21.6.2007]
>
> And this is exactly what I reported here on June 20th (codegen problem).
>
> >
> > at the c-server side in the method "axis2_svc_skel_<servicename>_invoke"
> >
> > i implemented the buissness-logic as following :
> >
> > if (axutil_strcmp(op_name, "foo") == 0)
> > {
> > ret_val2 = axis2_skel_<servicename>_foo(env);
> > ret_node = axis2_DeviceInfo_serialize(ret_val2, env, NULL, 0);
> > return ret_node;
> > }
>
> And this is probably what Milinda suggested...
>
>
> >
> > with a breakpoint in the invoke method i found out, that the server
> > didn't reach this method,
but in my experience axis2/c engine must execute the invoke method. Also
please attach the your service implementation if possible.
when calling with the java-client, but the
> > java-client sends the SOAPAction="foo".
> >
> > otherwise when i set up a request with SOAPUI 1.7.1 and
> > send the methodname "foo" as first element in the soap-body,
> > the c-server response is fine (the breakpoint was reached).
> >
> > so what do i have to do, to set the SOAPAction accurately ?
>
> I am sorry - I do not know... I am still thinking about the exception
> thing from yesterday.... (and can't find a solution...)
>
> Flori
Thanks in advance
Milinda
---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-c-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-c-user-help@ws.apache.org
>
>
--
milindalakmal@cse.mrt.ac.lk
Department of Computer Science ,
University of Moratuwa,
Sri Lanka.
http://www.milindalakmal.wordpress.com
http://wsaxc.blogspot.com "Web Services with Axis2/C"
Re: [AXIS2C] codegen - SOAPAction
Posted by "Dr. Florian Steinborn" <fp...@gmx.de>.
Hi Mark,
> otherwise, when my java-client sends the request with the
> SOAPAction="foo" in the header, the c-server could not
> find the method and replies with the fault :
> "Operation Not Found"
> [i think this was my problem in the mail from 21.6.2007]
And this is exactly what I reported here on June 20th (codegen problem).
>
> at the c-server side in the method "axis2_svc_skel_<servicename>_invoke"
>
> i implemented the buissness-logic as following :
>
> if (axutil_strcmp(op_name, "foo") == 0)
> {
> ret_val2 = axis2_skel_<servicename>_foo(env);
> ret_node = axis2_DeviceInfo_serialize(ret_val2, env, NULL, 0);
> return ret_node;
> }
And this is probably what Milinda suggested...
>
> with a breakpoint in the invoke method i found out, that the server
> didn't reach this method, when calling with the java-client, but the
> java-client sends the SOAPAction="foo".
>
> otherwise when i set up a request with SOAPUI 1.7.1 and
> send the methodname "foo" as first element in the soap-body,
> the c-server response is fine (the breakpoint was reached).
>
> so what do i have to do, to set the SOAPAction accurately ?
I am sorry - I do not know... I am still thinking about the exception
thing from yesterday.... (and can't find a solution...)
Flori
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-c-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-c-user-help@ws.apache.org