Re: Failed in creating DLL

2008-03-26 Thread Senaka Fernando
Hi Sunil,

So are you using IIS? If so, this is an issue, that has already been
reported, a patch has also been submitted. I will have this fixed by
Friday evening.

Regards,
Senaka

On Wed, 2008-03-26 at 21:59 -0500, Sunil Pandit wrote:
The service is C implementation . It does uses one dll other than the axis
> and runtime DLL. That DLL is in path.
>
> Thanks
> Sunil Pandit
> R&D , CSC FSG Austin
> (512)2755792
>
> Computer Sciences Corporation
> Registered Office: 2100 East Grand Avenue, El Segundo California 90245, USA
> Registered in USA No: C-489-59
>
> 
>
> This is a PRIVATE message. If you are not the intended recipient, please
> delete without copying and kindly advise us by e-mail of the mistake in
> delivery.
> NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
> any order or other contract unless pursuant to explicit written agreement
> or government initiative expressly permitting the use of e-mail for such
> purpose.
> 
>
>
>
>
>
>  "Senaka Fernando"
>  <[EMAIL PROTECTED]>
> To
>  03/26/2008 05:30  "Apache AXIS C User List"
>  PM
> cc
>
>  Please respond to Subject
>   "Apache AXIS C   Re: Failed in creating DLL
> User List"
>  <[EMAIL PROTECTED]
> pache.org>
>
>
>
>
>
>
>
> Hi Sunil,
>
> Few clarifications,
>
> 1. Is your service using any C++ code?
> 2. Is your service dependant on any other library other than the runtime?
>
> Regards,
> Senaka
>
> > Nandika ,
> >
> > The service in both the environments using the same DLL's and also the
> > same
> > runtime DLL . The only difference is Windows server vs . Windows XP.
> >
> > Regards
> > Sunil Pandit
> > R&D , CSC FSG Austin
> > (512)2755792
> >
> > Computer Sciences Corporation
> > Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
> > USA
> > Registered in USA No: C-489-59
> >
> >
> 
>
> >
> > This is a PRIVATE message. If you are not the intended recipient, please
> > delete without copying and kindly advise us by e-mail of the mistake in
> > delivery.
> > NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
> > any order or other contract unless pursuant to explicit written agreement
> > or government initiative expressly permitting the use of e-mail for such
> > purpose.
> >
> 
>
> >
> >
> >
> >
> >
> >  "Nandika
> >  Jayawardana"
> >  <[EMAIL PROTECTED]
> To
> >  om>   "Apache AXIS C User List"
> >
> >  03/26/2008 11:19
> cc
> >  AM
> >
> Subject
> >Re: Failed in creating DLL
> >  Please respond to
> >   "Apache AXIS C
> > User List"
> >  <[EMAIL PROTECTED]
> > pache.org>
> >
> >
> >
> >
> >
> >
> > Hi,
> > What I meant was C runtime library MSVCRT.DLL. Try using the
> > depends.exe ( Dependency walker tool ) to find out the dependencies of
> > your service. This may help you figure out the problem.
> >
> > Regards
> > Nandika
> >
> >
> > On Wed, Mar 26, 2008 at 9:23 PM, Sunil Pandit <[EMAIL PROTECTED]> wrote:
> >> Nandika ,
> >>
> >> The server where it is running is
> >>
> >> OS Name Microsoft(R) Windows(R) Server 2003, Standard Edition
> >> Version 5.2.3790 Service Pack 1 Build 3790
> >>
> >> And the machine where it is failing is
> >>
> >> OS Name Microsoft Windows XP Professional
> >> Version 5.1.2600 Service Pack 2 Build 2600
> >>
> >> Could you please elaborate which libraries I should be looking for .?
> >> The
> >> dependency of axis are same .
> >>
> >> Thanks
> >> Sunil Pandit
> >> R&D , CSC FSG Austin
> >> (512)2755792
> >>
> >> Computer Sciences Corporation
> >> Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
> > USA
> >> Registered in US

Re: Header parameters being ignored

2008-03-26 Thread Dimuthu Gamage
Hi Sérgio,
Currently WSDL2C doesn't support picking headers from the wsdl. The
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 fix
this for the client side within this week

Thanks
Dimuthu

On Thu, Mar 27, 2008 at 2:30 AM, Sérgio Gomes <[EMAIL PROTECTED]> 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 header
>  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_email_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 the class
>  names, but it has already been confirmed and will be fixed, according
>  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 should
>  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érgio
>
>  -
>  To unsubscribe, e-mail: [EMAIL PROTECTED]
>  For additional commands, e-mail: [EMAIL PROTECTED]
>
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: I don't understand what is going on with memory control in a client.

2008-03-26 Thread Samisa Abeysinghe

Try with echo sample.

Samisa...

Alex Bolgarov wrote:

Well, I _am_ using the sample provided by the Axis project - the
client I'm using is the exact code sample from the "Axis2/C Manual" -
the manual that is available here:
http://ws.apache.org/axis2/c/docs/axis2c_manual.html. The sample
client code I'm using is, without any changes, from this page:
http://ws.apache.org/axis2/c/docs/hello/client/hello.c.html (I'm
attaching the file that I was compiling, just in case there are some
differences I could not see, but I've just copied the code from the
web browser window and pasted it into XEmacs editor and saved as a
'my_client.c' file)

And, as you can see in the sample client code, this sample _releases_
a payload memory that is passes to the send_receive operation:

if (payload)
{
axiom_node_free_tree(payload, env);
payload = NULL;
}

Is the sample wrong? I will take a look at the samples from the source
distribution, may be they don't release the payload?

Anyway, when the service _is_ running and the client receives the
response, why attempt to release the payload tree by the client (which
this sample client does) does not cause the crash? If the Axis took
ownership for the payload tree, it should have deleted it already, and
attempt to delete if in the client code would have caused a crash.
Something is not right here...


Thank you,

alex.



On Wed, Mar 26, 2008 at 10:30 AM, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
  

In short, the AXIOM that you create and pass to service client
 send_receive operation would be taken control of by service client. So,
 you do not have to free that, even though you will be creating it. Same
 with the returned response payload. You can use it, but you do not have
 ownership of that. All that you have to delete is the service client
 instance.

 If you can send in your client code, we can have a look.

 Also, the samples follow the convention that I explained above, so if
 you follow the samples, you can solve the problems.

 Samisa...



 Alex Bolgarov wrote:
 > Hi,
 >
 > I don't understand what's going on inside the Axis2/C client. My test
 > client crashes. I looked at the Axis source code and did some
 > debugging (mostly, I've added a lots of AXIS2_LOG_DEBUG(...) to the
 > Axis source code and recompiled - I have a fast enough computer, and
 > this way you can receive repeating results, something that hard to get
 > with a debugger), and run a client code with valgrind.
 >
 > I think there might be some mix up in the the
 > axis2_op_client_add_msg_ctx() function, which causes the memory that
 > is not supposed to be freed by the Axis library (specifically, the
 > payload data that is allocated by the client application before it
 > calls the axis2_svc_client_send_receive()). Then, when the
 > axis2_svc_client_send_receive() returns to my client code, the client
 > tries to free the payload it allocated, at which moment the client
 > crashes - either silently, or with the glibc reporting "double free or
 > corruption".
 >
 > Now that I've got your attention, here are the details (sorry, this is
 > a long message):
 >
 > First, I'm using Ubuntu 7.10, and I downloaded and compiled sources of
 > Axis2/C 1.3.0.
 >
 > I compiled a SOAP service - virtually unchanged code of the example
 > from the user guide, but the service looks to be OK, there is a
 > problem with the client.
 >
 > I compiled a SOAP client - absolutely unchanged code of the client
 > from the user guide
 > (http://ws.apache.org/axis2/c/docs/hello/client/hello.c.html).
 >
 > When I'm starting the Axis server (for example, stand-alone
 > axis2_http_server application), the client works OK, it sends
 > something to the service and receives some response. No crashes.
 >
 > But if I start the client application _without_ starting a server
 > (that is, I expect some kind of timeout or some error about inability
 > to conect to the server), the client application crashes.
 >
 > Here is what I found:
 >
 > The axis2_svc_client_send_receive() calls
 > axis2_svc_client_send_receive_with_op_qname() function that implements
 > the sending and receiving of the SOAP messages. If there is an error
 > in the low-level sending/receiving of the messages (which really
 > happens in my case, because I did not start the SOAP server for this
 > test), the res_msg_ctx variable will be NULL, and in the conditional
 > statement in the lines 864-872 of the file axis2_svc_client.c is
 > executed the 'else' alternative, which calls the
 > axis2_op_client_add_msg_ctx() function, passing the res_msg_ctx value
 > (which is NULL) to it.
 >
 > In the axis2_op_client_add_msg_ctx() function, right before the 'if'
 > statement in the lines 274-296 (file axis_op_client.c):
 >
 > if (out_msg_ctx && !mc)
 >
 >  value of the out_msg_ctx is not NULL, and value of the mc is not NULL
 > (I checked this using the debug logging), so the body of this
 > statement is executed. In this body, right before the

Re: Failed in creating DLL

2008-03-26 Thread Sunil Pandit
The service is C implementation . It does uses one dll other than the axis
and runtime DLL. That DLL is in path.

Thanks
Sunil Pandit
R&D , CSC FSG Austin
(512)2755792

Computer Sciences Corporation
Registered Office: 2100 East Grand Avenue, El Segundo California 90245, USA
Registered in USA No: C-489-59



This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
any order or other contract unless pursuant to explicit written agreement
or government initiative expressly permitting the use of e-mail for such
purpose.





   
 "Senaka Fernando" 
 <[EMAIL PROTECTED]> 
To 
 03/26/2008 05:30  "Apache AXIS C User List"   
 PM 
cc 
   
 Please respond to Subject 
  "Apache AXIS C   Re: Failed in creating DLL  
User List" 
 <[EMAIL PROTECTED] 
pache.org> 
   
   
   




Hi Sunil,

Few clarifications,

1. Is your service using any C++ code?
2. Is your service dependant on any other library other than the runtime?

Regards,
Senaka

> Nandika ,
>
> The service in both the environments using the same DLL's and also the
> same
> runtime DLL . The only difference is Windows server vs . Windows XP.
>
> Regards
> Sunil Pandit
> R&D , CSC FSG Austin
> (512)2755792
>
> Computer Sciences Corporation
> Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
> USA
> Registered in USA No: C-489-59
>
>


>
> This is a PRIVATE message. If you are not the intended recipient, please
> delete without copying and kindly advise us by e-mail of the mistake in
> delivery.
> NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
> any order or other contract unless pursuant to explicit written agreement
> or government initiative expressly permitting the use of e-mail for such
> purpose.
>


>
>
>
>
>
>  "Nandika
>  Jayawardana"
>  <[EMAIL PROTECTED]
To
>  om>   "Apache AXIS C User List"
>
>  03/26/2008 11:19
cc
>  AM
>
Subject
>Re: Failed in creating DLL
>  Please respond to
>   "Apache AXIS C
> User List"
>  <[EMAIL PROTECTED]
> pache.org>
>
>
>
>
>
>
> Hi,
> What I meant was C runtime library MSVCRT.DLL. Try using the
> depends.exe ( Dependency walker tool ) to find out the dependencies of
> your service. This may help you figure out the problem.
>
> Regards
> Nandika
>
>
> On Wed, Mar 26, 2008 at 9:23 PM, Sunil Pandit <[EMAIL PROTECTED]> wrote:
>> Nandika ,
>>
>> The server where it is running is
>>
>> OS Name Microsoft(R) Windows(R) Server 2003, Standard Edition
>> Version 5.2.3790 Service Pack 1 Build 3790
>>
>> And the machine where it is failing is
>>
>> OS Name Microsoft Windows XP Professional
>> Version 5.1.2600 Service Pack 2 Build 2600
>>
>> Could you please elaborate which libraries I should be looking for .?
>> The
>> dependency of axis are same .
>>
>> Thanks
>> Sunil Pandit
>> R&D , CSC FSG Austin
>> (512)2755792
>>
>> 

Re: Failed in creating DLL

2008-03-26 Thread Senaka Fernando
Hi Sunil,

Few clarifications,

1. Is your service using any C++ code?
2. Is your service dependant on any other library other than the runtime?

Regards,
Senaka

> Nandika ,
>
> The service in both the environments using the same DLL's and also the
> same
> runtime DLL . The only difference is Windows server vs . Windows XP.
>
> Regards
> Sunil Pandit
> R&D , CSC FSG Austin
> (512)2755792
>
> Computer Sciences Corporation
> Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
> USA
> Registered in USA No: C-489-59
>
> 
>
> This is a PRIVATE message. If you are not the intended recipient, please
> delete without copying and kindly advise us by e-mail of the mistake in
> delivery.
> NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
> any order or other contract unless pursuant to explicit written agreement
> or government initiative expressly permitting the use of e-mail for such
> purpose.
> 
>
>
>
>
>
>  "Nandika
>  Jayawardana"
>  <[EMAIL PROTECTED]  To
>  om>   "Apache AXIS C User List"
>
>  03/26/2008 11:19   cc
>  AM
>Subject
>Re: Failed in creating DLL
>  Please respond to
>   "Apache AXIS C
> User List"
>  <[EMAIL PROTECTED]
> pache.org>
>
>
>
>
>
>
> Hi,
> What I meant was C runtime library MSVCRT.DLL. Try using the
> depends.exe ( Dependency walker tool ) to find out the dependencies of
> your service. This may help you figure out the problem.
>
> Regards
> Nandika
>
>
> On Wed, Mar 26, 2008 at 9:23 PM, Sunil Pandit <[EMAIL PROTECTED]> wrote:
>> Nandika ,
>>
>> The server where it is running is
>>
>> OS Name Microsoft(R) Windows(R) Server 2003, Standard Edition
>> Version 5.2.3790 Service Pack 1 Build 3790
>>
>> And the machine where it is failing is
>>
>> OS Name Microsoft Windows XP Professional
>> Version 5.1.2600 Service Pack 2 Build 2600
>>
>> Could you please elaborate which libraries I should be looking for .?
>> The
>> dependency of axis are same .
>>
>> Thanks
>> Sunil Pandit
>> R&D , CSC FSG Austin
>> (512)2755792
>>
>> Computer Sciences Corporation
>> Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
> USA
>> Registered in USA No: C-489-59
>>
>>
> 
>
>>
>> This is a PRIVATE message. If you are not the intended recipient, please
>> delete without copying and kindly advise us by e-mail of the mistake in
>> delivery.
>> NOTE: Regardless of content, this e-mail shall not operate to bind CSC
>> to
>> any order or other contract unless pursuant to explicit written
>> agreement
>> or government initiative expressly permitting the use of e-mail for such
>> purpose.
>>
> 
>
>>
>>
>>
>>
>>
>> "Nandika
>> Jayawardana"
>> <[EMAIL PROTECTED]
>> To
>> om>   "Apache AXIS C User List"
>>   
>> 03/26/2008 10:12
>> cc
>> AM
>>   Subject
>>   Re: Failed in creating DLL
>> Please respond to
>>
>>  "Apache AXIS C
>>User List"
>> <[EMAIL PROTECTED]
>>pache.org>
>>
>>
>>
>>
>>
>>
>> Hi,
>> This may be due to a difference in C runtime environments in the
>> machine you tested and the machine you have deployed the service. Also
>> check whether there is a difference in dependency library versions.
>>
>> Regards
>> Nandika
>>
>> On Wed, Mar 26, 2008 at 7:56 PM, Sunil Pandit <[EMAIL PROTECTED]> wrote:
>> > Manjula
>> >
>> > Thanks for your quick response. The dll has been tested on one of our
>> > server . We deployed this dll in customer environment and we are
> getting
>> > this error . So I am not sure if it is compiler settings. Yes the
> serv

Re: Failed in creating DLL

2008-03-26 Thread Sunil Pandit
Hello again,

I ran depends walker on my service dll. All the direct dependencies (Axis
related) are same on both the environment . The run time msvcrt.dll is also
same.

The only difference is windows xp vs. windows server.

Any  clue in resolving this issue ?

Any help is greatly appreciated.

Thanks
Sunil Pandit
R&D , CSC FSG Austin
(512)2755792

Computer Sciences Corporation
Registered Office: 2100 East Grand Avenue, El Segundo California 90245, USA
Registered in USA No: C-489-59



This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
any order or other contract unless pursuant to explicit written agreement
or government initiative expressly permitting the use of e-mail for such
purpose.





   
 "Nandika  
 Jayawardana"  
 <[EMAIL PROTECTED]  To 
 om>   "Apache AXIS C User List"   

 03/26/2008 11:19   cc 
 AM
   Subject 
   Re: Failed in creating DLL  
 Please respond to 
  "Apache AXIS C   
User List" 
 <[EMAIL PROTECTED] 
pache.org> 
   
   




Hi,
What I meant was C runtime library MSVCRT.DLL. Try using the
depends.exe ( Dependency walker tool ) to find out the dependencies of
your service. This may help you figure out the problem.

Regards
Nandika


On Wed, Mar 26, 2008 at 9:23 PM, Sunil Pandit <[EMAIL PROTECTED]> wrote:
> Nandika ,
>
> The server where it is running is
>
> OS Name Microsoft(R) Windows(R) Server 2003, Standard Edition
> Version 5.2.3790 Service Pack 1 Build 3790
>
> And the machine where it is failing is
>
> OS Name Microsoft Windows XP Professional
> Version 5.1.2600 Service Pack 2 Build 2600
>
> Could you please elaborate which libraries I should be looking for .? The
> dependency of axis are same .
>
> Thanks
> Sunil Pandit
> R&D , CSC FSG Austin
> (512)2755792
>
> Computer Sciences Corporation
> Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
USA
> Registered in USA No: C-489-59
>
>


>
> This is a PRIVATE message. If you are not the intended recipient, please
> delete without copying and kindly advise us by e-mail of the mistake in
> delivery.
> NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
> any order or other contract unless pursuant to explicit written agreement
> or government initiative expressly permitting the use of e-mail for such
> purpose.
>


>
>
>
>
>
> "Nandika
> Jayawardana"
> <[EMAIL PROTECTED]  To
> om>   "Apache AXIS C User List"
>   
> 03/26/2008 10:12   cc
> AM
>   Subject
>   Re: Failed in creating DLL
> Please respond to
>
>  "Apache AXIS C
>User List"
> <[EMAIL PROTECTED]
>pache.org>
>
>
>
>
>
>
> Hi,
> This may be due to a difference in C

Header parameters being ignored

2008-03-26 Thread Sérgio Gomes
Hello again,

When sending my SOAP messages, I noticed that the headers were always
empty, even though the WSDL2C tool generated support for the header
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_email_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 the class
names, but it has already been confirmed and will be fixed, according
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 should
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érgio

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Client data stream null or socket error

2008-03-26 Thread Sérgio Gomes
Hey everyone,

Just an update: I managed to fix it by tracing the problem in the
library source code. Looks like the parameter has to be defined in the
root level (axisconfig node) rather than in the transportReceiver /
transportSender.

Hope this helps anyone with the same issue.

Cheers,
Sérgio

---
On Thu, Mar 20, 2008 at 2:12 PM, Sérgio Gomes <[EMAIL PROTECTED]> wrote:
> Hi Dinesh,
>
>  I think SERVER_CERT is set correctly, I added it to both the
>  transportSender and transportReceiver (you can check the axis2.xml
>  file I sent). Is there anywhere else where I should set these?
>
>  Cheers,
>  Sérgio
>
>  ---
>
>
> On Thu, Mar 20, 2008 at 1:24 PM, Dinesh Premalal <[EMAIL PROTECTED]> wrote:
>  > Hi Sérgio,
>  >
>  >
>  >  "Sérgio Gomes" <[EMAIL PROTECTED]> writes:
>  >  > [Thu Mar 20 12:49:38 2008] [info]  [ssl client] CA certificate not
>  >  > specified
>  >
>  >  I think this is the problem. Axis2/C engine didn't pick up your
>  >  certificate file.
>  >
>  >
>  >  > It's complaining that the data stream is null or there is a socket
>  >  > error, so I guess it's having problems connecting to the endpoint, or
>  >  > am I wrong?
>  >
>  >  Could you please check whether you have set SERVER_CERT correctly?
>  >
>  >  thanks,
>  >  Dinesh
>  >  --
>  >  http://nethu.org
>  >
>  >  -
>  >  To unsubscribe, e-mail: [EMAIL PROTECTED]
>  >  For additional commands, e-mail: [EMAIL PROTECTED]
>  >
>  >
>

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Failed in creating DLL

2008-03-26 Thread Sunil Pandit
Nandika ,

The service in both the environments using the same DLL's and also the same
runtime DLL . The only difference is Windows server vs . Windows XP.

Regards
Sunil Pandit
R&D , CSC FSG Austin
(512)2755792

Computer Sciences Corporation
Registered Office: 2100 East Grand Avenue, El Segundo California 90245, USA
Registered in USA No: C-489-59



This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
any order or other contract unless pursuant to explicit written agreement
or government initiative expressly permitting the use of e-mail for such
purpose.





   
 "Nandika  
 Jayawardana"  
 <[EMAIL PROTECTED]  To 
 om>   "Apache AXIS C User List"   

 03/26/2008 11:19   cc 
 AM
   Subject 
   Re: Failed in creating DLL  
 Please respond to 
  "Apache AXIS C   
User List" 
 <[EMAIL PROTECTED] 
pache.org> 
   
   




Hi,
What I meant was C runtime library MSVCRT.DLL. Try using the
depends.exe ( Dependency walker tool ) to find out the dependencies of
your service. This may help you figure out the problem.

Regards
Nandika


On Wed, Mar 26, 2008 at 9:23 PM, Sunil Pandit <[EMAIL PROTECTED]> wrote:
> Nandika ,
>
> The server where it is running is
>
> OS Name Microsoft(R) Windows(R) Server 2003, Standard Edition
> Version 5.2.3790 Service Pack 1 Build 3790
>
> And the machine where it is failing is
>
> OS Name Microsoft Windows XP Professional
> Version 5.1.2600 Service Pack 2 Build 2600
>
> Could you please elaborate which libraries I should be looking for .? The
> dependency of axis are same .
>
> Thanks
> Sunil Pandit
> R&D , CSC FSG Austin
> (512)2755792
>
> Computer Sciences Corporation
> Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
USA
> Registered in USA No: C-489-59
>
>


>
> This is a PRIVATE message. If you are not the intended recipient, please
> delete without copying and kindly advise us by e-mail of the mistake in
> delivery.
> NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
> any order or other contract unless pursuant to explicit written agreement
> or government initiative expressly permitting the use of e-mail for such
> purpose.
>


>
>
>
>
>
> "Nandika
> Jayawardana"
> <[EMAIL PROTECTED]  To
> om>   "Apache AXIS C User List"
>   
> 03/26/2008 10:12   cc
> AM
>   Subject
>   Re: Failed in creating DLL
> Please respond to
>
>  "Apache AXIS C
>User List"
> <[EMAIL PROTECTED]
>pache.org>
>
>
>
>
>
>
> Hi,
> This may be due to a difference in C runtime environments in the
> machine you tested and the machine you have deployed the service. Also
> check whether there is a difference

Re: Failed in creating DLL

2008-03-26 Thread Nandika Jayawardana
Hi,
What I meant was C runtime library MSVCRT.DLL. Try using the
depends.exe ( Dependency walker tool ) to find out the dependencies of
your service. This may help you figure out the problem.

Regards
Nandika


On Wed, Mar 26, 2008 at 9:23 PM, Sunil Pandit <[EMAIL PROTECTED]> wrote:
> Nandika ,
>
> The server where it is running is
>
> OS Name Microsoft(R) Windows(R) Server 2003, Standard Edition
> Version 5.2.3790 Service Pack 1 Build 3790
>
> And the machine where it is failing is
>
> OS Name Microsoft Windows XP Professional
> Version 5.1.2600 Service Pack 2 Build 2600
>
> Could you please elaborate which libraries I should be looking for .? The
> dependency of axis are same .
>
> Thanks
> Sunil Pandit
> R&D , CSC FSG Austin
> (512)2755792
>
> Computer Sciences Corporation
> Registered Office: 2100 East Grand Avenue, El Segundo California 90245, USA
> Registered in USA No: C-489-59
>
> 
>
> This is a PRIVATE message. If you are not the intended recipient, please
> delete without copying and kindly advise us by e-mail of the mistake in
> delivery.
> NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
> any order or other contract unless pursuant to explicit written agreement
> or government initiative expressly permitting the use of e-mail for such
> purpose.
> 
>
>
>
>
>
> "Nandika
> Jayawardana"
> <[EMAIL PROTECTED]  To
> om>   "Apache AXIS C User List"
>   
> 03/26/2008 10:12   cc
> AM
>   Subject
>   Re: Failed in creating DLL
> Please respond to
>
>  "Apache AXIS C
>User List"
> <[EMAIL PROTECTED]
>pache.org>
>
>
>
>
>
>
> Hi,
> This may be due to a difference in C runtime environments in the
> machine you tested and the machine you have deployed the service. Also
> check whether there is a difference in dependency library versions.
>
> Regards
> Nandika
>
> On Wed, Mar 26, 2008 at 7:56 PM, Sunil Pandit <[EMAIL PROTECTED]> wrote:
> > Manjula
> >
> > Thanks for your quick response. The dll has been tested on one of our
> > server . We deployed this dll in customer environment and we are getting
> > this error . So I am not sure if it is compiler settings. Yes the service
> > name is correct.
> >
> > Regards
> > Sunil Pandit
> > R&D , CSC FSG Austin
> > (512)2755792
> >
> > Computer Sciences Corporation
> > Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
> USA
> > Registered in USA No: C-489-59
> >
> >
> 
>
> >
> > This is a PRIVATE message. If you are not the intended recipient, please
> > delete without copying and kindly advise us by e-mail of the mistake in
> > delivery.
> > NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
> > any order or other contract unless pursuant to explicit written agreement
> > or government initiative expressly permitting the use of e-mail for such
> > purpose.
> >
> 
>
> >
> >
> >
> >
> >
> > Manjula Peiris
> > <[EMAIL PROTECTED]
> > >  To
> >   Apache AXIS C User List
> > 03/26/2008 01:43  
> > AM cc
> >
> >   Subject
> > Please respond to Re: Failed in creating DLL
> >  "Apache AXIS C
> >User List"
> > <[EMAIL PROTECTED]
> >pache.org>
> >
> >
> >
> >
> >
> >
> >
> > Hi Sunil,
> >
> > How did you create the service ? What are the compiler and linker
> > commands? And is the service dll name in the services.xml is correct?
> >
> > Thanks,
> > -Manjula
> >
> >
> > On Tue, 2008-03-25 at 21:08 -0500, Sunil Pandit wrote:
> > > Hello Axis experts ,
> > >
>

Re: Failed in creating DLL

2008-03-26 Thread Sunil Pandit
Nandika ,

The server where it is running is

OS Name Microsoft(R) Windows(R) Server 2003, Standard Edition
Version 5.2.3790 Service Pack 1 Build 3790

And the machine where it is failing is

OS Name Microsoft Windows XP Professional
Version 5.1.2600 Service Pack 2 Build 2600

Could you please elaborate which libraries I should be looking for .? The
dependency of axis are same .

Thanks
Sunil Pandit
R&D , CSC FSG Austin
(512)2755792

Computer Sciences Corporation
Registered Office: 2100 East Grand Avenue, El Segundo California 90245, USA
Registered in USA No: C-489-59



This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
any order or other contract unless pursuant to explicit written agreement
or government initiative expressly permitting the use of e-mail for such
purpose.





   
 "Nandika  
 Jayawardana"  
 <[EMAIL PROTECTED]  To 
 om>   "Apache AXIS C User List"   

 03/26/2008 10:12   cc 
 AM
   Subject 
   Re: Failed in creating DLL  
 Please respond to 
  "Apache AXIS C   
User List" 
 <[EMAIL PROTECTED] 
pache.org> 
   
   




Hi,
This may be due to a difference in C runtime environments in the
machine you tested and the machine you have deployed the service. Also
check whether there is a difference in dependency library versions.

Regards
Nandika

On Wed, Mar 26, 2008 at 7:56 PM, Sunil Pandit <[EMAIL PROTECTED]> wrote:
> Manjula
>
> Thanks for your quick response. The dll has been tested on one of our
> server . We deployed this dll in customer environment and we are getting
> this error . So I am not sure if it is compiler settings. Yes the service
> name is correct.
>
> Regards
> Sunil Pandit
> R&D , CSC FSG Austin
> (512)2755792
>
> Computer Sciences Corporation
> Registered Office: 2100 East Grand Avenue, El Segundo California 90245,
USA
> Registered in USA No: C-489-59
>
>


>
> This is a PRIVATE message. If you are not the intended recipient, please
> delete without copying and kindly advise us by e-mail of the mistake in
> delivery.
> NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
> any order or other contract unless pursuant to explicit written agreement
> or government initiative expressly permitting the use of e-mail for such
> purpose.
>


>
>
>
>
>
> Manjula Peiris
> <[EMAIL PROTECTED]
> >  To
>   Apache AXIS C User List
> 03/26/2008 01:43  
> AM cc
>
>   Subject
> Please respond to Re: Failed in creating DLL
>  "Apache AXIS C
>User List"
> <[EMAIL PROTECTED]
>pache.org>
>
>
>
>
>
>
>
> Hi Sunil,
>
> How did you create the service ? What are the compiler and linker
> commands? And is the service dll name in the se

Re: I don't understand what is going on with memory control in a client.

2008-03-26 Thread Alex Bolgarov
Well, I _am_ using the sample provided by the Axis project - the
client I'm using is the exact code sample from the "Axis2/C Manual" -
the manual that is available here:
http://ws.apache.org/axis2/c/docs/axis2c_manual.html. The sample
client code I'm using is, without any changes, from this page:
http://ws.apache.org/axis2/c/docs/hello/client/hello.c.html (I'm
attaching the file that I was compiling, just in case there are some
differences I could not see, but I've just copied the code from the
web browser window and pasted it into XEmacs editor and saved as a
'my_client.c' file)

And, as you can see in the sample client code, this sample _releases_
a payload memory that is passes to the send_receive operation:

if (payload)
{
axiom_node_free_tree(payload, env);
payload = NULL;
}

Is the sample wrong? I will take a look at the samples from the source
distribution, may be they don't release the payload?

Anyway, when the service _is_ running and the client receives the
response, why attempt to release the payload tree by the client (which
this sample client does) does not cause the crash? If the Axis took
ownership for the payload tree, it should have deleted it already, and
attempt to delete if in the client code would have caused a crash.
Something is not right here...


Thank you,

alex.



On Wed, Mar 26, 2008 at 10:30 AM, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
> In short, the AXIOM that you create and pass to service client
>  send_receive operation would be taken control of by service client. So,
>  you do not have to free that, even though you will be creating it. Same
>  with the returned response payload. You can use it, but you do not have
>  ownership of that. All that you have to delete is the service client
>  instance.
>
>  If you can send in your client code, we can have a look.
>
>  Also, the samples follow the convention that I explained above, so if
>  you follow the samples, you can solve the problems.
>
>  Samisa...
>
>
>
>  Alex Bolgarov wrote:
>  > Hi,
>  >
>  > I don't understand what's going on inside the Axis2/C client. My test
>  > client crashes. I looked at the Axis source code and did some
>  > debugging (mostly, I've added a lots of AXIS2_LOG_DEBUG(...) to the
>  > Axis source code and recompiled - I have a fast enough computer, and
>  > this way you can receive repeating results, something that hard to get
>  > with a debugger), and run a client code with valgrind.
>  >
>  > I think there might be some mix up in the the
>  > axis2_op_client_add_msg_ctx() function, which causes the memory that
>  > is not supposed to be freed by the Axis library (specifically, the
>  > payload data that is allocated by the client application before it
>  > calls the axis2_svc_client_send_receive()). Then, when the
>  > axis2_svc_client_send_receive() returns to my client code, the client
>  > tries to free the payload it allocated, at which moment the client
>  > crashes - either silently, or with the glibc reporting "double free or
>  > corruption".
>  >
>  > Now that I've got your attention, here are the details (sorry, this is
>  > a long message):
>  >
>  > First, I'm using Ubuntu 7.10, and I downloaded and compiled sources of
>  > Axis2/C 1.3.0.
>  >
>  > I compiled a SOAP service - virtually unchanged code of the example
>  > from the user guide, but the service looks to be OK, there is a
>  > problem with the client.
>  >
>  > I compiled a SOAP client - absolutely unchanged code of the client
>  > from the user guide
>  > (http://ws.apache.org/axis2/c/docs/hello/client/hello.c.html).
>  >
>  > When I'm starting the Axis server (for example, stand-alone
>  > axis2_http_server application), the client works OK, it sends
>  > something to the service and receives some response. No crashes.
>  >
>  > But if I start the client application _without_ starting a server
>  > (that is, I expect some kind of timeout or some error about inability
>  > to conect to the server), the client application crashes.
>  >
>  > Here is what I found:
>  >
>  > The axis2_svc_client_send_receive() calls
>  > axis2_svc_client_send_receive_with_op_qname() function that implements
>  > the sending and receiving of the SOAP messages. If there is an error
>  > in the low-level sending/receiving of the messages (which really
>  > happens in my case, because I did not start the SOAP server for this
>  > test), the res_msg_ctx variable will be NULL, and in the conditional
>  > statement in the lines 864-872 of the file axis2_svc_client.c is
>  > executed the 'else' alternative, which calls the
>  > axis2_op_client_add_msg_ctx() function, passing the res_msg_ctx value
>  > (which is NULL) to it.
>  >
>  > In the axis2_op_client_add_msg_ctx() function, right before the 'if'
>  > statement in the lines 274-296 (file axis_op_client.c):
>  >
>  > if (out_msg_ctx && !mc)
>  >
>  >  value of the out_msg_ctx is not NULL, and value of the mc is not NULL
>  > (I checked this using the deb

Re: Failed in creating DLL

2008-03-26 Thread Nandika Jayawardana
Hi,
This may be due to a difference in C runtime environments in the
machine you tested and the machine you have deployed the service. Also
check whether there is a difference in dependency library versions.

Regards
Nandika

On Wed, Mar 26, 2008 at 7:56 PM, Sunil Pandit <[EMAIL PROTECTED]> wrote:
> Manjula
>
> Thanks for your quick response. The dll has been tested on one of our
> server . We deployed this dll in customer environment and we are getting
> this error . So I am not sure if it is compiler settings. Yes the service
> name is correct.
>
> Regards
> Sunil Pandit
> R&D , CSC FSG Austin
> (512)2755792
>
> Computer Sciences Corporation
> Registered Office: 2100 East Grand Avenue, El Segundo California 90245, USA
> Registered in USA No: C-489-59
>
> 
>
> This is a PRIVATE message. If you are not the intended recipient, please
> delete without copying and kindly advise us by e-mail of the mistake in
> delivery.
> NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
> any order or other contract unless pursuant to explicit written agreement
> or government initiative expressly permitting the use of e-mail for such
> purpose.
> 
>
>
>
>
>
> Manjula Peiris
> <[EMAIL PROTECTED]
> >  To
>   Apache AXIS C User List
> 03/26/2008 01:43  
> AM cc
>
>   Subject
> Please respond to Re: Failed in creating DLL
>  "Apache AXIS C
>User List"
> <[EMAIL PROTECTED]
>pache.org>
>
>
>
>
>
>
>
> Hi Sunil,
>
> How did you create the service ? What are the compiler and linker
> commands? And is the service dll name in the services.xml is correct?
>
> Thanks,
> -Manjula
>
>
> On Tue, 2008-03-25 at 21:08 -0500, Sunil Pandit wrote:
> > Hello Axis experts ,
> >
> > I have developed a web service which has been working fine in our test
> > environment .  We have tested this service in both axis web server
> > environment as well as in HTTP server environment.
> >
> > However when we deployed same service in our  customer's environment ,
> we
> > are facing "Failed in creating DLL"  error .
> >
> > The service can be seen among the available services . I would appreciate
> > if someone shed some light on this problem. Here is the log.
> >
> > [Tue Mar 25 15:26:26 2008] [info]  Starting HTTP server thread
> > [Tue Mar 25 15:26:34 2008] [debug]
> > ..\..\src\core\transport\http\common\http_worker.c(153) Client HTTP
> version
> > HTTP/1.0
> > [Tue Mar 25 15:26:34 2008] [debug]
> ..\..\axiom\src\soap\soap_builder.c(843)
> > Identified soap version is soap11
> > [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\engine.c(648)
> > Start:axis2_engine_invoke_phases
> > [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\engine.c(660)
> > Invoking phase Transport
> > [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\phase.c(204)
> > Invoke the handler request_uri_based_dispatcher within the phase
> Transport
> > [Tue Mar 25 15:26:34 2008] [debug]
> > ..\..\src\core\engine\req_uri_disp.c(101) Checking for service using
> target
> > endpoint address : http://161.250.36.4:9090/axis2/services/VPMSService
> > [Tue Mar 25 15:26:34 2008] [debug]
> > ..\..\src\core\engine\req_uri_disp.c(122) Service found using target
> > endpoint address
> > [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\phase.c(204)
> > Invoke the handler AddressingInHandler within the phase Transport
> > [Tue Mar 25 15:26:34 2008] [info]  Starting addressing in handler
> .
> > [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\phase.c(204)
> > Invoke the handler addressing_based_dispatcher within the phase Transport
> > [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\engine.c(660)
> > Invoking phase PreDispatch
> > [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\engine.c(660)
> > Invoking phase Dispatch
> > [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\phase.c(204)
> > Invoke the handler soap_message_body_based_dispatcher within the phase
> > Dispatch
> > [Tue Mar 25 15:26:34 2008] [debug]
> > ..\..\src\core\engine\soap_body_disp.c(228) Checking for operation using
> > SOAP message body's first child's local name : execute
> > [Tue Mar 25 15:26:34 2008] [debug]
> > ..\..\src\core\engine\soap_body_disp.c(236) Operation found usin

Re: I don't understand what is going on with memory control in a client.

2008-03-26 Thread Samisa Abeysinghe
In short, the AXIOM that you create and pass to service client 
send_receive operation would be taken control of by service client. So, 
you do not have to free that, even though you will be creating it. Same 
with the returned response payload. You can use it, but you do not have 
ownership of that. All that you have to delete is the service client 
instance.


If you can send in your client code, we can have a look.

Also, the samples follow the convention that I explained above, so if 
you follow the samples, you can solve the problems.


Samisa...

Alex Bolgarov wrote:

Hi,

I don't understand what's going on inside the Axis2/C client. My test
client crashes. I looked at the Axis source code and did some
debugging (mostly, I've added a lots of AXIS2_LOG_DEBUG(...) to the
Axis source code and recompiled - I have a fast enough computer, and
this way you can receive repeating results, something that hard to get
with a debugger), and run a client code with valgrind.

I think there might be some mix up in the the
axis2_op_client_add_msg_ctx() function, which causes the memory that
is not supposed to be freed by the Axis library (specifically, the
payload data that is allocated by the client application before it
calls the axis2_svc_client_send_receive()). Then, when the
axis2_svc_client_send_receive() returns to my client code, the client
tries to free the payload it allocated, at which moment the client
crashes - either silently, or with the glibc reporting "double free or
corruption".

Now that I've got your attention, here are the details (sorry, this is
a long message):

First, I'm using Ubuntu 7.10, and I downloaded and compiled sources of
Axis2/C 1.3.0.

I compiled a SOAP service - virtually unchanged code of the example
from the user guide, but the service looks to be OK, there is a
problem with the client.

I compiled a SOAP client - absolutely unchanged code of the client
from the user guide
(http://ws.apache.org/axis2/c/docs/hello/client/hello.c.html).

When I'm starting the Axis server (for example, stand-alone
axis2_http_server application), the client works OK, it sends
something to the service and receives some response. No crashes.

But if I start the client application _without_ starting a server
(that is, I expect some kind of timeout or some error about inability
to conect to the server), the client application crashes.

Here is what I found:

The axis2_svc_client_send_receive() calls
axis2_svc_client_send_receive_with_op_qname() function that implements
the sending and receiving of the SOAP messages. If there is an error
in the low-level sending/receiving of the messages (which really
happens in my case, because I did not start the SOAP server for this
test), the res_msg_ctx variable will be NULL, and in the conditional
statement in the lines 864-872 of the file axis2_svc_client.c is
executed the 'else' alternative, which calls the
axis2_op_client_add_msg_ctx() function, passing the res_msg_ctx value
(which is NULL) to it.

In the axis2_op_client_add_msg_ctx() function, right before the 'if'
statement in the lines 274-296 (file axis_op_client.c):

if (out_msg_ctx && !mc)

 value of the out_msg_ctx is not NULL, and value of the mc is not NULL
(I checked this using the debug logging), so the body of this
statement is executed. In this body, right before the 'if' statement
on the line 290:

if (axutil_strcmp(dump_value, AXIS2_VALUE_TRUE))

the value of the dump_value is NULL (again checked by the debug
logging), and the axutil_strcmp() returns -1 (which is interpreted as
a 'true' boolean value), and thus the body of the statement, including
the call (line 292)

axis2_msg_ctx_free(out_msg_ctx, env);

is executed.

The out_msg_ctx here points to the same message context object that
was created in the axis2_svc_client_send_receive_with_op_qname()
function, before sending the SOAP request - I saw using the debug
logging that the pointer value returned by the axis2_msg_ctx_create()
call in the axis2_svc_client_send_receive_with_op_qname() (line 834)
is the same as the value of the pointer out_msg_ctx here.

But this message context object contains a soap_envelop object that,
in turn, contains the payload object (tree of the object model nodes)
that my client application allocated before calling the
axis2_svc_client_send_receive() (specifically, this soap_envelop is
filled with the payload in the call
axis2_svc_client_fill_soap_envelope() (line 838, function
axis2_svc_client_send_receive_with_op_qname(), file
axis2_svc_client.c). So, returning back to the the
axis2_op_client_add_msg_ctx() function, this payload object (tree)
gets freed here. Then, later, when my client application tries to free
the payload object after the axis2_svc_client_send_receive() returns
to it, the application crashes, because this memory is already freed.


So, finally, my questions:

What strategy the client application that calls
axis2_svc_client_send_receive() should use regarding
allocating/freeing memory?

Re: Failed in creating DLL

2008-03-26 Thread Sunil Pandit
Manjula

Thanks for your quick response. The dll has been tested on one of our
server . We deployed this dll in customer environment and we are getting
this error . So I am not sure if it is compiler settings. Yes the service
name is correct.

Regards
Sunil Pandit
R&D , CSC FSG Austin
(512)2755792

Computer Sciences Corporation
Registered Office: 2100 East Grand Avenue, El Segundo California 90245, USA
Registered in USA No: C-489-59



This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery.
NOTE: Regardless of content, this e-mail shall not operate to bind CSC to
any order or other contract unless pursuant to explicit written agreement
or government initiative expressly permitting the use of e-mail for such
purpose.





   
 Manjula Peiris
 <[EMAIL PROTECTED] 
 >  To 
   Apache AXIS C User List 
 03/26/2008 01:43   
 AM cc 
   
   Subject 
 Please respond to Re: Failed in creating DLL  
  "Apache AXIS C   
User List" 
 <[EMAIL PROTECTED] 
pache.org> 
   
   




Hi Sunil,

How did you create the service ? What are the compiler and linker
commands? And is the service dll name in the services.xml is correct?

Thanks,
-Manjula


On Tue, 2008-03-25 at 21:08 -0500, Sunil Pandit wrote:
> Hello Axis experts ,
>
> I have developed a web service which has been working fine in our test
> environment .  We have tested this service in both axis web server
> environment as well as in HTTP server environment.
>
> However when we deployed same service in our  customer's environment ,
we
> are facing "Failed in creating DLL"  error .
>
> The service can be seen among the available services . I would appreciate
> if someone shed some light on this problem. Here is the log.
>
> [Tue Mar 25 15:26:26 2008] [info]  Starting HTTP server thread
> [Tue Mar 25 15:26:34 2008] [debug]
> ..\..\src\core\transport\http\common\http_worker.c(153) Client HTTP
version
> HTTP/1.0
> [Tue Mar 25 15:26:34 2008] [debug]
..\..\axiom\src\soap\soap_builder.c(843)
> Identified soap version is soap11
> [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\engine.c(648)
> Start:axis2_engine_invoke_phases
> [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\engine.c(660)
> Invoking phase Transport
> [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\phase.c(204)
> Invoke the handler request_uri_based_dispatcher within the phase
Transport
> [Tue Mar 25 15:26:34 2008] [debug]
> ..\..\src\core\engine\req_uri_disp.c(101) Checking for service using
target
> endpoint address : http://161.250.36.4:9090/axis2/services/VPMSService
> [Tue Mar 25 15:26:34 2008] [debug]
> ..\..\src\core\engine\req_uri_disp.c(122) Service found using target
> endpoint address
> [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\phase.c(204)
> Invoke the handler AddressingInHandler within the phase Transport
> [Tue Mar 25 15:26:34 2008] [info]  Starting addressing in handler
.
> [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\phase.c(204)
> Invoke the handler addressing_based_dispatcher within the phase Transport
> [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\engine.c(660)
> Invoking phase PreDispatch
> [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\engine.c(660)
> Invoking phase Dispatch
> [Tue Mar 25 15:26:34 2008] [debug] ..\..\src\core\engine\phase.c(204)
> Invoke the handler soap_message_body_based_dispatcher within the phase
> Dispatch
> [Tue Mar 25 15:26:34 2008] [debug]
> ..\..\src\core\engine\soap_body_disp.c(228) Checking for operation using
> SOAP message body's first child's 

I don't understand what is going on with memory control in a client.

2008-03-26 Thread Alex Bolgarov
Hi,

I don't understand what's going on inside the Axis2/C client. My test
client crashes. I looked at the Axis source code and did some
debugging (mostly, I've added a lots of AXIS2_LOG_DEBUG(...) to the
Axis source code and recompiled - I have a fast enough computer, and
this way you can receive repeating results, something that hard to get
with a debugger), and run a client code with valgrind.

I think there might be some mix up in the the
axis2_op_client_add_msg_ctx() function, which causes the memory that
is not supposed to be freed by the Axis library (specifically, the
payload data that is allocated by the client application before it
calls the axis2_svc_client_send_receive()). Then, when the
axis2_svc_client_send_receive() returns to my client code, the client
tries to free the payload it allocated, at which moment the client
crashes - either silently, or with the glibc reporting "double free or
corruption".

Now that I've got your attention, here are the details (sorry, this is
a long message):

First, I'm using Ubuntu 7.10, and I downloaded and compiled sources of
Axis2/C 1.3.0.

I compiled a SOAP service - virtually unchanged code of the example
from the user guide, but the service looks to be OK, there is a
problem with the client.

I compiled a SOAP client - absolutely unchanged code of the client
from the user guide
(http://ws.apache.org/axis2/c/docs/hello/client/hello.c.html).

When I'm starting the Axis server (for example, stand-alone
axis2_http_server application), the client works OK, it sends
something to the service and receives some response. No crashes.

But if I start the client application _without_ starting a server
(that is, I expect some kind of timeout or some error about inability
to conect to the server), the client application crashes.

Here is what I found:

The axis2_svc_client_send_receive() calls
axis2_svc_client_send_receive_with_op_qname() function that implements
the sending and receiving of the SOAP messages. If there is an error
in the low-level sending/receiving of the messages (which really
happens in my case, because I did not start the SOAP server for this
test), the res_msg_ctx variable will be NULL, and in the conditional
statement in the lines 864-872 of the file axis2_svc_client.c is
executed the 'else' alternative, which calls the
axis2_op_client_add_msg_ctx() function, passing the res_msg_ctx value
(which is NULL) to it.

In the axis2_op_client_add_msg_ctx() function, right before the 'if'
statement in the lines 274-296 (file axis_op_client.c):

if (out_msg_ctx && !mc)

 value of the out_msg_ctx is not NULL, and value of the mc is not NULL
(I checked this using the debug logging), so the body of this
statement is executed. In this body, right before the 'if' statement
on the line 290:

if (axutil_strcmp(dump_value, AXIS2_VALUE_TRUE))

the value of the dump_value is NULL (again checked by the debug
logging), and the axutil_strcmp() returns -1 (which is interpreted as
a 'true' boolean value), and thus the body of the statement, including
the call (line 292)

axis2_msg_ctx_free(out_msg_ctx, env);

is executed.

The out_msg_ctx here points to the same message context object that
was created in the axis2_svc_client_send_receive_with_op_qname()
function, before sending the SOAP request - I saw using the debug
logging that the pointer value returned by the axis2_msg_ctx_create()
call in the axis2_svc_client_send_receive_with_op_qname() (line 834)
is the same as the value of the pointer out_msg_ctx here.

But this message context object contains a soap_envelop object that,
in turn, contains the payload object (tree of the object model nodes)
that my client application allocated before calling the
axis2_svc_client_send_receive() (specifically, this soap_envelop is
filled with the payload in the call
axis2_svc_client_fill_soap_envelope() (line 838, function
axis2_svc_client_send_receive_with_op_qname(), file
axis2_svc_client.c). So, returning back to the the
axis2_op_client_add_msg_ctx() function, this payload object (tree)
gets freed here. Then, later, when my client application tries to free
the payload object after the axis2_svc_client_send_receive() returns
to it, the application crashes, because this memory is already freed.


So, finally, my questions:

What strategy the client application that calls
axis2_svc_client_send_receive() should use regarding
allocating/freeing memory? From the current implementation of Axis2/C,
it looks like a) if the response was received successfully, the client
application should free the payload, but b) if there was a
communication error, the Axis library will free the payload itself. Is
this correct?

Is this a 'by design' feature of the Axis2/C or is this a bug and (in
theory) there should be more sane rules regarding memory control?
(And, is there somewhere published the memory management rules for the
Axis2/C?)


Second thing I've noticed when browsing the code of the
axis2_svc_client_send_receive_with_op_qname()

Regarding CGI application with axis2 c

2008-03-26 Thread Baxi, Rinilkumar (TCS)

Hi All,

I have my own http server running on my system. It is providing the CGI 
interface. How can I invoke an axis service using my http server?
Please let me know is axis2c supporting CGI applications or not?

Thanks in advance.

Regards,
Rinil