Re: Another memory leak in axis2/C - mod_axis2

2008-07-26 Thread Subra A Narayanan
i think u do. click on the "log in" link on the top right corner and then u
will see a link to "sign up"

On Sat, Jul 26, 2008 at 10:50 AM, Alex Bolgarov <[EMAIL PROTECTED]> wrote:

> On Sat, Jul 26, 2008 at 10:46 AM, Subra A Narayanan <[EMAIL PROTECTED]>
> wrote:
> > here you go => https://issues.apache.org/jira/browse/AXIS2C
>
> Do I need to have an account there, or what?
>
>
> >
> >
> >
> > On Sat, Jul 26, 2008 at 10:37 AM, Alex Bolgarov <[EMAIL PROTECTED]>
> wrote:
> >>
> >> On Fri, Jul 25, 2008 at 11:02 PM, Uthaiyashankar <[EMAIL PROTECTED]>
> wrote:
> >> > Hi Alex,
> >> >
> >> > Thank you for pointing out. Yes, it is a serious memory leak. Can you
> >> > create
> >> > a jira in [1]. We'll fix it ASAP.
> >>
> >> How do I create a jira there? I can't find any link or button for
> >> reporting issues...
> >>
> >>
> >> Thank you,
> >>
> >>alex.
> >>
> >> -
> >> 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: Another memory leak in axis2/C - mod_axis2

2008-07-26 Thread Subra A Narayanan
here you go => https://issues.apache.org/jira/browse/AXIS2C



On Sat, Jul 26, 2008 at 10:37 AM, Alex Bolgarov <[EMAIL PROTECTED]> wrote:

> On Fri, Jul 25, 2008 at 11:02 PM, Uthaiyashankar <[EMAIL PROTECTED]> wrote:
> > Hi Alex,
> >
> > Thank you for pointing out. Yes, it is a serious memory leak. Can you
> create
> > a jira in [1]. We'll fix it ASAP.
>
> How do I create a jira there? I can't find any link or button for
> reporting issues...
>
>
> Thank you,
>
>alex.
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Redirecting Web Services

2008-07-21 Thread Subra A Narayanan
Brian,

Basically this is what is happening here:

1. YourClient => Initial Request =>1st Server
2. 1st Server => 301 Response => YourClient
3. YouClient is supposed to interpret the 301 response and resend the
request to the 2nd Server. But since ur client is written in Axis2c which
doesn't support redirection, ur client doesn't know what to do with the
response and doesn't take any further action.


Your browser on the other hand, knows how to interpret the 301 response and
goes after the new location (2nd Server).


So the bottom line is, ur server is behaving correctly. Try writing a client
in some other language like c# or java and I am sure this issue will go
away.

Subra

On Mon, Jul 21, 2008 at 1:51 PM, Brian S Bates (bribates) <
[EMAIL PROTECTED]> wrote:

>  Hi,
>
> When I use TCPMon to listen in on what's going on, this is what I get when
> using an Axis2C client:
>
> In the top box of TCPMon:
> GET /dp/go?param1=val1¶m2=val2¶m3=val3 HTTP/1.1
> User-Agent: Axis2C/1.4.0
> Host: 127.0.0.1:8080
>
> In the bottom box of TCPMon:
> HTTP/1.1 301 Moved Permanently
> Date: Mon, 21 Jul 2008 17:42:49 GMT
> Server: Apache/2.2.9 (Win32) Axis2C/1.4.0
> Location:
> http://127.0.0.1:8080/axis2/restprinter/go?param1=val1¶m2=val2¶m3=val3
> Content-Length: 294
> Content-Type: text/html; charset=iso-8859-1
>
> 
>
>   
>  301 Moved Permanently
>   
>   
>  Moved Permanently
>  The document has moved
> http://127.0.0.1:8080/axis2/restprinter/go?param1=val1¶m2=val2¶m3=val3";>herehttp://127.0.0.1:8080/axis2/restprinter/go?param1=val1¶m2=val2¶m3=val3%22%3Ehere%3C/a>
> >.
>  
>   
>
> On the other hand, when I use the browser (which works):
>
> In the top box of TCPMon:
> GET /axis2/restprinter/go/vala/valb?param3=valc HTTP/1.1
> Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg,
> application/vnd.ms-excel, application/vnd.ms-powerpoint, application/msword,
> application/x-shockwave-flash, application/x-silverlight, */*
> Accept-Language: en-us
> Accept-Encoding: gzip, deflate
> User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET
> CLR 1.1.4322; .NET CLR 2.0.50727)
> Host: 127.0.0.1:8080
> Connection: Keep-Alive
>
> In the bottom box of TCPMon:
> HTTP/1.1 200 OK
> Date: Mon, 21 Jul 2008 17:49:11 GMT
> Server: Apache/2.2.9 (Win32) Axis2C/1.4.0
> Content-Length: 26
> Keep-Alive: timeout=5, max=100
> Connection: Keep-Alive
> Content-Type: text/xml
>
> hello
>
> If there is anything else I can provide that you think would help, please
> feel free to let me know.
> Thanks,
> Brian
>
>  --
> *From:* Supun Kamburugamuva [mailto:[EMAIL PROTECTED]
> *Sent:* Thursday, July 17, 2008 1:47 AM
> *To:* Apache AXIS C User List
> *Subject:* Re: Redirecting Web Services
>
>  Hi brian,
>
> Can you please send us the redirected message for the Axis2/C client. It
> seems that their is something wrong in the XML. You can capture the message
> using a tool like tcpmon http://ws.apache.org/commons/tcpmon/.
>
> Supun..
>
> On Wed, Jul 16, 2008 at 7:58 PM, Brian S Bates (bribates) <
> [EMAIL PROTECTED]> wrote:
>
>>  Hi,
>>
>> I am working on a project using REST with Axis2C, and have encountered a
>> problem.  I would like to take the URI of the REST request and redirect it
>> somewhere else.
>>
>> For example, if the user enters:
>> http://server:port/loc1/service?param1=value1, I want this to be directed
>> to http://server:port/newlocation/service?param1=value1
>>
>> Currently, I am using the mod_axis2.dll module with Apache 2.2.9.  In my
>> Apache httpd.conf file, I have added the following lines (at the end):
>>
>> # Redirect requests to the axis2 directory
>> RewriteEngine on
>> RewriteRule ^/dp(.*) /axis2/restprinter$1 [R=permanent]
>>
>> # Axis2 C Configuration
>> LoadModule axis2_module modules/mod_axis2.dll
>> Axis2RepoPath C:/axis2c
>> Axis2LogFile  logs/axis2.log
>> Axis2LogLevel error
>> Axis2ServiceURLPrefix /axis2
>> Axis2MaxLogFileSize 100
>> 
>> SetHandler axis2_module
>> 
>>
>> ...Basically, rerouting anything with a URI that begins with /dp to
>> /axis2/restprinter (the first two lines).
>>
>> Using this configuration in a web browser works.  That is to say, the
>> redirection happens and a valid XML response is returned from my service.
>> However, using an Axis2C client fails.  Looking over the log file for the
>> client, it seems that the redirection is not happening?  Here is an excerpt:
>>
>> [Tue Jul 15 16:05:10 2008] [info]  Starting addressing out handler
>> [Tue Jul 15 16:05:10 2008] [debug]
>> ..\..\src\modules\mod_addr\addr_out_handler.c(133) No action present. Stop
>> processing addressing
>> [Tue Jul 15 16:05:10 2008] [debug]
>> ..\..\src\core\transport\http\sender\http_transport_sender.c(246) ctx_epr:
>> http://localhost:80/dp/go
>> [Tue Jul 15 16:05:10 2008] [debug]
>> ..\..\src\core\transport\http\sender\http_transport_sender.c(768) using
>> axis2 native http sender.
>> [Tue J

Re: rampart libs being copied incorrectly

2008-06-06 Thread Subra A Narayanan
Here you go => https://issues.apache.org/jira/browse/RAMPARTC-110

On Fri, Jun 6, 2008 at 12:02 AM, Uthaiyashankar <[EMAIL PROTECTED]> wrote:

> Hi Subra,
>
> see my comments
>
>
> Subra A Narayanan wrote:
>
>> Hey guys,
>>
>> I downloaded axis2c 1.4 and rampart 1.2 and built them. when I did an ls
>> -l of the axis2/c lib folder, i saw this
>>
>> bash-3.00$ ls -l axis2c/lib/libmod_rampart.*
>> -rwxr-xr-x  1 subra user1551 Jun  4 18:34 /nfs/home/subra/axis2c/lib/
>> libmod_rampart.la <http://libmod_rampart.la>
>> -rwxr-xr-x  1 subra user 6485794 Jun  4 18:34
>> /nfs/home/subra/axis2c/lib/libmod_rampart.so
>> -rwxr-xr-x  1 subra user 6485794 Jun  4 18:34
>> /nfs/home/subra/axis2c/lib/libmod_rampart.so.0
>> -rwxr-xr-x  1 subra user 6485794 Jun  4 18:34
>> /nfs/home/subra/axis2c/lib/libmod_rampart.so.0.0.0
>>
>> as you can see the symbolic links are missing here. 'libmod_rampart.so'
>> and 'libmod_rampart.so.0' are not linked to 'libmod_rampart.so.0.0.0'
>>
>
> This is a bug. Can you raise a jira? We should have symbolic links in lib
> folder...
>
>
>> but in the axis2c/modules/rampart folder, they are linked correctly. My
>> question is:
>>
>> 1. why are these libraries even present in the axis2c/lib folder. as far
>> as i remember, this was not happening in earlier versions of rampart.
>>
>
> Say if you are writing a service or client which uses Rampart's
> functionality. Then you need to link to mod_rampart.so. Either you can
> include $AXIS2C_HOME/modules/rampart in your lib path, but we figured most
> of the users are making the mistake of not adding this to the lib path.
> Because of this, we decided to install it in lib as well. But the files
> installed to lib should be symbolic links.
>
>  2. will they cause any problem/conflict?
>>
>
> No, it will not. Since both libraries are same, you will not get any
> conflict. When you are replacing mod_rampart.so manually, you have to
> replace it in both places.
>
> Regards,
> Shankar.
>
>>
>> Subra
>>
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Incorrect SoapFault format

2008-06-05 Thread Subra A Narayanan
Hello folks,

Rampart v1.2 is not generating soap faults correctly. The response below is
for a soap 1.1 message as captured by tcpmon. As you can see the 
node does not belong here.  is part of soap1.2 fault not soap1.1
fault.

http://schemas.xmlsoap.org/soap/envelope/";>
   
   
  
 
http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd
">
   wsse:InvalidSecurity
soapenv:Sender
 
 Signature Verification failed.
 
http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd
">ds:Signature
 
  
   


I have already created a JIRA for this =>
https://issues.apache.org/jira/browse/RAMPARTC-109


Thanks,
Subra


rampart libs being copied incorrectly

2008-06-05 Thread Subra A Narayanan
Hey guys,

I downloaded axis2c 1.4 and rampart 1.2 and built them. when I did an ls -l
of the axis2/c lib folder, i saw this

bash-3.00$ ls -l axis2c/lib/libmod_rampart.*
-rwxr-xr-x  1 subra user1551 Jun  4 18:34 /nfs/home/subra/axis2c/lib/
libmod_rampart.la
-rwxr-xr-x  1 subra user 6485794 Jun  4 18:34
/nfs/home/subra/axis2c/lib/libmod_rampart.so
-rwxr-xr-x  1 subra user 6485794 Jun  4 18:34
/nfs/home/subra/axis2c/lib/libmod_rampart.so.0
-rwxr-xr-x  1 subra user 6485794 Jun  4 18:34
/nfs/home/subra/axis2c/lib/libmod_rampart.so.0.0.0

as you can see the symbolic links are missing here. 'libmod_rampart.so' and
'libmod_rampart.so.0' are not linked to 'libmod_rampart.so.0.0.0'

but in the axis2c/modules/rampart folder, they are linked correctly. My
question is:

1. why are these libraries even present in the axis2c/lib folder. as far as
i remember, this was not happening in earlier versions of rampart.
2. will they cause any problem/conflict?

Subra


Re: How to compile Axis2c v1.4 with libxml2

2008-06-04 Thread Subra A Narayanan
Never mindi found it. its --enable-libxml2



On Wed, Jun 4, 2008 at 6:03 PM, Subra A Narayanan <[EMAIL PROTECTED]>
wrote:

> Hello guys,
>
> whats the configure option to compile v1.4 with libxml2 rather than
> gunthila?
>
> Subra
>


How to compile Axis2c v1.4 with libxml2

2008-06-04 Thread Subra A Narayanan
Hello guys,

whats the configure option to compile v1.4 with libxml2 rather than
gunthila?

Subra


Re: Reload mod_axis2

2008-05-30 Thread Subra A Narayanan
Thanks guys. I think the graceful restart option of apache is a good
solution for my problem.

On Fri, May 30, 2008 at 12:46 AM, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:

> Manjula Peiris wrote:
>
>> On Thu, 2008-05-29 at 15:12 -0400, Subra A Narayanan wrote:
>>
>>
>>> Hello all,
>>>
>>> I was wondering if there was a way to reload the apache axis2 module
>>> (so that it picks up config file changes like loglevel) without having
>>> to restart apache? The reason I ask this is I have other modules
>>> loaded in to apache and I want those modules to continue serving
>>> incoming requests when axis2 module is unloaded and reloaded.
>>>
>>>
>>
>> HTTPD has an option call grceful restart. I think you can achieve this
>> using that. See [1] for more details.
>>
>> [1] http://httpd.apache.org/docs/trunk/stopping.html
>>
>>
>
> But that still reloads all modules. It is a restart, except that it is
> graceful, meaning the request already being served will be completed, but
> the new requests will have to be dropped during the restart anyway.
>
> Samisa...
>
>
>>
>>
>>> Thanks!
>>>
>>> Subra
>>>
>>>
>>
>>
>> -
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>  
>>
>>
>> No virus found in this incoming message.
>> Checked by AVG. Version: 8.0.100 / Virus Database: 269.24.4/1473 - Release
>> Date: 5/29/2008 7:53 PM
>>
>>
>
>
> --
> Samisa Abeysinghe Director, Engineering; WSO2 Inc.
>
> http://www.wso2.com/ - "The Open Source SOA Company"
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Reload mod_axis2

2008-05-29 Thread Subra A Narayanan
Hello all,

I was wondering if there was a way to reload the apache axis2 module (so
that it picks up config file changes like loglevel) without having to
restart apache? The reason I ask this is I have other modules loaded in to
apache and I want those modules to continue serving incoming requests when
axis2 module is unloaded and reloaded.

Thanks!

Subra


Module conflict

2008-03-05 Thread Subra A Narayanan
Hello folks,

I am running in to another problem and was wondering if I could get some
help from you guys.

Another developer in my team had to add the following lines to httpd config
file. These lines are in a separate .conf file which is placed in the
/etc/httpd/conf.d/ directory and gets included in the main httpd.conf file.

DocumentRoot /srv/www/html/WebUI/public/

Options ExecCGI FollowSymLinks
AddHandler cgi-script .cgi
AllowOverride all
Order allow,deny
Allow from all


We realized that once this is added, we are unable to access our axis2 soap
webservices. We are not even able to bring up the page that lists all the
services and the operations. Looks like that the axis2 httpd module isn't
loading properly.

I did some research and I think it might have something to do with the per
server config and per directory config structures in the axis2 apache
module. Do we have to merge the directory config structures? I am kind of
new to writing apache modules so pls excuse my ignorance if I am wrong. I
will continue to investigate this issue as one of my own apache module is
also not working because of this.

In the meantime, if you guys have any idea please let me know.


Thanks,
Subra


Re: Axis2/C 1.2 breaks my webservice

2008-03-04 Thread Subra A Narayanan
Hi Senaka,

I suggest you check out from a branch and try running ./build.sh so that
> the configure scripts will be regenerated to support your CFLAGS. If this
> also fails, may be it is the "-static-libgcc -shared" combination that
> gives trouble.
>

I have downloaded ver 1.3 and would like to try my code with this version.
but before I begin I just wanted to make sure that I am doing evrything
correctly.

What do you mean when you ask me to checkout from a branch? Do you want me
to checkout just the build.sh file? isn't the build.sh file from axis2 1.1good?


Subra


Re: Axis2/C 1.2 breaks my webservice

2008-02-28 Thread Subra A Narayanan
>
>
> >You mean 1.1?
> Sorry for the confusion. Yes I meant Axis2 1.1
>
> >This is a thread issues as per your description. Hence I wonder if gdb
> >trace would lead to the exact problem, but it will lead to some clues as
> >to where it is hanging etc.
>
> >The following information would help:
> >   1. What are the CFLAGS and LDFLAGS you used when compiling the
> >service? In other words what are the compiler options and -l (linker)
> >options? Have you linked your external library to the service so in
> >compiling? Is the external library on LD_LIBRARY_PATH or in a locatable
> >path?

Here are my CFLAGS and LD_FLAGS value. Here 'myclient' is the external
library I have been telling you about.
CFLAGS = -fPIC -static-libgcc -shared -z initfirst
LD_FLAGS = -L /deps/axis2c/lib -L /mylib/ -l axutil -l axis2_engine -l dl -l
pthread -l myclient

Yes the library is in a locatable path. It works just fine with Axis2 1.1.
It gives me problem only with Axis2 1.2

Also I make couple of different calls to myclient library. Looks like only
when I call a function that uses multiple threads does my code hand.


>
> >   2. What CFLAGS and LDFLAGS you used when compiling 1.1 and 1.2
> >source trees

I used the build.sh file that came with the distribution for compiling axis.
Since there was no build.sh file in the axis1.2 source tar, I copied the one
from axis1.1


>
> >   3. Are you trying to run 1.1 and 1.2 with same httpd versions or
> >different httpd versions? If different, have those httpd instances been
> >compiled using different configure options?
>
I am running both axis1.1 and 1.2 on the same version of httpd. i have a
vmware image that i use for my testing. so the run env is exactly the same.




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


Re: Axis2/C 1.2 breaks my webservice

2008-02-27 Thread Subra A Narayanan
Hello folks,

Here are my findings:

A little more background first. The external library that my webservice
calls is a multithreaded library and uses semaphores for inter-thread
communication.  When I was in the process of debugging this problem, I
started httpd with the -X option (to limit httpd to a single process). When
I did this my webservice started working just fine. I stopped httpd and
started it normally and again my service hung up a particular call to my
external library.

Again the same code works just fine with Axis1.2

My question to you guys is:

-> Has something changed between Axis1.1 and Axis1.2 that would cause this
behavior?
-> Is this information enough or do you still want gdb trace information?

Thanks for all the help.

Subra

On Tue, Feb 26, 2008 at 10:44 PM, Dumindu Pallewela <[EMAIL PROTECTED]>
wrote:

> On Wed, Feb 27, 2008 at 5:50 AM, Subra A Narayanan <[EMAIL PROTECTED]>
> wrote:
>
> > I am running some other tests to see if I can get any further. I will
> report
> > my findings soon. In the meantime, if you guys can think of ways to
> track
> > down the problem, please let me know.
> >
>
> If you can provide a gdb trace, it would help to figure out where
> exactly the things go wrong.
>
> -Dumindu.
>
> --
> Dumindu Pallewela
> http://blog.dumindu.com
> GPG ID: 0x9E131672
>
> WSO2 | "Oxygenating the Web Service Platform" | http://wso2.com
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Axis2/C 1.2 breaks my webservice

2008-02-26 Thread Subra A Narayanan
Hello folks,

I also recompiled my code against Axis2 1.2 before trying to run. Even then
I am having trouble running it. Its not like the webservice code doesn't
comeup at all. I can see the request coming in, the input params being
processed and then it hangs when trying to call an external library.

I am running some other tests to see if I can get any further. I will report
my findings soon. In the meantime, if you guys can think of ways to track
down the problem, please let me know.

Subra

On Tue, Feb 26, 2008 at 4:08 AM, Michael Sutter <[EMAIL PROTECTED]>
wrote:

> Hello Subra,
>
> I have done the same with version 1.1 and 1.2 and it works without
> problems.
> But I compiled everything with the new version.
>
> Regards Michael
>
> Subra A Narayanan wrote:
> > Hello folks,
> >
> > I ran in to a curious problem and was wondering if anyone else has
> > seen it too. My webservice code works just fine with Axis2/C 1.1 . But
> > when I checked out version1.2 source code from here =>
> > http://svn.apache.org/repos/asf/webservices/axis2/tags/c/1.2.0-rc2-4/
> > my service stops working. I make a call to an external library(.so
> > file) from my webservice code and I see that my code hangs when I call
> > this external library.
> >
> > The same code works just fine with Axis2 ver 1.1. Any idea as to what
> > might be wrong?
> >
> > Thanks,
> > Subra
> >
> >
> > Subra
>


Axis2/C 1.2 breaks my webservice

2008-02-25 Thread Subra A Narayanan
Hello folks,

I ran in to a curious problem and was wondering if anyone else has seen it
too. My webservice code works just fine with Axis2/C 1.1 . But when I
checked out version1.2 source code from here =>
http://svn.apache.org/repos/asf/webservices/axis2/tags/c/1.2.0-rc2-4/ my
service stops working. I make a call to an external library(.so file) from
my webservice code and I see that my code hangs when I call this external
library.

The same code works just fine with Axis2 ver 1.1. Any idea as to what might
be wrong?

Thanks,
Subra


Subra


Re: how to autogen a wsdl

2008-01-15 Thread Subra A Narayanan
Axis2C doesn't support autogen of wsdl currently. I dont know if the Axis2C
team has any plans of supporting it in the future.

Subra

On Jan 15, 2008 2:08 PM, Brian McQueen <[EMAIL PROTECTED]> wrote:

> My co-worker's services support an autogen wsdl by doing something
> like this:  "http://hostname/something?wsdl";.  I'm sure its in axis2c
> too, but how do I get it going?  I don't see it in the manual or the
> quick start.  I do see some references to it in axis2_svc_client.h -
> something about dynamic invocation.  Any pointers for this?
>
> Brian McQueen
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: webservice and wsdl

2008-01-15 Thread Subra A Narayanan
Hey Mehdi,

As far as I know Axis2C doesn't generate the wsdl automatically for you. I
ended up coding my wsdl by hand.

Subra

On Jan 15, 2008 2:37 PM, Mehdi Ait Oufkir <[EMAIL PROTECTED]> wrote:

> Hi,
>
> I can't find any documentation about axis2/c automatically providing a
> wsdl based on a service. I know axis2/java provides that with the
> "?wsdl" parameter.
>
> I'd like to know if the c version has something similar or a work
> around...
>
> Thanks,
> Mehdi
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: [AXIS2C] Need IIS 6 instructions on how to set up Axis2/C

2008-01-03 Thread Subra A Narayanan
Is this what you are looking for:

http://ws.apache.org/axis2/c/docs/installationguide.html#win



On Jan 3, 2008 1:28 PM, Dave Meier <[EMAIL PROTECTED]> wrote:

>
> Hello,
>
> I'm just now getting back to Axis2/C as I am planning to use it with my
> product if it works well.
>
> Are there instructions on how to set it up in IIS6?  The resolution of
> AXIS2C-546 says "multiple filter initialization with IIS6"
> is what it takes to make it work, but I'm not sure what that means.  Are
> there documented steps on how to set this up?
>
> Thank you,
>
> -Dave Meier.
>
>
>
>
> -Original Message-
> From: Dinesh Premalal (JIRA) [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, April 03, 2007 10:53 PM
> To: [EMAIL PROTECTED]
> Subject: [jira] Resolved: (AXIS2C-546) IIS filter module needs to be
> made to work with IIS 6
>
>
> [
> https://issues.apache.org/jira/browse/AXIS2C-546?page=com.atlassian.jira
> .plugin.system.issuetabpanels:all-tabpanel ]
>
> Dinesh Premalal resolved AXIS2C-546.
> 
>
>Resolution: Fixed
>
> > IIS filter module needs to be made to work with IIS 6
> > -
> >
> > Key: AXIS2C-546
> > URL: https://issues.apache.org/jira/browse/AXIS2C-546
> > Project: Axis2-C
> >  Issue Type: Bug
> >  Components: platforms/windows
> >Affects Versions: Current (Nightly)
> > Environment: Windows with IIS 6
> >Reporter: Dave Meier
> > Assigned To: Dinesh Premalal
> >Priority: Critical
> >
> > IIS filter works with IIS 5, but will not work with IIS 6.
> > Excerpt of email from Supun:
> > "No, It won't work. The reason is that with IIS 6 Worker Process
> Isolationa mode (the default) there is no guarantee that filters are
> going to be single instansiated. But in the current implementation I
> assume that filters are single instansiated. Still I couldn't setup a
> Windows Server 2003 machine for developing the module on IIS 6. As soon
> as I setup a machine I will look in to this issue. Please create a Jira
> on this issue."
>
> --
> This message is automatically generated by JIRA.
> -
> You can reply to this email to add a comment to the issue online.
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
> **
> This email and any files transmitted with it are confidential and
> intended solely for the use of the individual or entity to whom they are
> addressed. Any unauthorized review, use, disclosure or distribution is
> prohibited. If you are not the intended recipient, please contact the
> sender by reply e-mail and destroy all copies of the original message.
> **
>
>
> -
> 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]
>
>


Rampart question

2007-12-06 Thread Subra A Narayanan
Hello folks,

1. How is role based authorization handled in Rampart? The Username and
password (basic or digest) just provide a way to authenticate the user, but
not authorize.

2. Is there anyway in Rampart/Axis2C to pass down the username from the
UsernameToken to the webservice code (after the username and password have
been authenticated) so that the webservice can then use the username to
determine if a user is authorized to access a particular resource or not.

Thanks for the help!

Subra


Re: HTTP Authentication (Basic and Digest)

2007-12-04 Thread Subra A Narayanan
One clarification

When we talk about support for Basic/Digest HTTP Authentication in Axis2/C,
we are talking about only the client side right? There is no problem on the
server side since this is taken care by the apache httpd server, correct?

So if my service is written in axis2/c with Digest Authentication enabled in
apache, and if I use Microsoft .Net client, I should be fine, right?

Subra

On Dec 4, 2007 4:07 AM, Dumindu Pallewela <[EMAIL PROTECTED]> wrote:

> Hi Subra,
>
> > 1. Is there any plan for supporting HTTP Digest Authentication anytime
> soon
> > in Axis2/C?
>
> I don't see anyone working on this regard at the moment. As a
> workaround you may try using basic auth with SSL (However, depending
> on your requirements this may not be possible).
>
> > 2. Are these still issues with Basic Authentication in Axis2/C? If yes,
> will
> > they be fixed in release 1.2?
> > -> https://issues.apache.org/jira/browse/AXIS2C-716
> > -> https://issues.apache.org/jira/browse/AXIS2C-767
>
> Yes, these issues are still there. I'm hoping to fix them for the 1.2release.
>
> Regards,
> Dumindu.
>
> --
> Dumindu Pallewela
> http://blog.dumindu.com
> GPG ID: 0x9E131672
>
> WSO2 | "Oxygenating the Web Service Platform" | http://wso2.com
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: AXIS2/C and scope="soapsession"

2007-12-04 Thread Subra A Narayanan
Hey Josef,

You might want to take a look at this thread ->
http://marc.info/?l=axis-c-user&m=119214357328385&w=2

Hopefully it will answer most of ur questions.

Subra

On Dec 4, 2007 4:04 AM, Stadelmann Josef <[EMAIL PROTECTED]>
wrote:

> Thanks Dinesh
>
> but in this case please can you or sombody from the team tell me what is
>
>
> #define AXIS2_SCOPE "scope"
>
> /**
>  * Field APPLICATION_SCOPE
>  */
> #define AXIS2_APPLICATION_SCOPE "application"
>
> /**
>  * Field SESSION_SCOPE
>  */
> #define AXIS2_SESSION_SCOPE "session"
>
>
>
> in axis2_const.h used for?
>
>
>
>
> I get the impression that something is not yet finished but that there
> issomehow an intention to be there some times in the future. Therefor I
> would like to know "Will Axis2/C ever support sessions to the degree as
> sessions are supported in Axis2 Java?
>
> How will sessions be supported with Apache Webserver when linked into it
> mod_axis2?"
>
> Any explanation is very welcome to us at this stage in our development.
>
> I guess, we all know from learnings in Axis2 Java that session of the
> types as defined in Axis2 uisng sope={application, soapsession, ... etc. }
> are a "must have" a strong requirement.
>
> Now I just like to know what is the intention of the developers regarding
> the implementation of session logic in Axis2/C?
>
> Josef.Stadelmann@
> axa-winterthur.ch
>
>
>
> -Ursprüngliche Nachricht-
> Von: Dinesh Premalal [mailto:[EMAIL PROTECTED] Auftrag von Dinesh
> Premalal
> Gesendet: Samstag, 1. Dezember 2007 06:23
> An: axis-c-user@ws.apache.org
> Betreff: Re: AXIS2/C and scope="soapsession"
>
>
> "Stadelmann Josef" <[EMAIL PROTECTED]> writes:
>
> > Hi
> >
> > does someone know how user sessions are implemented for Axis2/C ?
> >
> > Do I have the possibility to setup the same scope(s) as with the Java
> version
> > of Axis2?
> >
> > If yes how is it done? which .C files or .H. files do I have to check in
> the
> > axis2/c code set?
> >
> > I need scope="soapsession" as defined for some axis2 java services in
> > service.xml, so
> > I need this now as well for services I am going to implement using
> Axis2/C
> > techniq.
> >
> > If scope="sopasession" is supported which release of axis2/c supports
> it?
> >
> > where can I read about that?
>
> AFAIK, there is no method to manipulate sessions in Axis2/C.
>
> thanks,
> Dinesh
>
> -
> 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]
>
>


HTTP Authentication (Basic and Digest)

2007-12-03 Thread Subra A Narayanan
Hello folks,

I have 2 questions that I hope someone can answer

1. Is there any plan for supporting HTTP Digest Authentication anytime soon
in Axis2/C?

2. Are these still issues with Basic Authentication in Axis2/C? If yes, will
they be fixed in release 1.2?
-> https://issues.apache.org/jira/browse/AXIS2C-716
-> https://issues.apache.org/jira/browse/AXIS2C-767



Thanks as usual!

Subra


Re: mod_axis2 could not be loaded

2007-11-30 Thread Subra A Narayanan
Did you build the axis2 apache module according to these instructions:

http://ws.apache.org/axis2/c/docs/axis2c_manual.html#mod_axis2

axis2_http_server will work without the module but to deploy axis2 under
apache, you would need the module.

Subra


On Nov 30, 2007 4:26 PM, Sunil Pandit <[EMAIL PROTECTED]> wrote:

> Hi ,
>
> I am trying to deploy AXIS2/C under Apche web server . I am using version
> 2.0.61 . I have followed all the steps described in document however I am
> getting following error .
>
> Cannot load C:/Apache206/Apache2/modules/mod_axis2.dll into server: The
> specified procedure could not be found.
>
> However axis2_http_server is working fin and I can excute the samples. So
> that ensures the AXIS2c setup .
>
> Do I need to build mod_axis2.dll for Apache 2.0.59 version  ?
>
> Any inputs / suggestions are sincerely appreciated.
>
> 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.
>
> 
>
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


session cookies

2007-11-29 Thread Subra A Narayanan
Hello folks,

I have a webservice that requires that should be accessible only by
authenticated users. right now, the way it works is, each and every request
has to be authenticated. i was wondering, if there is a way in axis2/c to
generate a session cookie or id which would be valid for a given period of
time. the webservice would set this cookie after the first request comes in
and is successfully authenticated but each subsequent request would just
pass this cookie and there will be no need for authenticating every incoming
request.

does this make sense? is it doable in axis2c?


Thanks as usual!
Subra


Re: Axis2/C Memory Leaks

2007-11-20 Thread Subra A Narayanan
So there are still some known memory leak issues in axis2/c? I have
been doing some testing to look for memory leaks and I do see that
memory is being lost. I am using apache and _not_ the simple axis
server.

do we know when axis 1.2 is scheduled to be released? we are getting
pretty close to our launch date, thats why I am concerned.

the memory leaks that you have found, are they significant?

ur input is much appreciated.

Subra




On Nov 19, 2007 9:30 PM,  <[EMAIL PROTECTED]> wrote:
> Hi Edward,
>
> I've recently being fixing memory leaks in Axis2/C (using libxml2 parser).
> As far as I know, all the samples that we have do free all the resources
> before they exit, when the latest fixes would be done in 1.2.0. I haven't
> tried any generated code by the WSDL2C tool however, to see whether they
> do the freeing properly.
>
> *** If you could take a look at how the "echo" sample [axis2/c/samples] is
> implemented in both client and server sides, it should help. ***
>
> Please note that there are some "still reachable blocks" when you valgrind
> and I'm not sure whether it is a valgrind issue with glibc, or whether it
> is a dangling pointer, but there are no definite losses or indirect losses
> at the moment. Somebody correct me if I have made a wrong conclusion.
>
> On the other hand, there are still quite a number of leaks when you use
> the Guththila parser, which we are looking forward to fix.
>
> If you believe that the code generated by the codegen tool, lacks the
> freeing of memory, as in the samples that are provided, please feel free
> to raise an issue at the JIRA, and propose a patch.
>
> N.B. I'm not sure whether all the patches that I proposed are reflected on
> the current svn. But, I'm pretty sure that they would be, with the Axis2/C
> 1.2.0 release.
>
>
> > Hi,
> >
> > I am designing some web service client code using the Axis2/C framework
> > (used WSDL2C to generate client stubs that call the framework).  I have
> > a separate executable C file (C file that a main()) that calls the stub.
> > When I ran valgrind initially on it, I saw many memory leaks from this;
> > 49 loss records to be exact.  However, after inserting axis2_stub_free
> > and axutil_env_free before my end return statement in my executable C
> > file, I noticed that the loss records decreased greatly to 5.  I noticed
> > that this freeing of the stub and env variables is not in the sample
> > client code.  Should the sample client code also demonstrate this
> > freeing, and is this freeing logical to do on the client side?  Also, I
> > did some initial tests on the server side and noticed many memory leaks
> > as well.  Should this client-side freeing be also implemented on my
> > server code, or is the server-side freeing done differently and how if
> > anyone can describe where to insert the freeing statements?
> >
> > Thanks,
> > Edward
> >
> > -
> > 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]
>
>

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



Re: [Axis2] SSL and certificate support

2007-11-19 Thread Subra A Narayanan
Hey Dumindu,

Just want to make sure I understand this correctly. So if I just want
to run my axis2 webserices in SSL mode, I dont need rampart. I can
just use apache for that, right? But when I was reading rampart
documentation, it talks about soap body encryption using SSL certs.
How is that different from using apache for SSL?

My second question is, lets assume I want to use client authentication
for my webservice. I have to set the following 2 variables in the
httpd.conf file

SSLVerifyClient require
SSLVerifyDepth 1

I understand that this will force the client to send a cert with every
request. But after receives the client cert, what does it do with it?
does it check against a list of certs thats allowed to access the
service? Is this feature built-in to axis2 or do we hv to implement it
ourselves?


Thanks,
Subra

Hi Greg,
>>  Sorry if this is in some documentation somewhere (I've tried and not
>> found if). A cursory glance at the rampart code shows a lot of
>> references to ssl and certificates. Some specific questions:
>>
>> Is SSL supported on server side? Client?

Yes, Axis2/C supports both ssl server authentication and client
authentication. Please refer to the axis2c manual [1].

I would suggest you use axis2 1.0.0 RC3 [2] or the latest svn head,
since ssl transport has been updated since 0.96 release. In this case
you will have to refer to the documentation from the trunk [3].

Note that ssl transport is not a feature of rampart, but of Axis2/C itself.

Regards,
Dumindu.

[1] http://ws.apache.org/axis2/c/docs/axis2c_manual.html#ssl_client
[2] http://people.apache.org/~samisa/release/1.0.0/RC3/
[3] http://svn.apache.org/viewvc/webservices/axis2/trunk/c/xdocs/docs/
 axis2c_manual.html?view=co#ssl_client

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



Re: [Axis] Re: sync up modules error handling with new error blocks specified.

2007-11-13 Thread Subra A Narayanan
Hello,

Could you guys please provide some more information about this.

Should we just do a svn update to get the new code?

A brief tutorial as to what should be done to use this user error
block would be good.

There is some sample code in this thread here =>
http://marc.info/?l=axis-c-user&m=119106211228220&w=2
which I am currently using in my webservice. What changes will I need
to make to make use of the new custom error functionality.

Thanks in advance.


Subra



On Nov 13, 2007 3:33 AM, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
> Apart form the modules, the users too have been given a space to add
> custom errors.
>
> Samisa...
>
> Dinesh Premalal wrote:
> > Hi,
> >
> >   We have defined separate error blocks for modules and user
> >   space (axis2c-761). Please sync up all modules with appropriate error
> >   blocks. Comments are always welcome.
> >
> > thanks,
> > Dinesh
> >
> >
> > -
> > 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]
>
>

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



Re: custom error message with c server

2007-11-12 Thread Subra A Narayanan
Michael,

If you are setting the soap fault correctly on your server side, your
java client when it receives the soap response back with the soap
fault in it, should automatically throw an exception. You can then
retrieve the exception using ex.message.

May be someone from the Axis2 team can correct me if I am wrong.

Subra

On Nov 12, 2007 4:05 AM, Michael Sutter <[EMAIL PROTECTED]> wrote:
> Hello Senaka,
>
> sorry but I don't understand what you mean. Did you said that the custom
> error message I produce in my service is written to the log file of the
> server? I think this is not so - in my log file there is nothing from my
> message and the log level is set to debug. Otherwise how should I access
> the log file of my server from the java client? Both are running on
> different hosts and so I think it is normally not possible to access the
> log file. Only if both hosts have a shared file system.
>
> The only thing I want is to get a custom error message from the service
> - like a exception thrown in Java. Maybe there exists better ways and
> anybody can tell me?
>
> Regards
> Michael
>
> [EMAIL PROTECTED] wrote:
> > Hi Michael,
> >
> > As far as I know, the error(s) that you set, gets written in the log file
> > that you specify when you instantiate your service. This file can be found
> > inside the deploy/logs folder. You can open this file in your java client.
> > Basically, you could do a pattern matching in Java and locate the message
> > appearing after the error tag. You can then process the message and do
> > what ever you want.
> >
> > This is one method that you could use and it is guaranteed to work. I do
> > not know whether there are any other methods that would solve your
> > problem, and therefore, this may not be the only method.
> >
> > Hope this helps.
> >
> > Regards,
> >
> > Senaka.
>
> >
> >
> >> Hello,
> >>
> >> I habe a problem with a c server and a Java client. I want to return
> >> custom error messages from the c service. So I implemented in my service
> >> as told in Jira AXIS2C-678
> >> (https://issues.apache.org/jira/browse/AXIS2C-678?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel)
> >> and it works fine. The problem is now how I can get the error message in
> >> a Java Client? I found no methods to call in the classes. Has anybody a
> >> solution?
> >>
> >> Kind regards
> >> Michael
> >>
> >> -
> >> 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: Urgent: Specifying scope in Axis2c

2007-11-06 Thread Subra A Narayanan
Hello Samisa,

Do you have any updates on this issue? Do you have an approximate time frame
when this issue would be fixed in the framework? Is this feature under
development?

This capability is very important for the application I am working on. If it
wont't be fixed in the framework anytime soon, I will have to come up with a
fix in my code.

Your help is much appreciated.

Subra

On 10/12/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > thanks samisa.
> >
> > where would i store such a flag? service group context like in the
> > add.c example from sg_math service?
> Nop, if you do that, I think you will get the same problem again.
> I think you may have to use a database to do that. Savan module, the
> WS-Eventing module, came across such a problem and used sqlite.
>
> Can someone please explain how it was done in Savan?
>
> In the mean time, the matter is discussed on dev list, and would have a
> solution for this.
>
> Thanks,
> Samisa...
> >
> > On 10/11/07, *Samisa Abeysinghe* <[EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>> wrote:
> >
> > Subra A Narayanan wrote:
> > > Hello everyone,
> > >
> > > I have run in to an issue which I can't seem to figure out. In
> > my init
> > > method in the service skeleton I call the initialization routine
> of
> > > one of the libraries that my web service uses. I notice in my logs
> > > that the library initialization function is being called 8
> > times. This
> > > corresponds to the number of apache processes that are running.
> > This is a problem yet to be solved in Axis2/C. See
> >
> http://damithakumarage.wordpress.com/2007/09/23/an-axis2-c-design-issue/.
> > This is a pending issue that needs to be fixed.
> > The workaround for the time being would be to use some persistent
> > storage to keep a flag and call the init routine based on the flag
> > value.
> >
> > Samisa...
> > >
> > > This is causing a lot of issues because I was under the impression
> > > that my web service init function is called only once when the
> first
> > > request comes in. My library sets up some resources which I want
> to
> > > share among all processes. Can this be done?
> > >
> > > In Axis2/Java there is a way to specify scope for the webservice
> > > (request, session, application) in the services.xml file? can
> > > something similar be done in Axis2/c? I took a look at the
> > axis2c code
> > > and saw that there is an enum called axis2_scope defined. Is it
> used
> > > for the same purpose as in Axis2/Java?
> > >
> > > Thanks for any help.
> > >
> > > Subra
> > >
> > >
> > >
> >
> >
> > --
> > Samisa Abeysinghe : WSO2 WSF/PHP
> > "
> >
> http://wso2.org/projects/wsf/php?WSO2 Web Services Framework%2FPHP - Open source PHP extention for providing and consuming Web services in PHP
> > <
> http://wso2.org/projects/wsf/php?WSO2 Web Services Framework%2FPHP - Open source PHP extention for providing and consuming Web services in PHP
> >"
> >
> >
> >
> -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>
> >
> >
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/PHP
> "
> http://wso2.org/projects/wsf/php?WSO2 Web Services Framework%2FPHP - Open source PHP extention for providing and consuming Web services in PHP
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: axis simple http server versus apache

2007-10-31 Thread Subra A Narayanan
Hey Michael,

I think the reason you are getting this error is because apache is not able
to locate and load one of you libraries. Try this:

copy all ur shared libraries in to the /usr/lib (or /usr/lib64 ) folder and
try ur test with apache again. If that solves ur problem, you may need to
modify ur ld.so.conf file to add the location of ur library files to tell
apache where to look for the library files that it needs.

Subra


On 10/31/07, Michael Sutter <[EMAIL PROTECTED]> wrote:
>
> Hello list,
>
> I have a problem with a service running in the apache webserver.
> When I run the service with the axis simple server everything works
> fine. But when I run it inside apache I always get:
>
> raw_xml_in_out_msg_recv.c(109) Impl object for service 'DAQStatus' not
> set in message receiver. 100 :: Failed in creating DLL
>
> When I understand the message right the service can't get the input
> correct. Am I right? Does anybody know why this could occur and why only
> in apache?
>
> The input is only a string - the output is a compley datatype containing
> 6 boolean and 6 int variables.
>
> Kind Regards
> Michael
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Axiom element memory deallocation

2007-10-30 Thread Subra A Narayanan
Hello folks,

In my webservice I do some processing and then call the following function
to prepare the response to be sent to the client

1. axiom_node_t * BuildResponse(const axutil_env_t *env, axis2_char_t
*fileName)
2. {
3.axiom_node_t *resp_om_node = NULL;
4.axiom_element_t* resp_om_ele = NULL;
5.axiom_node_t* fileName_om_node = NULL;
6.axiom_element_t* fileName_om_ele = NULL;
7.axiom_namespace_t *ns = NULL;

8.ns = axiom_namespace_create(env, NAMESPACE_URI, NAMESPACE_PREFIX);
9.resp_om_ele = axiom_element_create(env, NULL, "MyResponse", ns,
&resp_om_node);
10.  fileName_om_ele = axiom_element_create(env, resp_om_node, "MyID", ns,
&fileName_om_node);
11.  axiom_element_set_text(fileName_om_ele, env, fileName,
fileName_om_node);

12. return resp_om_node;
}

The node returned from the above function is returned as it is to the client
without any further modification.

My question is, since I am explicitly creating the resp_om_ele and
fileName_om_ele, I should be freeing them too, right? But where exactly do I
do that? Can I do that right after line 11? But then what happens to the
resp_om_node?

Or should I not be worrying about freeing the two elements?

Please advise.



Subra


Re: Memory Issues in Sample Server Code

2007-10-30 Thread Subra A Narayanan
Dinesh/Samisa,

I am using Apache 2.0.59 with axis 1.1. Do you think upgrading to
apache 2.2might solve some of these issues? Are you guys aware of any
memory
management issues with apache 2.0?

Samisa, a quick question for you. In you email, you mentioned that calling
free is not going to free up memory from the apache pool. Does that mean
that I dont have to call AXIS2_FREE for any memory that I explicitly
allocated using AXIS2_MALLOC? Then why do we need the free function? Please
clarify.

Thank you,
Subra



On 10/30/07, Dinesh Premalal <[EMAIL PROTECTED]> wrote:
>
> Hi David,
>
> David Klassen <[EMAIL PROTECTED]> writes:
>
> > I am running my tests with v1.1 but on Windows with apache 2.2.x (latest
> > September release). I tried various things. I did see one diff where the
> free
> > statement was either lost during the correction of an indentation or
> purposely
> > removed, however the free statement replacement did not solve the issue.
> Seeing
> > how other JIRA issues seemed to be closed concerning similar reports, I
> kind of
> > assumed that people were not focusing on server performance in this
> project,
> > but embedded C client access.
> I just compiled Axis2/C 1.1 and run server with Apache2.2.6
> version.Tried to send 100,000 requests. I monitored memory
> consumptions of the httpd. For me it never reach 400MB resident or
> virtual memory. I also able to see the memory resetting thing, when it
> comes to something around 250MB memory get reset.I attached my process
> list and client response.
>
>
> thanks,
> Dinesh
>
>
> echo.xml
> --
>  xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope";> xmlns:wsa="http://www.w3.org/2005/08/addressing";>
> http://localhost:9089/axis2/services/echo
> http://ws.apache.org/axis2/c/samples/echoString
> 0c69d0c6-86b6-1dc1-275c-001125b4e529 xmlns:ns1="http://ws.apache.org/axis2/services/echo";>Hello
> World!
>
>
> client command
> --
> ab -T "application/soap+xml; charset=UTF-8" -p echo.xml -n 10 -c 4
> http://localhost:9090/axis2/services/echo
>
>
>
> client response
> ---
> Completed 9 requests
> Finished 10 requests
>
>
> Server Software:Apache/2.2.6
> Server Hostname:localhost
> Server Port:9090
>
> Document Path:  /axis2/services/echo
> Document Length:672 bytes
>
> Concurrency Level:  4
> Time taken for tests:   276.629621 seconds
> Complete requests:  10
> Failed requests:0
> Write errors:   0
> Total transferred:  83302499 bytes
> Total POSTed:   69302079
> HTML transferred:   67202016 bytes
> Requests per second:361.49 [/sec] (mean)
> Time per request:   11.065 [s] (mean)
> Time per request:   2.766 [s] (mean, across all concurrent requests)
> Transfer rate:  294.08 [bytes/sec] received
> 244.65 kb/s sent
> 538.73 kb/s total
>
> Connection Times (ms)
>   min  mean[/-sd] median   max
> Connect:00   1.3  0 243
> Processing: 0   10 110.7  15995
> Waiting:08 101.0  14267
> Total:  0   10 110.7  25995
>
> Percentage of the requests served within a certain time (ms)
>   50%  2
>   66%  2
>   75%  2
>   80%  2
>   90%  3
>   95%  3
>   98%  8
>   99%218
> 100%   5995 (longest request)
>
>
>
>
> process list
> ---
>
> USER  PR  NI  VIRT  RES  SHR S %CPU %MEMTIME+   UID   PID COMMAND
> daemon16   0  299m  69m 1772 D  0.0  6.9   0:06.141 29959 ./httpd
> -k start
> daemon16   0  237m  61m 1772 D  0.0  6.0   0:04.891 29957 ./httpd
> -k start
> daemon15   0  119m  47m 2260 S  0.0  4.7   0:02.391 30151 ./httpd
> -k start
> daemon15   0 91468  46m 2260 S  0.0  4.6   0:01.671 30215 ./httpd
> -k start
> daemon16   0  296m  46m 1772 S  0.0  4.6   0:06.181 29958 ./httpd
> -k start
> daemon15   0 89352  46m 2260 S  0.0  4.6   0:01.801 30205 ./httpd
> -k start
> daemon15   0  301m  45m 1612 S  0.0  4.5   0:06.171 29956 ./httpd
> -k start
> daemon15   0  133m  45m 2260 S  0.0  4.5   0:02.741 30110 ./httpd
> -k start
> daemon15   0 74116  44m 2260 S  0.0  4.4   0:01.461 30244 ./httpd
> -k start
> daemon15   0  128m  44m 2260 S  0.0  4.4   0:02.561 30120 ./httpd
> -k start
> daemon16   0  247m  40m 1764 D  0.0  4.0   0:05.451 30012 ./httpd
> -k start
> daemon15   0 45464  34m 2260 S  0.0  3.4   0:00.821 30364 ./httpd
> -k start
> daemon16   0  180m  32m 1764 D  0.0  3.2   0:03.991 30013 ./httpd
> -k start
> daemon16   0  160m  30m 1764 D  0.0  3.0   0:03.611 30014 ./httpd
> -k start
> daemon16   0  184m  28m 1652 D  0.0  2.9   0:04.041 30019 ./httpd
> -k start
> dinesh15   0 31024  15m 4972 S  0.0  1.5   0:19.63 1000  4763 emacs -f
> gnus
> root  15   0 99.8m 6600 2044 S  0.0  0.6   0:18.990  4333
> /usr/bin/X11/

Re: Memory Issues in Sample Server Code

2007-10-29 Thread Subra A Narayanan
Hello David,

Were you able to run the test again after adding some of the free()
statements back in? Did it improve the performance? I am seeing a similar
issue where the memory footprint of the apache process keeps increasing
until a point when the server becomes very unresponsive and my client starts
getting timeouts.

After a while the root apache process spawns some new processes and the
server starts responding again. But the earlier apache processes never free
up their memory. Their memory usage reaches about 60mb and kind of stays
there.

I am using Axis 1.1 with apache 2.0.59.

May be someone from the Apache team can shed some more light.


Thanks,
Subra

On 10/12/07, David Klassen <[EMAIL PROTECTED]> wrote:
>
> Thanks, I assumed that this memory would be automatically free'd. I will
> try again, stress testing then waiting for the memory to be free'd, since I
> did not  give the server a break in the action (Rather just watched the
> process memory move from 20 MB to 500MB without seeing any memory relieved).
> Over a  period of 30 minutes @ 25 requests/second.
>
> However I am very sure that a well designed server should not reach a
> 500MB process footprint. The functionality of Linux v1.1.0 single threaded
> example server (axis2_http_server), seems to have changed so as to not
> de-allocate all the memory right away. I suspect that with all the
> indentation changes and code replacements from the v1.0.0 release to 
> 1.1.0release perhaps a _free() or _FREE() function was accidentally removed in
> the process. I have already spotted one questionable place, when I scanned
> the svn diff from v1.0.0 to v1.1.0. I will test my theory tomorrow,
> attempting to read-add various free() functions where I cannot justify
> removal.
>
> - Original Message -
> From: Samisa Abeysinghe <[EMAIL PROTECTED]>
> Date: Thursday, October 11, 2007 7:46 pm
> Subject: Re: Memory Issues in Sample Server Code
> To: Apache AXIS C User List 
>
> > David Klassen wrote:
> > > Right this is what I have already done, using gnuthilla and
> > without
> > > gnuthilla. Unfortunately using mod_axis2.so with v1.1.0 or
> > v1.0.0
> > > causes the size of  httpd.exe to grow continually. I
> > decided to post
> > > bug  *AXIS2C-717
> > *
> > > detailing where the memory of httpd.exe kept growing and
> > eventually
> > > encountered an unhandled exception.
> > Please note that, even though there seems to be a growith, if
> > you keep
> > on sending requests, you would notice that, at some point, it
> > drops
> > back. This is dues to the pooling behaviors of apache. I cannot
> > recall
> > an exact number, after which it would drop, possibly you have to
> > send
> > few hundred requests.
> >
> > Samisa...
> > >
> > > - Original Message -
> > > From: Dumindu Pallewela <[EMAIL PROTECTED]>
> > > Date: Thursday, October 11, 2007 2:27 pm
> > > Subject: Re: Memory Issues in Sample Server Code
> > > To: Apache AXIS C User List 
> > >
> > > > Hi David,
> > > >
> > > > As we use apr pools for memory management in mod_axis2, the loss
> > > > that you see (when deployed in apache2) is most _likely_ not
> > a bug.
> > > > Rather, it should be because that is how apr pools work.
> > They do not
> > > > necessarily free up memory immediately after a pool is destroyed.
> > > >
> > > > The best way to test the apache module (If this isn't what you
> > > > already did!), is to run the client repeatedly and check if the
> > > > memory grows significantly.
> > > >
> > > > HTH,
> > > > -Dumindu.
> > > >
> > > > David Klassen wrote:
> > > > > Actually I was using both apache and the
> > axis2_http_server, of
> > > > which the axis2_http_server had less memory absorption.
> > > > Incidentally I also found a difference in the amount of memory
> > > > loss due to version of the axis2c client program used. All tests
> > > > were performed using a v1.1.0 based server on Windows. The
> > > > client programs were invoked on Linux using both v1.0.0 and
> > > > v1.1.0 of axis2c:
> > > > >
> > > > >
> > > >
> > Server|  v1.1.0 client   |   v1.0.0 client
> > > > > ---
> > > > >
> > > >
> > httpd.exe|   24K loss  |   16K loss
> > > > > axis2_http_server.exe | 8K
> > > > loss  |
> > 4K loss
> > > > >
> > > > > I then decide to try using a Windows client against a Linux
> > > > server. The windows client only used version 1.1.0.  I only
> > > > used the Linux axis2_http_server for the server but alternated
> > > > between v1.1.0 and v1.0.0. Here are the results:
> > > > >
> > > > >
> > > > >
> > > > >
> > > >
> > Server |   v1.1.0 Window Client
> > > > >
> > > > > ---
> > > > >
> > > > > axis2_http_server v1.1.0
> > > > | 4K loss
> > > > >
> > > > > axis2_http_server v1.0.0
> > > > | no loss
> > > > >
> 

Re: issue 731 - please have a look

2007-10-25 Thread Subra A Narayanan
Hello,

So what is the proposed solution to this problem? Is the code going to be
changed so that apr_base64_decode_len() always returns the correct length or
should developers use [axutil/apr]_base64_decode() to get the exact length?

I use the apr_base64_decode_len() function to allocate memory for attachment
recvd via the webservice and that introduces garbage characters in the end
as the len function always returns a value greates than the actual length.

Subra

On 10/23/07, Dumindu Pallewela <[EMAIL PROTECTED]> wrote:
>
> Kaushalye Kapuruge wrote:
> > Samisa Abeysinghe wrote:
> >> Mark Nüßler wrote:
> >>> hello users,
> >>>
> >>> on 26.09.2007 Royston Day found an issue,
> >>> i just correct my svn-code localy.
> >>>
> >>> Can someone have a look - 4 me Royston is
> >>> right.
> >>>
> >>> https://issues.apache.org/jira/browse/AXIS2C-731
> >> I think Rampart folks uses base64 encoding. Can someone using rampart
> >> please verify that the proposed code it correct.
> >>
> > I tried with the new code and it worked fine for all the scenarios in
> > Rampart/C. But I'm concerned about the interoperability. So it's too
> > early to say that new implementation is correct unless it is
> > inter-operable with other implementations. I'll update on that later.
>
> axutil_base64_decode_len() is the same implementation as that of the
> apr_base64_decode_len() found in libapr. AFAIK, this does not
> returns the exact decoded length of the encoded string, but returns
>   at least as many number of bytes that is necessary. Exact length
> is anyway returned by the [axutil/apr]_base64_decode().
>
> Thus, if the length returned from the proposed code is correct,
> there should be no problems with interoperability.
>
> -Dumindu.
>
> --
> Dumindu Pallewela
> http://blog.dumindu.com
> GPG ID: 0x9E131672
>
> WSO2 | http://wso2.com | "Oxygenating the Web Service Platform"
>
>
>


Bug in axis2c xml parsing?

2007-10-18 Thread Subra A Narayanan
Hello folks,

I use the following code to parse an incoming ws request. I am posting only
snippets of the code for sake of brevity

**CODE
BEGIN***
axutil_qname_t *Qname = axutil_qname_create(env, "Price",
MY_NAMESPACE_URI, MY_NAMESPACE_PREFIX);
axiom_node_t *myNode = NULL;
axiom_element_t *myElement = NULL;
myElement = axiom_element_get_first_child_with_qname(rootElement, env,
Qname, rootNode, &myNode);

if (myNode)
{
...
...
...
return AXIS2_SUCCESS;
}
else
{
AXIS2_LOG_DEBUG(env->log, AXIS2_LOG_SI, "Error!!");
return AXIS2_FAILURE;
}

**CODE
END**

If I have a node like this, it just works fine (here 'MyOperation' is the
root node from above)


   250



but if I have a node like this


   


the control goes in to the else condition and it returns AXIS2_FAILURE

I would think this shouldn't be happening since we do have a 'Price' node
although it is empty.

Is this by design or have I found a bug?


Thanks,
Subra


Re: Urgent: Specifying scope in Axis2c

2007-10-11 Thread Subra A Narayanan
thanks samisa.

where would i store such a flag? service group context like in the
add.cexample from sg_math service?

On 10/11/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hello everyone,
> >
> > I have run in to an issue which I can't seem to figure out. In my init
> > method in the service skeleton I call the initialization routine of
> > one of the libraries that my web service uses. I notice in my logs
> > that the library initialization function is being called 8 times. This
> > corresponds to the number of apache processes that are running.
> This is a problem yet to be solved in Axis2/C. See
> http://damithakumarage.wordpress.com/2007/09/23/an-axis2-c-design-issue/.
> This is a pending issue that needs to be fixed.
> The workaround for the time being would be to use some persistent
> storage to keep a flag and call the init routine based on the flag value.
>
> Samisa...
> >
> > This is causing a lot of issues because I was under the impression
> > that my web service init function is called only once when the first
> > request comes in. My library sets up some resources which I want to
> > share among all processes. Can this be done?
> >
> > In Axis2/Java there is a way to specify scope for the webservice
> > (request, session, application) in the services.xml file? can
> > something similar be done in Axis2/c? I took a look at the axis2c code
> > and saw that there is an enum called axis2_scope defined. Is it used
> > for the same purpose as in Axis2/Java?
> >
> > Thanks for any help.
> >
> > Subra
> >
> >
> >
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/PHP
> "
> http://wso2.org/projects/wsf/php?WSO2 Web Services Framework%2FPHP - Open source PHP extention for providing and consuming Web services in PHP
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Urgent: Specifying scope in Axis2c

2007-10-11 Thread Subra A Narayanan
Hello everyone,

I have run in to an issue which I can't seem to figure out. In my init
method in the service skeleton I call the initialization routine of one of
the libraries that my web service uses. I notice in my logs that the library
initialization function is being called 8 times. This corresponds to the
number of apache processes that are running.

This is causing a lot of issues because I was under the impression that my
web service init function is called only once when the first request comes
in. My library sets up some resources which I want to share among all
processes. Can this be done?

In Axis2/Java there is a way to specify scope for the webservice (request,
session, application) in the services.xml file? can something similar be
done in Axis2/c? I took a look at the axis2c code and saw that there is an
enum called axis2_scope defined. Is it used for the same purpose as in
Axis2/Java?

Thanks for any help.

Subra


Re: Help needed on building custom soap fault in axis2c

2007-10-04 Thread Subra A Narayanan
Hi Dimuthu,

I am using the solution you suggested in your last mail. That solution is
perfect for my application. But I have some concerns. I saw this line in
your code

#define MYSERVICE_ERROR_CODES_START (AXIS2_ERROR_LAST + 2000)


Will this cause any problems in the future? What if the value of
AXIS2_ERROR_LAST changes? Or what if some other axis2 component (like
sandesha or neethi or something else) uses error codes in the same range?
Will I be forced to change my code because of the above scenarios?

Any help is greatly appreciated.

Subra



On 10/1/07, Dimuthu Gamage <[EMAIL PROTECTED]> wrote:
>
> Hi Sathya,
>
> Please check the attachment. This tries to use custom error codes. (mostly
> follow the way Sandhesha/C is using their custom error messages)
> Anyway still functions like  "axutil_error_get_message" are too inflexible
> to work with custom error codes. So we need to define our version of the
> same function.
>
> Thanks
> Dimuthu
>
> On 10/1/07, Sathya Raghunathan <[EMAIL PROTECTED]> wrote:
> >
> > If i have build a soap fault based on an error code, should i create a
> > global variable in axutil_error_init() function? Can i make use of the
> > axutil_error_messages array?
> >
> > Thanks
> > Sathya
> >
> >
> > On 9/29/07, Dimuthu Gamage < [EMAIL PROTECTED]> wrote:
> >
> > > HI  Sathya,
> > >
> > > you can follow the attachments. I didnt test it, but it may give some
> > > hints to do your work.
> > > If you want to build a soap fault base on an error code, you need to
> > > keep a global variable to keep the error code and build the soap exception
> > > based on that.
> > >
> > > So It is clear we should have a better mechanism than this to do that,
> > > I think there was a discussion earlier in the same topic in the list
> > > sometime ago. We should quickly figure out a good way to do this and fix 
> > > the
> > > code generation templates.
> > >
> > > Thanks
> > > Dimuthu
> > >
> > >
> > >
> > > /*axiom_element_set_text(error_ele, env,
> > > adb_MyFirstException_get_text(_MyFirstException,env),
> > > error_node); */
> > >
> > > /** instead use following */
> > >
> > > another_node =
> > > adb_MyFirstException_serialize(_MyFirstException, env, NULL, AXIS2_FALSE);
> > > axiom_node_add_child(error_node, env, another_node);
> > >
> > >
> > > IN the client side axis2_stub_MyService.c should be changed like
> > > following.
> > >
> > >
> > > ret_node =  axis2_svc_client_send_receive_with_op_qname( svc_client,
> > > env, op_qname, payload);
> > >
> > > /** Just before this line, add following */
> > >
> > > if(ret_node && axiom_node_get_data_element( ret_node, env)
> > > &&
> > > axutil_strcmp("fault",
> > >  axiom_element_get_localname((axiom_element_t
> > > *)axiom_node_get_data_element( ret_node, env), env)))
> > > {
> > > /** adb_MyFirstException_t* _MyFirstException should
> > > be declared */
> > > _MyFirstException = adb_MyFirstException_create(env);
> > > adb_MyFirstException_deserialize(_MyFirstException,
> > > env, axiom_node_get_first_child( ret_node));
> > >
> > > /** so you have the same _MyFirstException you created
> > > at
> > >  * onfault is here, just do the processing at here
> > > manually */
> > > }
> > >
> > > On 9/29/07, Sathya Raghunathan < [EMAIL PROTECTED] > wrote:
> > > >
> > > > If you just check the axis2_svc_skel_MyService_on_fault() in the
> > > > attached file, please let me know if i have modified it correctly or 
> > > > not. Is
> > > > this the way to do? If i test that out, the server crashes. If i 
> > > > comment out
> > > > the object myfirstexception from it, i can see that a fault element is 
> > > > set
> > > > in the output with some message that i hardcoded there.
> > > >
> > > > Please guide me with the proper step of building the custom fault in
> > > > that function.
> > > >
> > > > Thanks
> > > > Sathya
> > > >
> > > >
> > > >  On 9/29/07, Sathya Raghunathan <[EMAIL PROTECTED] >
> > > > wrote:
> > > > >
> > > > > Hi Dimuthu,
> > > > >
> > > > > Do you have any example custom soap fault wsdl? I am not clear
> > > > > with this concept I tried a new example, since you found some 
> > > > > problems with
> > > > > my last wsdl file. I have attached the wsdl file. In that, there is 
> > > > > one
> > > > > myOperationRequest which is a string, and a myOperationResponse which 
> > > > > is
> > > > > also a string. There are two custom faults here, MyFirstException and
> > > > > MySecondException. With this wsdl, the service function that was 
> > > > > generated
> > > > > was as below:
> > > > >
> > > > > adb_myOperationResponse_t* axis2_skel_MyService_myOperation (const
> > > > > axutil_env_t *env  ,
> > > > >   adb_myOperation_t*
> > > > > myOperation )
> > > > > {
> > > > >  a

Re: Unable to locate/load library

2007-09-18 Thread Subra A Narayanan
Samisa/Dinesh,

I think I wasn't clear about my question.

My web service library name is libuserdata.so. I have placed this file in
axis2-deploy-directory/services/userdata folder. libuserdata.so uses another
library called libtestws.so. This is file that is not being loaded. I placed
this file in the same directory as libuserdata.so but even that didn't help.

But when I placed the file in /usr/lib folder, apache found it and loaded it
successfully.

But is there any way to tell apache to look in some other folder for the
file. I dont want to add all my library files to /usr/lib file but want
apache to look in /my/library/files/folder. Can this be done?

Thanks,
Subra



On 9/18/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hello folks,
> >
> > My webservice calls a c library but is unable to load it as it can't
> > locate it. I put some debugging code in the framework code and this is
> > what I see in the axis2 log.
> >
> > [Mon Sep 17 16:53:41 2007] [error] raw_xml_in_out_msg_recv.c(110) Impl
> > object for service 'object' not set in message receiver. 100 :: Failed
> > in creating DLL
> > [Mon Sep 17 16:53:41 2007] [debug] raw_xml_in_out_msg_recv.c(115)
> > create_funct failed 'libtestws.so: cannot open shared object file: No
> > such file or directory' :
> > [Mon Sep 17 16:53:41 2007] [debug] engine.c(296) Axis2 engine receive
> > completed!
> >
> >
> > I have set the LD_LIBRARY_PATH and the file is in the path. Is there
> > something else that I am missing?
> What is the "ServiceClass" setting in your services.xml file? It looks
> to me that you have:
> testws
>
> In this case, make sure you have a folder named testws in your
> repository and also make sure that you have the libtestws.so in there.
>
> If you have both the service class setting and the service folder with
> the correct lib in place, then you may check how you liked it. You have
> to have
> -lpthread -ldl when linking the service lib.
>
> Thanks,
> Samisa...
>
> >
> > Is there an apache start up script file or something where I can
> > specify where to look for library files? My web service builds
> > perfectly fine with the correct LD_FLAGS options. The error happens
> > when I try to invoke the service.
> >
> > Thanks,
> > Subra
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/PHP
> "
> http://wso2.org/projects/wsf/php?WSO2 Web Services Framework%2FPHP - Open source PHP extention for providing and consuming Web services in PHP
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Unable to locate/load library

2007-09-17 Thread Subra A Narayanan
Hello folks,

My webservice calls a c library but is unable to load it as it can't locate
it. I put some debugging code in the framework code and this is what I see
in the axis2 log.

[Mon Sep 17 16:53:41 2007] [error] raw_xml_in_out_msg_recv.c(110) Impl
object for service 'object' not set in message receiver. 100 :: Failed in
creating DLL
[Mon Sep 17 16:53:41 2007] [debug] raw_xml_in_out_msg_recv.c(115)
create_funct failed 'libtestws.so: cannot open shared object file: No such
file or directory' :
[Mon Sep 17 16:53:41 2007] [debug] engine.c(296) Axis2 engine receive
completed!


I have set the LD_LIBRARY_PATH and the file is in the path. Is there
something else that I am missing?

Is there an apache start up script file or something where I can specify
where to look for library files? My web service builds perfectly fine with
the correct LD_FLAGS options. The error happens when I try to invoke the
service.

Thanks,
Subra


Re: Changing the web service end point

2007-09-07 Thread Subra A Narayanan
Thanks Samisa!!!

On 9/7/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> I forgot to mention that I fixed this for simple Axis server as well.
> But in that case, you have to recompile the source. Only the httpd
> module support the config based deployment. I hope we can live with that
> as simple axis server would hardly be used in production.
>
> Thanks,
> Samisa...
>
> Samisa Abeysinghe wrote:
> > Subra A Narayanan wrote:
> >> Hello everyone,
> >>
> >> Endpoint for Web services written using Axis2c are generally of the
> >> format
> >>
> >> => http://www.foo.com/axis2c/services/servicename
> >>
> >>
> >> By modifying the httpd.conf (or apache2.conf) file, I was able to
> >> change the above to
> >>
> >> => http://www.foo.com/subra/services/servicename
> >>
> >>
> >> Now I would like to get rid of the word "services" from the uri. How
> >> do I do that. Is that even possible?
> > Good that you raised the question, I fixed it today in svn head and
> > will be available with 1.1 release.
> > To get an idea on how to achieve this, please have a look at the
> > comment here:
> > http://issues.apache.org/jira/browse/AXIS2C-410#action_12525679
> >
> > Thanks,
> > Samisa...
> >>
> >>
> >> Thanks for any help!
> >>
> >>
> >> Subra
> >
> >
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Changing the web service end point

2007-09-06 Thread Subra A Narayanan
Hello everyone,

Endpoint for Web services written using Axis2c are generally of the format

=> http://www.foo.com/axis2c/services/servicename


By modifying the httpd.conf (or apache2.conf) file, I was able to change the
above to

=> http://www.foo.com/subra/services/servicename


Now I would like to get rid of the word "services" from the uri. How do I do
that. Is that even possible?


Thanks for any help!


Subra


Re: REST with Axis2/C

2007-09-05 Thread Subra A Narayanan
Thanks for all your help Samisa!


On 9/4/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Sorry about the late reply - please see my comments in line.
> Subra A Narayanan wrote:
> > Good Morning Samisa,
> >
> > Could you pls elaborate a little bit more on ur statement "The problem
> > you would have to solve in
> > this case would be, how to handle the resources requested to a service."
> First, there is an error in my statement. It is not "how to handle",
> rather it should be "how to map". Sorry about that.
> Now to what I meant; when the request comes, you have to locate the
> service. In Axis2/C jargon, we call this process 'dispatching', and
> there are multiple dispatch mechanisms - from those request URL based
> dispatcher could be used for REST case.
> >
> > I am not sure I understand that correctly.
> >
> > Also can you point me to code in Axis2/C framework where I could begin
> > looking to get ideas for my module (this is the first time I will be
> > writing one). Also I will start looking into libcurl. Is threading a
> > major issue that needs to be dealt with while writing modules?
> Our apache module code is located inside the folder
> src/core/transport/http/server/apache2/
>
> Threading is not an issue - APR, the core library that httpd runs on,
> handles those for you - you just have to worry about how to handle
> requests.
>
> Thanks,
> Samisa...
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: REST with Axis2/C

2007-09-03 Thread Subra A Narayanan
Good Morning Samisa,

Could you pls elaborate a little bit more on ur statement "The problem you
would have to solve in
this case would be, how to handle the resources requested to a service."

I am not sure I understand that correctly.

Also can you point me to code in Axis2/C framework where I could begin
looking to get ideas for my module (this is the first time I will be writing
one). Also I will start looking into libcurl. Is threading a major issue
that needs to be dealt with while writing modules?


Thanks in advance!
Subra

On 9/3/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Samisa,
> >
> > Thank you for ur reply.
> >
> > I think I agree with ur views. I think I will have to look for other
> > ways of supporting REST for my web service. I was loking in to writing
> > my own apache module since all I need is access to the request_rec
> > struct, parse the uri and then call the same library (its a c++
> > library with a C like interface) that I call from my SOAP web service.
> >
> > Do you think thats what I need? Do you think it would be better to use
> > some other library/framework rather than writing my own module? Do you
> > know of any such framework for REST?
> There are no C REST libraries as such that I know of out there. However,
> you can leverage the features of an HTTP library like libcurl. libcurl
> is a client side library though. Hence it looks it is better to write
> your own Apache httpd module for the server side, because then you have
> control over what you could do. The problem you would have to solve in
> this case would be, how to handle the resources requested to a service.
> I think it would not be a big deal to come up with a mechanism - you can
> even get some ideas and/or code form Axis2/C to do that. Axis2/C code
> also has a mime parser, so you can use that code too to pick up MIME
> attachments form requests.
>
> Thanks,
> Samisa...
>
>
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: 1.1?

2007-09-03 Thread Subra A Narayanan
Hi Dinesh,

Do you if it will be done in time for release 1.1? It would be a great help
as right now there is no way of sending meaningful error messages to client.

Thanks,
Subra


On 9/3/07, Dinesh Premalal <[EMAIL PROTECTED]> wrote:
>
> Hi,
> Samisa Abeysinghe <[EMAIL PROTECTED]> writes:
> > Subra A Narayanan wrote:
> >> Any idea if any of the following JIRA issues will be fixed in time
> >> for the 1.1 release
> >>
> >> http://issues.apache.org/jira/browse/AXIS2C-678
> > I think Dinesh was looking into this sometime back. Dinesh it would be
> > great if you could comment on the issue?
> I think we need to do bit of a refactoring to our error
> mechanism. Because as this issue raised, we are unable to give user to
> define custom errors, moreover now we can only see last
> error only. We need to enable ability to see the stack of errors or
> something like that. However I was unable to do some workaround
> regarding this issue. I think , I will be able to find sometime to
> work on this issue.
>
>
> thanks,
> Dinesh
>
> PS:Sorry, I was bit out of sync with the list past few days. That's why
> delayed to reply.
>
> --
> Dinesh Premalal
> http://xydinesh.wordpress.com/
> GPG ID : A255955C
> GPG Key Finger Print : C481 E5D4 C27E DC34 9257  0229 4F44 266E A255 955C
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: REST with Axis2/C

2007-09-02 Thread Subra A Narayanan
Hey Samisa,

First, I apologize for the delay in replying.

I feel, the reason REST has got so much attention lately is because of its
perceived simplicity. I feel supporting REST by converting REST requests in
to SOAP requests behind the scenes may not be a good idea. One major problem
that I can see with that approach is how do we handle REST requests with
attachments?

Can we have the ability in Axis2 to define 2 service endpoints? Lets say
something like

http://www.foo.com/axis2c/ - for SOAP (which is how axis2c works today)

http://www.foo.com/axis2c/REST - for REST


Then in the axis2_apache2_worker_process_request function in the
apache2_worker.c file, depending on the end point either axis2 continues to
do what it is doing today or hands over the request (request_rec struct) to
the user written code who can process it in anyway and return a response.
This will give so much flexibility to for REST development. The ws creator
can then take care of issues like attachments, multiple parametrs for the
operations etc at the same time making use of the rich library that axis2
provides. And also the user (service creator) can let axis2 worry abt
threading and memory management issues.

Such a feature would be a great help for developers like us who want to
provide a full fledged REST support for our services. Thoughts?

Subra




On 8/29/07, Samisa Abeysinghe < [EMAIL PROTECTED]> wrote:
>
>
> >>
> >> Here are my thoughts:
> >>
> >> I have been going through the Axis2/c framework code and I think I
> >> have a fair (although not complete) understanding of how REST works
> >> in Axis2. If we can have a way to let the developers of the
> >> webservice write their own implementaion of how to handle REST
> >> request, that will be great.
> >>
> >> Something like an interface that the developers have to implement so
> >> as to receive RESt requests. Once the request is received, it is up
> >> to the developers to construct the corresponding SOAP message by
> >> looking at the URL and the HTTP method and give it back to the
> >> framework which inturn forwards the SOAP envelop to the web service
> >> implementation.
> > This sounds very flexible. There are two points the user can specify
> > what they want in case of a service. One is in the services.xml config
> > file. The second is the service implementation itself. Non of these
> > methods could be used in this case, as we have to first deal with the
> > request to identify the service to be invoked. May be, the REST
> > request processing could be another service, which will process the
> > request and formulate the payload based on the request, and invoke the
> > required service within that service.
> I looked at how Axis2/Java has implemented REST yesterday, and they seem
> to have done some improvements over the initial model that we have used
> in C.
>
> The ideas come from WSDL 2.0 Adjuncts:
> http://www.w3.org/TR/wsdl20-adjuncts/
>
> Basically you can provide a resource config in services.xml to map
> resources to operations and payload formats.
> You can have the config syntax of a resource like the following
> http://localhost/axis2/services/[service_name]/[operation_name]/[val_1]/[val_2]
>
> <http://localhost/axis2/services/%5Bservice_name%5D/%5Boperation_name%5D/%5Bval_1%5D/%5Bval_2%5D>
>
> So I can have something like the following in the services.xml file:
> http://localhost/axis2/services/echo/echoString/text
>
> And the REST client is requesting for the resource
> http://localhost/axis2/services/echo/echoString/Hello%20World
>
> I can map that resource to service 'echo' and build the payload
> 
>
>   Hello World
>
> 
>
> I can use the URL based dispatcher to find the payload. I think we can
> implement this model without much trouble on top of Axis2/C architecture.
>
> Thoughts please...
>
> Thanks,
> Samisa...
>
> And if your mapping is like
> >
> > Thanks,
> > Samisa...
> >>
> >> They say a picture is worth a thousand words - I will try to
> >> summarize this whole thing as a diagram first thing tomorrow morning
> >> and send it to you guys.
> >>
> >> I would like to emphasize that the above is my understanding of how
> >> REST works and I admit it may be flawed. So feel free to correct me
> >> lets discuss what is the best way to implement REST in Axis2.
> >>
> >>
> >> Thanks for the help!
> >>
> >> Subra
> >>
> >>
> >> On 8/28/07, *Samisa Abeysinghe* < [EMAIL PROTECTED]
> >> > wrote:
> >>
> >>

Re: HTTP return codes

2007-09-02 Thread Subra A Narayanan
I apologize for the delay in replying.

My question was somewhat related to the my other question about REST support
in Axis2c. I have seen that a lot of webservices with REST support return
standard HTTP return codes like the following as a response

501- NOT IMPLEMENTED

*400 - Bad Request*
The syntax of the request was not understood by the server.

*401 - Not Authorised*
The request needs user authentication

Thats why I wanted to find out if something similar can be done in Axis2c as
well.


Subra


On 8/29/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Samisa Abeysinghe wrote:
> > Subra A Narayanan wrote:
> >> Hello everyone,
> >>
> >> Is there any way to return standard HTTP return codes to the clients
> >> from a Axis2/C web service. For e.g. HTTP 404, HTTP 201, etc etc.
> > No, not using service client API. Transport info are hidden form client.
> BTW, what is the use case?
>
> Thanks,
> Samisa...
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


HTTP return codes

2007-08-29 Thread Subra A Narayanan
Hello everyone,

Is there any way to return standard HTTP return codes to the clients from a
Axis2/C web service. For e.g. HTTP 404, HTTP 201, etc etc.

Subra


Re: REST with Axis2/C

2007-08-28 Thread Subra A Narayanan
Hey Samisa,

The way Axis2/C supports REST is not fully REST compliant (I am sorry to use
the word compliant since REST is not really a standard). REST says
everything is a resource and URI represent resources. So the URIs should
have nouns in them rather than verbs. For e.g. in the Amazon S3 webservice
example, the uri just had the object name but what action needs to be taken
on the object is decided by the HTTP method (GET retrieves the object,
DELETE removes it and PUT stores the object. The URI is the same in all the
3 cases)

Here are my thoughts:

I have been going through the Axis2/c framework code and I think I have a
fair (although not complete) understanding of how REST works in Axis2. If we
can have a way to let the developers of the webservice write their own
implementaion of how to handle REST request, that will be great.

Something like an interface that the developers have to implement so as to
receive RESt requests. Once the request is received, it is up to the
developers to construct the corresponding SOAP message by looking at the URL
and the HTTP method and give it back to the framework which inturn forwards
the SOAP envelop to the web service implementation.

They say a picture is worth a thousand words - I will try to summarize this
whole thing as a diagram first thing tomorrow morning and send it to you
guys.

I would like to emphasize that the above is my understanding of how REST
works and I admit it may be flawed. So feel free to correct me lets discuss
what is the best way to implement REST in Axis2.


Thanks for the help!

Subra


On 8/28/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Samisa,
> >
> > I have been looking at the code that you pointed me to and trying to
> > figure out how REST works. Right now, the method name needs to be in
> > the URL for REST to work. To make Axis2/C more RESTful, we would need
> > a way to map HTTP methods and keywords in the URI to map to webservice
> > method names. I will take amazon s3  service to explain what I mean.
> > Look at the following 2 requests:
> >
> > #1 get object request
> >
> > GET /[bucket-name]/[key-name] HTTP/1.0
> > Date: Wed, 08 Mar 2006 04:06:18 GMT
> > Authorization: AWS [aws-access-key-id]:[header-signature]
> > Host: s3.amazonaws.com <http://s3.amazonaws.com>
> >
> >
> > #2 delete object request
> >
> > DELETE /[bucket-name]/[key-name] HTTP/1.0
> > Date: Wed, 08 Mar 2006 04:06:19 GMT
> > Authorization: AWS [aws-access-key-id]:[header-signature]
> > Host: s3.amazonaws.com <http://s3.amazonaws.com>
> >
> >
> > The above 2 requests look exactly the same except for their HTTP
> > methods: GET vs DELETE. In Axis2/C I think we would need a way to may
> > HTTP method name/key word in URI to be mapped to a webservice
> > operation name so that the soap request can be formed accordingly.
> >
> > Do you have suggestions as to how this can be done in a generic way?
> At the moment, in out GET support for REST, you can get something like
> the following working.
>
> GET /axis2/services/echo/echoString?text=Hello%20World%21 HTTP/1.1
> User-Agent: Axis2/C
> Host: 127.0.0.1:9090
>
> The mapping that we use at the moment is that the last token in request
> URI path become the operation, in this case 'echoString'. And the
> parameters that follow becomes parameter/value pairs. In this case we
> have "text => Hello World". Using parameter/value pairs we construct the
> XML payload for the request.
>
> Now lets consider the sample GET case first. Could you point me to few
> use cases where the format that we are using would not map to the GET
> template that you have provided. That would help me understand what we
> should be doing different at Axis2/C level.
>
> Once we understand the GET case, we can look into DELETE case. However,
> if you feel that our current implementation of GET support can handle
> the generic GET template that you are providing, we can use the same for
> DELETE as well.
>
> Thanks,
> Samisa...
> >
> > Thanks,
> > Subra
> >
> >
> > On 8/23/07, *Samisa Abeysinghe* < [EMAIL PROTECTED]
> > > wrote:
> >
> > Dinesh Premalal wrote:
> > > Hi Subra,
> > > "Subra A Narayanan" < [EMAIL PROTECTED]
> > > writes:
> > >
> > >> So the solution looks like writing an Apache module (I have
> > never written one
> > >> before) which receives the REST request, translates the request
> > to a SOAP
> > >> request and then forwards it on to Axis2/c. But this is exactly
> > what Axis2/C is

Re: 1.1?

2007-08-28 Thread Subra A Narayanan
Any idea if any of the following JIRA issues will be fixed in time for the
1.1 release

http://issues.apache.org/jira/browse/AXIS2C-678
http://issues.apache.org/jira/browse/AXIS2C-676
http://issues.apache.org/jira/browse/AXIS2C-672

Thanks,
Subra



On 8/28/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Stefano Pettini wrote:
> > Dear all,
> >
> > any news about Axis2/C 1.1 ??
> I am working on it. Specially I have been looking into the open issues
> in Jira and has been fixing those.
> I hope we should be able to do the release by mid of next month. Yes I
> said end of August earlier, but I could not fix some of issues that I
> felt must be fixed in time.
>
> Thanks,
> Samisa...
> >
> > Thank you
> > Stefano
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
>
> 
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Trouble using external library in Axis2/C

2007-08-28 Thread Subra A Narayanan
Hello folks,

I want to use an external library in my Axis2/C webservice. I library is a
shared library (.so file). In my webservice's init method, I call the
initialization function of my library and in the free method I my library's
free function to free up resources.

Then I compile my service and place .so file in the
axis2c/services/myservice folder. When I try accessing my webservice i get
the following error in my axis2.log file

.
.
[Tue Aug 28 09:58:17 2007] [info]  addr_in_handler.c
[Tue Aug 28 09:58:17 2007] [debug] phase.c(195) Invoke the handler
addressing_based_dispatcher within the phase Transport
[Tue Aug 28 09:58:17 2007] [debug] engine.c(577) Invoking phase PreDispatch
[Tue Aug 28 09:58:17 2007] [debug] phase.c(195) Invoke the handler
LoggingInHandler within the phase PreDispatch
[Tue Aug 28 09:58:17 2007] [info]  Starting logging in handler .
[Tue Aug 28 09:58:17 2007] [info]  Input message: http://schemas.xmlsoap.org/soap/envelope/";>http://www.emc.com/2007/07/maui/";>45checksumTue
Aug 28 09:58:11
2007OBJECT:READ:Group=PUBLICuseridaswats
GoogleWifi.jpghttp://www.w3.org/2004/08/xop/include
"/>
[Tue Aug 28 09:58:17 2007] [debug] engine.c(577) Invoking phase Dispatch
[Tue Aug 28 09:58:17 2007] [debug] phase.c(195) Invoke the handler
soap_message_body_based_dispatcher within the phase Dispatch
[Tue Aug 28 09:58:17 2007] [debug] soap_body_disp.c(217) Checking for
operation using SOAP message body's first child's local name : CreateObject
[Tue Aug 28 09:58:17 2007] [debug] soap_body_disp.c(226) Operation found
using SOAP message body's first child's local name
[Tue Aug 28 09:58:17 2007] [debug] engine.c(577) Invoking phase PostDispatch
[Tue Aug 28 09:58:17 2007] [debug] phase.c(195) Invoke the handler
dispatch_post_conditions_evaluator within the phase PostDispatch
[Tue Aug 28 09:58:17 2007] [debug] phase.c(195) Invoke the handler
context_handler within the phase PostDispatch
[Tue Aug 28 09:58:17 2007] [debug] engine.c(587)
End:axis2_engine_invoke_phases
[Tue Aug 28 09:58:17 2007] [debug] engine.c(564)
Start:axis2_engine_invoke_phases
[Tue Aug 28 09:58:17 2007] [debug] engine.c(587)
End:axis2_engine_invoke_phases
**[Tue Aug 28 09:58:17 2007] [error] raw_xml_in_out_msg_recv.c(109) Impl
object for service 'object' not set in message receiver. 100 :: Failed in
creating DLL**
[Tue Aug 28 09:58:17 2007] [debug] engine.c(292) Axis2 engine receive
completed!
[Tue Aug 28 09:58:17 2007] [debug] engine.c(564)
Start:axis2_engine_invoke_phases
[Tue Aug 28 09:58:17 2007] [debug] engine.c(577) Invoking phase MessageOut
[Tue Aug 28 09:58:17 2007] [debug] engine.c(587)
End:axis2_engine_invoke_phases


Please see the error generated in the raw_xml_in_out_msg_recv.c(109) file. Why
am I getting this error? Is it because axis2/C cannot find my library file?
If yes, how should I solve this problem?

Thanks for any help!

Subra


Re: REST with Axis2/C

2007-08-26 Thread Subra A Narayanan
Samisa,

I have been looking at the code that you pointed me to and trying to figure
out how REST works. Right now, the method name needs to be in the URL for
REST to work. To make Axis2/C more RESTful, we would need a way to map HTTP
methods and keywords in the URI to map to webservice method names. I will
take amazon s3  service to explain what I mean. Look at the following 2
requests:

#1 get object request

GET /[bucket-name]/[key-name] HTTP/1.0
Date: Wed, 08 Mar 2006 04:06:18 GMT
Authorization: AWS [aws-access-key-id]:[header-signature]
Host: s3.amazonaws.com


#2 delete object request

DELETE /[bucket-name]/[key-name] HTTP/1.0
Date: Wed, 08 Mar 2006 04:06:19 GMT
Authorization: AWS [aws-access-key-id]:[header-signature]
Host: s3.amazonaws.com


The above 2 requests look exactly the same except for their HTTP methods:
GET vs DELETE. In Axis2/C I think we would need a way to may HTTP method
name/key word in URI to be mapped to a webservice operation name so that the
soap request can be formed accordingly.

Do you have suggestions as to how this can be done in a generic way?

Thanks,
Subra


On 8/23/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Dinesh Premalal wrote:
> > Hi Subra,
> > "Subra A Narayanan" <[EMAIL PROTECTED]> writes:
> >
> >> So the solution looks like writing an Apache module (I have never
> written one
> >> before) which receives the REST request, translates the request to a
> SOAP
> >> request and then forwards it on to Axis2/c. But this is exactly what
> Axis2/C is
> >> also doing.
> >>
> > Yes, that is also a possibility. However I think it will be quite
> > arduous to maintain two apache modules in the long run. I would rather
> > like improving Axis2/C REST support.
> >
> I too think that it would be much simpler to improve the current REST
> support rather than to implement another Apache module.
>
> If you look at the apache module implementation, in source file
> src/core/transport/http/server/apache2/apache2_worker.c, there is a
> method named axis2_apache2_worker_process_request. If you have a look at
> this, then you can understand how GET and POST requests are dealt with
> and in turn, this function calls the methods
> axis2_http_transport_utils_process_http_get_request and
> axis2_http_transport_utils_process_http_post_request methods deal with
> detailed request processing, including REST stuff. So if you want PUT
> and DELETE you can implement new functions like,
> axis2_http_transport_utils_process_http_put_request and
> axis2_http_transport_utils_process_http_delete_request. Also, if you
> want to deal with the media types, before control is passed on to
> Axis2/C, I hope you can do that within
> axis2_apache2_worker_process_request function, as you have access to the
> request information there.
> The above are just few suggestions, to use the current apache module
> code and improve that to deal with more REST stuff. However, I did not
> look into that in detail. If you try that and have more questions please
> feel free to ask this list.
>
> Thanks,
> Samisa...
> >> I want to start looking in to improving REST support in Axis2/C. Is
> >> it doable?
> >>
> > Yes, It is.
> >
> >> Am I missing something very obvious which would prevent us from
> implementing
> >> such support in Axis2? If not please let me know as to where I should
> start
> >> looking in the Axis2 source.
> >>
> > You could start at looking HTTP transport I guess. If you could debug
> > echo_rest sample, it will be helpful to understand the underlying
> > logic.
> >
> > thanks,
> > Dinesh
> >
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: REST with Axis2/C

2007-08-23 Thread Subra A Narayanan
Thanks Samisa.I will start looking in to this and email you guys with
any questions that I may have.



On 8/23/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Dinesh Premalal wrote:
> > Hi Subra,
> > "Subra A Narayanan" <[EMAIL PROTECTED]> writes:
> >
> >> So the solution looks like writing an Apache module (I have never
> written one
> >> before) which receives the REST request, translates the request to a
> SOAP
> >> request and then forwards it on to Axis2/c. But this is exactly what
> Axis2/C is
> >> also doing.
> >>
> > Yes, that is also a possibility. However I think it will be quite
> > arduous to maintain two apache modules in the long run. I would rather
> > like improving Axis2/C REST support.
> >
> I too think that it would be much simpler to improve the current REST
> support rather than to implement another Apache module.
>
> If you look at the apache module implementation, in source file
> src/core/transport/http/server/apache2/apache2_worker.c, there is a
> method named axis2_apache2_worker_process_request. If you have a look at
> this, then you can understand how GET and POST requests are dealt with
> and in turn, this function calls the methods
> axis2_http_transport_utils_process_http_get_request and
> axis2_http_transport_utils_process_http_post_request methods deal with
> detailed request processing, including REST stuff. So if you want PUT
> and DELETE you can implement new functions like,
> axis2_http_transport_utils_process_http_put_request and
> axis2_http_transport_utils_process_http_delete_request. Also, if you
> want to deal with the media types, before control is passed on to
> Axis2/C, I hope you can do that within
> axis2_apache2_worker_process_request function, as you have access to the
> request information there.
> The above are just few suggestions, to use the current apache module
> code and improve that to deal with more REST stuff. However, I did not
> look into that in detail. If you try that and have more questions please
> feel free to ask this list.
>
> Thanks,
> Samisa...
> >> I want to start looking in to improving REST support in Axis2/C. Is
> >> it doable?
> >>
> > Yes, It is.
> >
> >> Am I missing something very obvious which would prevent us from
> implementing
> >> such support in Axis2? If not please let me know as to where I should
> start
> >> looking in the Axis2 source.
> >>
> > You could start at looking HTTP transport I guess. If you could debug
> > echo_rest sample, it will be helpful to understand the underlying
> > logic.
> >
> > thanks,
> > Dinesh
> >
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


REST with Axis2/C

2007-08-22 Thread Subra A Narayanan
Good morning folks!

This is more of a approach/design question rather than an Axis2/C question.

The project I am working on requires that I provide both SOAP and REST
interface to my webservice. With Axis2/C SOAP is no big deal. But REST is
something I am not too sure about. As it says in the API documentation
itself, Axis2/C is a SOAP toolkit and REST is not supported that well.

These 2 issues in particular
1) There is no support for PUT and DELETE
2) Also the way Axis2/C requires the operation name and the operation
parameters in the url, is a shift away from REST as there is no resource
representation.

So the solution looks like writing an Apache module (I have never written
one before) which receives the REST request, translates the request to a
SOAP request and then forwards it on to Axis2/c. But this is exactly what
Axis2/C is also doing.

I want to start looking in to improving REST support in Axis2/C. Is it
doable? Am I missing something very obvious which would prevent us from
implementing such support in Axis2? If not please let me know as to where I
should start looking in the Axis2 source.

If the above approach is not feasible, I will have to look at other ways of
supporting REST. One way would be to write my own apache module.

I would love to hear any comments/suggestions.


Thanks a lot for all the help!

Subra


Re: SOAP fault builder

2007-08-22 Thread Subra A Narayanan
Dinesh,

I have created JIRA issues for both the issues we have been talking about.
Here is a link to the issues:

Internal server error => https://issues.apache.org/jira/browse/AXIS2C-676
Ability to return custom error messages/codes to the client  =>
https://issues.apache.org/jira/browse/AXIS2C-678


Thanks!!
Subra


On 8/22/07, Dinesh Premalal <[EMAIL PROTECTED]> wrote:
>
> "Subra A Narayanan" <[EMAIL PROTECTED]> writes:
> Hi Subra,
> "Subra A Narayanan" <[EMAIL PROTECTED]> writes:
> > Thanks for your reply. I tried running the same servive with the
> > asix2_http_server and the client successfully receives a soap fault. No
> > problems there. So I think it is a bug with apache http server module.
> If you
> > guys concur, I will open a JIRA issue. It would be really nice to have
> this
> > problem fixed.
> Yes, Please do raise a JIRA issue.
> >
> > Having a way to return custom error codes/messages to client would be a
> big
> > plus? This way the client would know where exactly the error lies, on
> the
> > server side or in the request itself. Should I create a JIRA issue for
> this
> > too. If yes, under which category?
> I too think, we need to implement customize errors for user. yes
> please raise a jira under axis2c/util because error implementation is
> under the utils. If others think there should be alternate method, we
> could do it in the JIRA itself. (we could edit the JIRA accordingly).
>
> thanks,
> Dinesh
> --
> Dinesh Premalal
> http://xydinesh.wordpress.com/
> GPG ID : A255955C
> GPG Key Finger Print : C481 E5D4 C27E DC34 9257  0229 4F44 266E A255 955C
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: SOAP fault builder

2007-08-22 Thread Subra A Narayanan
Dinesh,

Thanks for your reply. I tried running the same servive with the
asix2_http_server and the client successfully receives a soap fault. No
problems there. So I think it is a bug with apache http server module. If
you guys concur, I will open a JIRA issue. It would be really nice to have
this problem fixed.

Having a way to return custom error codes/messages to client would be a big
plus? This way the client would know where exactly the error lies, on the
server side or in the request itself. Should I create a JIRA issue for this
too. If yes, under which category?

Thanks,
Subra


On 8/21/07, Dinesh Premalal <[EMAIL PROTECTED]> wrote:
>
> Hi Subra,
> "Subra A Narayanan" <[EMAIL PROTECTED]> writes:
>
> > I modified the axis2_raw_xml_in_out_msg_recv_invoke_business_logic_sync
> > function to log the soap fault message to axis2.log file just before it
> returns
> > and see the correct soap fault message. So something happens after this
> point
> > which makes the apache http server send a 500 Internal server error to
> the
> > client.
> were you able to log those fault to axis2.log? My feeling is, there
> might be some misconfiguration in apache server. Did you try with
> axis2_http_server?
>
> > My second question was, is there a way to return custom error numbers
> and error
> > message to the myservice_on_fault function so that the error number/msg
> can be
> > included in the soap fault. Right now only predefined AXIS2 error
> message can
> > be set using AXIS2_ERROR_SET. I understand that I can modify
> axutil_error.h
> > file but it says that the error codes are reserved for modules. Is there
> any
> > other better way of doing this?
> AFAIK, there is no such a mechanism. However I think we should
> provide custom error mechanism to user. May be an extension for
> current axis2 error mechanism will be helpful.
>
> Thoughts ???
>
> thanks,
> Dinesh
> --
> Dinesh Premalal
> http://xydinesh.wordpress.com/
> GPG ID : A255955C
> GPG Key Finger Print : C481 E5D4 C27E DC34 9257  0229 4F44 266E A255 955C
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: SOAP fault builder

2007-08-21 Thread Subra A Narayanan
Hey Nandika,

Thanks for your reply. Looking at the
axis2_raw_xml_in_out_msg_recv_invoke_business_logic_sync function in
raw_xml_in_out_msg_recv.c was very helpful.

So I modified my code accordingly and I think I might have found a bug in
the framework. This is what I did

1. Set error status to AXIS2_FAILURE using AXIS2_ERROR_SET
2. Return NULL from my service
3. Implement myservice_on_fault function and create an axiom node which gets
added to the soap fault details node.

No when I try return a soap fault, the server sends a 500 Internal Server
error to the client. Chris Darroch created a JIRA issue late last year about
this bug here => https://issues.apache.org/jira/browse/AXIS2C-328 but I dont
think the bug has been fixed (pls correct me if I am wrong). I used TcpMon
to capture the response and this is what the client sees:

HTTP/1.1 500 Internal Server Error Date: Tue, 21 Aug 2007 17:39:55 GMT
Server: Apache/2.0.59 (rPath) Content-Length: 613 Connection: close
Content-Type: text/html; charset=iso-8859-1  

500 Internal Server Error

Internal Server Error
The server encountered an internal error or
misconfiguration and was unable to complete
your request.
Please contact the server administrator,
 [EMAIL PROTECTED] and inform them of the time the error occurred,
and anything you might have done that may have
caused the error.
More information about this error may be available
in the server error log.

Apache/2.0.59 (rPath) Server at 168.159.116.42 Port 80


I modified the axis2_raw_xml_in_out_msg_recv_invoke_business_logic_sync
function
to log the soap fault message to axis2.log file just before it returns and
see the correct soap fault message. So something happens after this point
which makes the apache http server send a 500 Internal server error to the
client.



My second question was, is there a way to return custom error numbers and
error message to the myservice_on_fault function so that the error
number/msg can be included in the soap fault. Right now only predefined
AXIS2 error message can be set using AXIS2_ERROR_SET. I understand that I
can modify axutil_error.h file but it says that the error codes are reserved
for modules. Is there any other better way of doing this?


Thank you folks!

Subra






On 8/21/07, Nandika Jayawardana <[EMAIL PROTECTED]> wrote:
>
> Hi Subra,
>
> To send a fault from the service you can do the following.
> In the invoke function of the service skeleton set an the error status to
> AXIS2_FALSE
> and return NULL. You can use the AXIS2_ERROR_SET macro to set the error
> status.
>
> Then implement the on_fault function in the skeleton to return the error
> message you want to return. This will be added to the fault detail section.
>
> When axis2 calls invoke function and finds that it returned null, it will
> check the error status.
> If the error status if AXIS2_FALSE , then a fault is returned.
>
> You do not have to be concerned about the soap version of the fault.
> Depending on the received
> message's soap version an appropriate  soap fault will be returned.
>
> You can have a look at
> axis2_raw_xml_in_out_msg_recv_invoke_business_logic_sync function
> in raw_xml_in_out_msg_recv.c file to understand how the fault is
> processed.
>
> Regards,
> Nandika
>
>
> On 8/21/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
> >
> > Hey Nandika,
> >
> > Did you get a chance to look at my questions? I would really appreciate
> > ur input on these.
> >
> > Thanks so much!
> >
> > Subra
> >
> > On 8/17/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
> > >
> > > Hey Nandika,
> > >
> > > So I tried your suggestion but I have a doubt. I am just modifying the
> > > 'math' webservice from the samples folder.
> > >
> > > The 'add' operation returns a axiom_node_t * on success, which is
> > > nothing but the soap message. But I want to return a soap fault from the
> > > 'add' operation if lets say one of the parameters was missing from the
> > > request or it was a decimal number. If I follow what you asked me to do,
> > > what do I return from the add function? I have to return a axiom_node_t
> > > *? But from your email I thought you meant that if I set the soap
> > > fault to the message context, the soap fault will automatically be 
> > > returned
> > > to the client. I dont understand how do I stop further processing and 
> > > return
> > > a soap fault to the client.
> > >
> > > So I did some further digging in to the axis code and found this
> > > function in axiom_soap_envelope.h:
> > >
> > > AXIS2_EXTERN axiom_node_t* AXIS2_CALL
> > > axiom_soap_envelop

Re: SOAP fault builder

2007-08-20 Thread Subra A Narayanan
Hey Nandika,

Did you get a chance to look at my questions? I would really appreciate ur
input on these.

Thanks so much!

Subra

On 8/17/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
>
> Hey Nandika,
>
> So I tried your suggestion but I have a doubt. I am just modifying the
> 'math' webservice from the samples folder.
>
> The 'add' operation returns a axiom_node_t * on success, which is nothing
> but the soap message. But I want to return a soap fault from the 
> 'add'operation if lets say one of the parameters was missing from the request 
> or
> it was a decimal number. If I follow what you asked me to do, what do I
> return from the add function? I have to return a axiom_node_t *? But from
> your email I thought you meant that if I set the soap fault to the message
> context, the soap fault will automatically be returned to the client. I dont
> understand how do I stop further processing and return a soap fault to the
> client.
>
> So I did some further digging in to the axis code and found this function
> in axiom_soap_envelope.h:
>
> AXIS2_EXTERN axiom_node_t* AXIS2_CALL
> axiom_soap_envelope_get_base_node(axiom_soap_envelope_t *envelope, 
> constaxutil_env_t *env);
>
>
> so this gives me access to the soap fault message as a axiom_node_t*. And
> upon error in the 'add' operation, I just return it to the client. Is this
> the right way to do it? I am missing something here.
>
> Now one more important thing. When I call
> axiom_soap_envelope_get_base_node, it seems to returning a soap1.2 fault
> message rather than a soap1.1 message even though I set *
>
> *soapVersion = AXIOM_SOAP11;
>
> Why is that? Is there a way to get soap1.1 fault message?
>
>
> I hope my questions are clear. Thanks so much for your help!
>
>
> Subra
>
>
>
> On 8/17/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
> >
> > Thanks Nandika. I will give it a shot.
> >
> > Have a good weekend!
> >
> > On 8/17/07, Nandika Jayawardana < [EMAIL PROTECTED] > wrote:
> > >
> > > Hi Subra,
> > >
> > > You can create a soap11 fault using following lines.
> > >
> > > int soap_version = AXIOM_SOAP11;
> > >
> > > soap_envelope = axiom_soap_envelope_create_default_soap_envelope (env,
> > > soap_version);
> > >
> > > soap_body = axiom_soap_envelope_get_body(soap_envelope, env);
> > >
> > > soap_fault = axiom_soap_fault_create_default_fault (env,
> > > soap_body, "fault code" , "fault reason"
> > > , soap_version);
> > >
> > > axis2_msg_ctx_set_fault_soap_envelope(msg_ctx, env, soap_envelope);
> > >
> > > You can set the fault to the msg_ctx and it will be returned to the
> > > client.
> > >
> > > Regards
> > >
> > > Nandika
> > >
> > >
> > >
> > > On 8/17/07, Subra A Narayanan <[EMAIL PROTECTED] > wrote:
> > > >
> > > > Hello folks,
> > > >
> > > > I am trying ti build a SOAP1.1 fault and return to the ws client. I
> > > > am having some difficulty understanding how to go about this. I have 
> > > > tryng
> > > > to dig through the source code but was wondering if you guys have some
> > > > sample code. If you have it that would be very helpful in understanding 
> > > > the
> > > > usage.
> > > >
> > > > In the meantime I will continue to dig through the source code to
> > > > try to understand.
> > > >
> > > > Thanks as usual!
> > > >
> > > > Subra
> > > >
> > >
> > >
> > >
> > > --
> > > [EMAIL PROTECTED]
> > > WSO2 Inc: http://www.wso2.com
> >
> >
> >
>


Memory management in Axis2/C

2007-08-19 Thread Subra A Narayanan
Hello everyone,

I had some very basic questions about memory management in Axis2/C and hope
I can clarify my doubts with your help. I did go through the article on
memory management => http://wso2.org/library/237 but still have some
questions.

1. I am working on a new webservice for which I just copied the 'math'
service from the samples and have been just modifying it. In the 'add'
operation of the 'math' service, there are some calls to
axiom_element_get_text function which returns a const axis2_char_t* to
retrieve the parameters from the soap xml document. Who is responsible for
freeing up this memory? I assume since its const pointer and I didnt
explicitly allocate memory, it will be clened up by the framework. But when
does this happen? I looked at the math_free function in math_skeleton.c file
but it doesn't tell me much. Is this when the clean up happens?

 int AXIS2_CALL
math_free(axis2_svc_skeleton_t *svc_skeleton,
const axutil_env_t *env)
{
if (svc_skeleton)
{
AXIS2_FREE(env->allocator, svc_skeleton);
svc_skeleton = NULL;
}
return AXIS2_SUCCESS;
}



2. Is there any advantage in using the AXIS2_MALLOC over jus malloc? From my
understanding, AXIS2_MALLOC just hides the env specific implementation of
memory allocation. So if I am using 'C' either malloc or AXIS2_MALLOC are
one and the same. Am I correct? On a similar note, is there any advantage in
using axis2_char_t* over just char*?


I thank all of you for ur help and patience as I try to understand the Axis2
framework.

Subra


Using Axis2 functionality

2007-08-19 Thread Subra A Narayanan
Good morning folks,

Is it ok to use AXIS2_LOG_DEBUG (and other related logging functions) to log
errors/info/trace from my web service code to the axis2 log file? Or was the
logging functionality designed to be used only by the Axis2 framework? Any
downside of using the axis2 logging functionality? Its so convenient and
tempting to use. Please share your thoughts on this.

Thanks,
Subra


Re: SOAP fault builder

2007-08-17 Thread Subra A Narayanan
Hey Nandika,

So I tried your suggestion but I have a doubt. I am just modifying the
'math' webservice from the samples folder.

The 'add' operation returns a axiom_node_t * on success, which is nothing
but the soap message. But I want to return a soap fault from the
'add'operation if lets say one of the parameters was missing from the
request or
it was a decimal number. If I follow what you asked me to do, what do I
return from the add function? I have to return a axiom_node_t *? But from
your email I thought you meant that if I set the soap fault to the message
context, the soap fault will automatically be returned to the client. I dont
understand how do I stop further processing and return a soap fault to the
client.

So I did some further digging in to the axis code and found this function in
axiom_soap_envelope.h:

 AXIS2_EXTERN axiom_node_t* AXIS2_CALL
axiom_soap_envelope_get_base_node(axiom_soap_envelope_t *envelope,
constaxutil_env_t *env);


so this gives me access to the soap fault message as a axiom_node_t*. And
upon error in the 'add' operation, I just return it to the client. Is this
the right way to do it? I am missing something here.

Now one more important thing. When I call axiom_soap_envelope_get_base_node,
it seems to returning a soap1.2 fault message rather than a soap1.1 message
even though I set *

*soapVersion = AXIOM_SOAP11;

Why is that? Is there a way to get soap1.1 fault message?


I hope my questions are clear. Thanks so much for your help!


Subra



On 8/17/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
>
> Thanks Nandika. I will give it a shot.
>
> Have a good weekend!
>
> On 8/17/07, Nandika Jayawardana <[EMAIL PROTECTED] > wrote:
> >
> > Hi Subra,
> >
> > You can create a soap11 fault using following lines.
> >
> > int soap_version = AXIOM_SOAP11;
> >
> > soap_envelope = axiom_soap_envelope_create_default_soap_envelope (env,
> > soap_version);
> >
> > soap_body = axiom_soap_envelope_get_body(soap_envelope, env);
> >
> > soap_fault = axiom_soap_fault_create_default_fault (env,
> > soap_body, "fault code" , "fault reason"
> > , soap_version);
> >
> > axis2_msg_ctx_set_fault_soap_envelope(msg_ctx, env, soap_envelope);
> >
> > You can set the fault to the msg_ctx and it will be returned to the
> > client.
> >
> > Regards
> >
> > Nandika
> >
> >
> >
> > On 8/17/07, Subra A Narayanan <[EMAIL PROTECTED] > wrote:
> > >
> > > Hello folks,
> > >
> > > I am trying ti build a SOAP1.1 fault and return to the ws client. I am
> > > having some difficulty understanding how to go about this. I have tryng to
> > > dig through the source code but was wondering if you guys have some sample
> > > code. If you have it that would be very helpful in understanding the 
> > > usage.
> > >
> > > In the meantime I will continue to dig through the source code to try
> > > to understand.
> > >
> > > Thanks as usual!
> > >
> > > Subra
> > >
> >
> >
> >
> > --
> > [EMAIL PROTECTED]
> > WSO2 Inc: http://www.wso2.com
>
>
>


Re: SOAP fault builder

2007-08-17 Thread Subra A Narayanan
Thanks Nandika. I will give it a shot.

Have a good weekend!

On 8/17/07, Nandika Jayawardana <[EMAIL PROTECTED]> wrote:
>
> Hi Subra,
>
> You can create a soap11 fault using following lines.
>
> int soap_version = AXIOM_SOAP11;
>
> soap_envelope = axiom_soap_envelope_create_default_soap_envelope (env,
> soap_version);
>
> soap_body = axiom_soap_envelope_get_body(soap_envelope, env);
>
> soap_fault = axiom_soap_fault_create_default_fault (env, soap_body, "fault
> code" , "fault reason"
> , soap_version);
>
> axis2_msg_ctx_set_fault_soap_envelope(msg_ctx, env, soap_envelope);
>
> You can set the fault to the msg_ctx and it will be returned to the
> client.
>
> Regards
>
> Nandika
>
>
>
> On 8/17/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
> >
> > Hello folks,
> >
> > I am trying ti build a SOAP1.1 fault and return to the ws client. I am
> > having some difficulty understanding how to go about this. I have tryng to
> > dig through the source code but was wondering if you guys have some sample
> > code. If you have it that would be very helpful in understanding the usage.
> >
> > In the meantime I will continue to dig through the source code to try to
> > understand.
> >
> > Thanks as usual!
> >
> > Subra
> >
>
>
>
> --
> [EMAIL PROTECTED]
> WSO2 Inc: http://www.wso2.com


SOAP fault builder

2007-08-16 Thread Subra A Narayanan
Hello folks,

I am trying ti build a SOAP1.1 fault and return to the ws client. I am
having some difficulty understanding how to go about this. I have tryng to
dig through the source code but was wondering if you guys have some sample
code. If you have it that would be very helpful in understanding the usage.

In the meantime I will continue to dig through the source code to try to
understand.

Thanks as usual!

Subra


Re: axiom_data_handler_get_input_stream

2007-08-16 Thread Subra A Narayanan
Samisa,

Pls find attached the svn diff file.

Thanks!


On 8/16/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Just some additional comments:
> >
> > I think we definitely need the length function because there is no
> > other way of retrieving the length of the input stream as the
> > definition of the axiom_data_handler struct is in data_handler.c file
> > and not in axiom_data_handler.h file. So my question is, should the
> > declaration of the axiom_data_handler struct be moved to
> > axiom_data_handler.h file?
> >
> > I have made these simple changes to my local copy of the files. If you
> > want I can send it over to you guys and you can check it in after
> > reviewing the changes.
> Please do 'svn diff' and send the diff. I will have a look and committ in.
> BTW, the reason to have the struct in the C file was for data hiding
> purposes. We can add an accessor method, so that it would be in sync
> with the rest of the code.
>
> Thanks,
> Samisa...
> >
> > Thanks!!
> > Subra
> >
> > On 8/16/07, *Subra A Narayanan* <[EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>> wrote:
> >
> > Hello folks,
> >
> > I was looking at data_handler.c file and came across this function
> >
> >
> > AXIS2_EXTERN axis2_byte_t * AXIS2_CALL
> > axiom_data_handler_get_input_stream(axiom_data_handler_t
> > *data_handler,
> > const axutil_env_t *env)
> > {
> > return (axis2_byte_t *)"";
> > }
> >
> >
> > The above function always returns null. Should the above line be:
> >
> > return (axis2_byte_t *)data_handler->buffer;
> >
> >
> > Also, would it be useful to have a function called
> > axiom_data_handler_get_input_stream_len?
> >
> > Subra
> >
> >
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
Index: data_handler.c
===
--- data_handler.c  (revision 566723)
+++ data_handler.c  (working copy)
@@ -121,9 +121,16 @@
 axiom_data_handler_get_input_stream(axiom_data_handler_t *data_handler, 
 const axutil_env_t *env)
 {
-return (axis2_byte_t *)"";
+return (axis2_byte_t *)data_handler->buffer;
 }
 
+AXIS2_EXTERN int AXIS2_CALL
+axiom_data_handler_get_input_stream_len(axiom_data_handler_t *data_handler, 
+const axutil_env_t *env)
+{
+return data_handler->buffer_len;
+}
+
 AXIS2_EXTERN axis2_status_t AXIS2_CALL
 axiom_data_handler_read_from(axiom_data_handler_t *data_handler, 
 const axutil_env_t *env,
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Re: axiom_data_handler_get_input_stream

2007-08-16 Thread Subra A Narayanan
Just some additional comments:

I think we definitely need the length function because there is no other way
of retrieving the length of the input stream as the definition of the
axiom_data_handler struct is in data_handler.c file and not in
axiom_data_handler.h file. So my question is, should the declaration of the
axiom_data_handler struct be moved to axiom_data_handler.h file?

I have made these simple changes to my local copy of the files. If you want
I can send it over to you guys and you can check it in after reviewing the
changes.

Thanks!!
Subra

On 8/16/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
>
> Hello folks,
>
> I was looking at data_handler.c file and came across this function
>
>
> AXIS2_EXTERN axis2_byte_t * AXIS2_CALL
> axiom_data_handler_get_input_stream(axiom_data_handler_t *data_handler,
> const axutil_env_t *env)
> {
> return (axis2_byte_t *)"";
> }
>
>
> The above function always returns null. Should the above line be:
>
> return (axis2_byte_t *)data_handler->buffer;
>
>
> Also, would it be useful to have a function called 
> axiom_data_handler_get_input_stream_len?
>
>
> Subra
>


axiom_data_handler_get_input_stream

2007-08-16 Thread Subra A Narayanan
Hello folks,

I was looking at data_handler.c file and came across this function


AXIS2_EXTERN axis2_byte_t * AXIS2_CALL
axiom_data_handler_get_input_stream(axiom_data_handler_t *data_handler,
const axutil_env_t *env)
{
return (axis2_byte_t *)"";
}


The above function always returns null. Should the above line be:

 return (axis2_byte_t *)data_handler->buffer;


Also, would it be useful to have a function called
axiom_data_handler_get_input_stream_len?

Subra


Re: Large Attachment support in Axis2/C

2007-08-15 Thread Subra A Narayanan
Thanks Samisado let me know what you find out with your tests?

Also I created a JIRA issue requesting attachment caching support be added
to Axis2/C. Here is a lnk to the issue:

https://issues.apache.org/jira/browse/AXIS2C-672

Thanks!!


On 8/15/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Samisa,
> >
> > One more thing that I noticed today was that the web server where my
> > service is running becomes non-responsive when it is receiving an
> > attachment. I should let you know that for the time being, i am using
> > my laptop as the web server. i am running 64 bit linux using VM ware
> > virtual machine on windows xp professional. Is there any way I can
> > change axis2/apache settings so as to improve the performance?
> Are you running the apache server in debug mode with -X option? If yes,
> you may try the non-debug mode of apache. If not, it could be due to the
> fact that you are using VM ware. However, I will also test it with a
> large attachment and see if there is a problem. I have tested large
> attachments with simple axis server without much problem.
> >
> > Also is there any recommended limit on attachment size in Axis2/C
> > since caching is not available yet? I was easily able to transmit a
> > 3.5 MB file but when I tried a 5 MB file, the server recvd only a part
> > of the file about 2.8 MB.
> This needs further investigation. Let me have a look into this with the
> Apache module.
>
> Samisa...
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Large Attachment support in Axis2/C

2007-08-15 Thread Subra A Narayanan
Samisa,

One more thing that I noticed today was that the web server where my service
is running becomes non-responsive when it is receiving an attachment. I
should let you know that for the time being, i am using my laptop as the web
server. i am running 64 bit linux using VM ware virtual machine on windows
xp professional. Is there any way I can change axis2/apache settings so as
to improve the performance?

Also is there any recommended limit on attachment size in Axis2/C since
caching is not available yet? I was easily able to transmit a 3.5 MB file
but when I tried a 5 MB file, the server recvd only a part of the file about
2.8 MB.

Thanks so much for all the help.

Subra




On 8/15/07, Subra A Narayanan < [EMAIL PROTECTED]> wrote:
>
> Do you have an approximate idea as to when you will be implementing
> attachment caching support in Axis2/C? That would be a great feature to have
> and it will greatly help my development efforts. Do you want me to create a
> JIRA issue so that this gets prioritized?
>
> How do I tell if the client is using chunking or not? Just by looking at
> the HTTP headers? I will do that once I get to work today. My client is also
> written in Axis2/C. Is there a way to explicitly turn chunking on/off?
>
> TIA
> Subra
>
> On 8/14/07, Samisa Abeysinghe < [EMAIL PROTECTED]> wrote:
> >
> > Subra A Narayanan wrote:
> > > Hello folks,
> > >
> > > My webservice receives/sends attachments from/to clients using Axis2/C
> > > MTOM. Today we noticed that when a client was trying to send a 1.3 MB
> > > file, the server only received about 1/2 of it (around 760 KB)
> > There was a bug that we fond out yesterday with  chunked clients  where
> > the  size of the attachment was limited to 1MB.
> > Is your client using HTTP chinking? If yes, cold you turn that off and
> > see how it goes? Alternatively you can use the latest svn.
> > > I was reading the MTOM guide
> > >
> > > => http://ws.apache.org/axis2/1_2/mtom-guide.html#41
> > >
> > >
> > > Under advanced topics, it talks about  file caching for large files
> > > in Axis2/Java. Is similar kind of support  available in Axis2/C as
> > > well?  I looked at the axis2.xml file and there is nothing in there.
> > Axis2/C does not have caching support as yet. We would have to look into
> >
> > the details and implement it with Axis2/C MTOM model.
> >
> > Samisa...
> > >
> > > The application I am working on requires to support the sending and
> > > receiving of very large files.
> > >
> > > As usual thanks  for all the help!
> > >
> > >
> > > Subra
> >
> >
> > --
> > Samisa Abeysinghe : WSO2 WSF/C
> > "http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> >
> > <http://wso2.org/projects/wsf/c?WSO2%C2%A0Web%C2%A0Services%C2%A0Framework/C%C2%A0-%C2%A0Open%C2%A0source%C2%A0C%C2%A0library%C2%A0for%C2%A0providing%C2%A0and%C2%A0consuming%C2%A0Web%C2%A0services>
> > "
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>


Re: Large Attachment support in Axis2/C

2007-08-15 Thread Subra A Narayanan
Do you have an approximate idea as to when you will be implementing
attachment caching support in Axis2/C? That would be a great feature to have
and it will greatly help my development efforts. Do you want me to create a
JIRA issue so that this gets prioritized?

How do I tell if the client is using chunking or not? Just by looking at the
HTTP headers? I will do that once I get to work today. My client is also
written in Axis2/C. Is there a way to explicitly turn chunking on/off?

TIA
Subra

On 8/14/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hello folks,
> >
> > My webservice receives/sends attachments from/to clients using Axis2/C
> > MTOM. Today we noticed that when a client was trying to send a 1.3 MB
> > file, the server only received about 1/2 of it (around 760 KB)
> There was a bug that we fond out yesterday with  chunked clients  where
> the  size of the attachment was limited to 1MB.
> Is your client using HTTP chinking? If yes, cold you turn that off and
> see how it goes? Alternatively you can use the latest svn.
> > I was reading the MTOM guide
> >
> > => http://ws.apache.org/axis2/1_2/mtom-guide.html#41
> >
> >
> > Under advanced topics, it talks about  file caching for large files
> > in Axis2/Java. Is similar kind of support  available in Axis2/C as
> > well?  I looked at the axis2.xml file and there is nothing in there.
> Axis2/C does not have caching support as yet. We would have to look into
> the details and implement it with Axis2/C MTOM model.
>
> Samisa...
> >
> > The application I am working on requires to support the sending and
> > receiving of very large files.
> >
> > As usual thanks  for all the help!
> >
> >
> > Subra
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Large Attachment support in Axis2/C

2007-08-14 Thread Subra A Narayanan
Hello folks,

My webservice receives/sends attachments from/to clients using Axis2/C MTOM.
Today we noticed that when a client was trying to send a 1.3 MB file, the
server only received about 1/2 of it (around 760 KB)
I was reading the MTOM guide

=> http://ws.apache.org/axis2/1_2/mtom-guide.html#41


Under advanced topics, it talks about  file caching for large files  in
Axis2/Java. Is similar kind of support  available in Axis2/C as well?  I
looked at the axis2.xml file and there is nothing in there.

The application I am working on requires to support the sending and
receiving of very large files.

As usual thanks  for all the help!


Subra


Re: [Axis2/C]: SOAP request with line breaks fails

2007-08-14 Thread Subra A Narayanan
Samisa,

Good news. This morning, I built and installed Axis2/C from latest source
code on a different machine than I was using earlier. Now soap requests with
line breaks works fine.

I am thinking the earlier machine that I was using had some environment
issues.

Thanks a lot everyone for looking in to the issue!

Subra

On 8/13/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Samisa,
> >
> > Its still the same case. Request with line breaks fails, without the
> > line breaks works fine.
> > I started the simple axis server with gdb. I didnt get a backtrace at
> > all. See the text below
> hmmm. Looking at the gdb output, I cannot think of any possible reason
> why it is crashing.
>
> Would it be possible for you to send me the exact payload send by the
> client, including http headers (you can capture this using tcpmon Java
> tool)
> and send it to the list, so that I could try and replay it with the
> server and see what is going wrong on my machine.
>
> Also, I hope that you are using the latest svn head, if not, i plan to
> post an RC1 of 1.1 release today, so that you can try with that.
>
> Thanks,
> Samisa...
>
> >
> >
> > [EMAIL PROTECTED] bin]# gdb ./axis2_http_server
> > GNU gdb 6.3
> > Copyright 2004 Free Software Foundation, Inc.
> > GDB is free software, covered by the GNU General Public License, and
> > you are
> > welcome to change it and/or distribute copies of it under certain
> > conditions.
> > Type "show copying" to see the conditions.
> > There is absolutely no warranty for GDB.  Type "show warranty" for
> > details.
> > This GDB was configured as "x86_64-unknown-linux-gnu"...Using host
> > libthread_db library "/lib64/tls/libthread_db.so.1".
> >
> > (gdb) run -p 80
> > Starting program: /usr/local/axis2c/bin/axis2_http_server -p 80
> > AXIS2C_HOME is not set - log is written to . dir
> > Started Simple Axis2 HTTP Server ...
> >
> > Program terminated with signal SIGTRAP, Trace/breakpoint trap.
> > The program no longer exists.
> > (gdb) bt
> > No stack.
> > (gdb)
> >
> >
> >
> > This is my dev set up:
> >
> > 64 bit Linux
> > Axis2/C - server
> > Ruby Client
> >
> >
> > Subra
> >
> >
> >
> >
> > On 8/12/07, * Subra A Narayanan* <[EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>> wrote:
> >
> > Thanks Samisa..I will run axis http server with gdb and send u
> > the trace.
> >
> >
> >
> >
> > On 8/9/07, *Samisa Abeysinghe * < [EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>> wrote:
> >
> > Samisa Abeysinghe wrote:
> > > Subra A Narayanan wrote:
> > >> Hey Samisa,
> > >>
> > >> It still doesn't work. Anything else that I can do to solve
> this
> > >> problem?
> > > I tested it on my machine, with newlines in the payload, and
> > it works
> > > with the latest svn. I tested with a PHP client and echo
> > service.
> > > You seem to have tested with SOAP 1.1 in place. I am not sure
> > if this
> > > is related to SOAP version. I tested with SOAP 1.2, I will
> > test with
> > > SOAP 1.1 and let you know.
> > I tested with SOAP 1.1 as well, and it seems to work fine with
> > the
> > latest svn when there are newlines in the payload.
> > To help solve the problem, what you can do is to run Axis2/C
> > server with
> > gdb and send us the back trace of the crash point.
> >
> > Thanks,
> > Samisa...
> >
> > --
> > Samisa Abeysinghe :  > href="http://wso2.org/projects/wsf/c";>WSO2 Web Services
> > Framework/C - Open source C library for providing and
> > consuming Web services
> >
> >
> >
> -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail:
> > [EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>
> >
> >
> >
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Axiom Questions

2007-08-14 Thread Subra A Narayanan
Dumindu,

Thanks for the reply! I am going to try it out for myself but just wanted to
make sure that this was a no issue :-)

Thanks again!

Subra

On 8/14/07, Dumindu Pallewela <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hey Kaushalye,
> >
> > I noticed that ip_stream is of type axis2_byte_t. Looking at the
> > definition of axis2_byte_t in axutil_utils_defines.h, I realized that it
> > is nothing but a char. I am wondering if I read a part of a binary file
> > from disk using pread and store the read data in void *buffer and then
> > type cast the buffer in to a axis2_byte_t, if that will cause a problem?
>
> It should not. Because you give the length of the buffer alongside the
> buffer itself. FYI, the axiom_data_handler_set_binary_data function
> signature is as follows:
>
> axiom_data_handler_set_binary_data(
>  axiom_data_handler_t *data_handler,
>  const axutil_env_t *env,
>  axis2_byte_t* input_stream,
>  int input_stream_len)
>
>
> BTW, you could try this out and see for yourself ;)
>
> -Dumindu.
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Axiom Questions

2007-08-14 Thread Subra A Narayanan
Hey Kaushalye,

I noticed that ip_stream is of type axis2_byte_t. Looking at the definition
of axis2_byte_t in axutil_utils_defines.h, I realized that it is nothing but
a char. I am wondering if I read a part of a binary file from disk using
pread and store the read data in void *buffer and then type cast the buffer
in to a axis2_byte_t, if that will cause a problem?

Does my question make sense?

TIA
Subra

On 8/13/07, Kaushalye Kapuruge <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hey Samisa,
> >
> > With regards to my second question:
> >
> > I am not talking about reading part of the attachment. What I am
> > asking is can I read part of the file from the disk and attach it to
> > the message? 'axiom_data_handler_create' takes in a file name but no
> > offset. I can read a part of the file using pread, but but do I
> > convert the void *buff in to a data handler?
> Have you tried this?
> axiom_data_handler_set_binary_data(data_handler, env, ip_stream, len);
> First of all you'll have to keep you data(i.e. ip_stream) using
> axis2_byte_t*.
>
> Cheers,
> Kaushalye
> >
> > Subra
> >
> > On 8/13/07, *Samisa Abeysinghe* <[EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>> wrote:
> >
> > Subra A Narayanan wrote:
> > > Hello everyone,
> > >
> > > Its Monday morning and I am back with my questions. :-)
> > >
> > > Not sure if these questions belong here but will ask anyways.
> Please
> > > let me know if I should be sending this mail to some other
> > mailing list.
> > >
> > > I am using Axis2 and have 2 basic questions about Axiom. I did
> some
> > > searching on the web and tried looking through the Axis2/C
> > source code
> > > but don't have my answer. Here it goes:
> > >
> > > Q1) I have a web service with 4 operations. The first 3
> > parameters are
> > > the same for all the 4 operations. In other words, the first 3
> child
> > > elements inside the  > > Name> are the same for the 4 operations. So I created a
> > > function, called ReadFirst3Params which gets called from all the 4
>
> > > operations. Since, Axiom is based on a pull parser, I know I
> > have to
> > > have a reference to the 3rd parameter node to be able to read
> > the 4th
> > > parameter. Now my question is, do I need to return a reference
> > to the
> > > 3rd parameter node from my ReadFirst3Params function so that I can
> > > continue reading the other params in the operation.
> > Not really, one can read the rest of the OM tree the way they want,
> as
> > an example, using the qname (see
> > axiom_element_get_children_with_qname).
> >
> > > Or is there any other way of doing this. For e.g. an internal
> > pointer
> > > that Axiom maintains which will tell me the position with in the
> XML
> > > document. (I hope my question makes sense)
> > >
> > > Q2) One of the operation returns an attachment to the client as an
> > > mtom attachment. I use axiom_data_handler_create to read in the
> > binary
> > > file. I have a requirement to be able to read in a part of the
> file
> > > rather than the whole file. Just like pread function in 'C' where
> I
> > > can specify an offset and the file is read from the beginning to
> the
> > > offset. Is there a function in axiom to be able to do that? If
> not,
> > > how do I solve the above problem?
> > We do not have provision to read part of the attachment as of now.
> Is
> > there any way you can break the attachment to multiple parts and
> send
> > that in the SOAP message. If you can do that, then you can read
> > only the
> > first attachment and forget about the rest and pass it on, I hope.
> >
> > Samisa...
> > >
> > >
> > > Thanks again for ur help!
> > >
> > >
> > > Subra
> > >
> > >
> > >
> >
> >
> > --
> > Samisa Abeysinghe : WSO2 WSF/C
> > "
> > 
> > http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
>
> <http://wso2.org/projects/wsf/c?WSO2%C2%A0Web%C2%A0Services%C2%A0Framework/C%C2%A0-%C2%A0Open%C2%A0source%C2%A0C%C2%A0

Re: Axiom Questions

2007-08-13 Thread Subra A Narayanan
I think thats what I was looking for. I will try it out and let you know.

Thanks!!

On 8/13/07, Kaushalye Kapuruge <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hey Samisa,
> >
> > With regards to my second question:
> >
> > I am not talking about reading part of the attachment. What I am
> > asking is can I read part of the file from the disk and attach it to
> > the message? 'axiom_data_handler_create' takes in a file name but no
> > offset. I can read a part of the file using pread, but but do I
> > convert the void *buff in to a data handler?
> Have you tried this?
> axiom_data_handler_set_binary_data(data_handler, env, ip_stream, len);
> First of all you'll have to keep you data(i.e. ip_stream) using
> axis2_byte_t*.
>
> Cheers,
> Kaushalye
> >
> > Subra
> >
> > On 8/13/07, *Samisa Abeysinghe* <[EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>> wrote:
> >
> > Subra A Narayanan wrote:
> > > Hello everyone,
> > >
> > > Its Monday morning and I am back with my questions. :-)
> > >
> > > Not sure if these questions belong here but will ask anyways.
> Please
> > > let me know if I should be sending this mail to some other
> > mailing list.
> > >
> > > I am using Axis2 and have 2 basic questions about Axiom. I did
> some
> > > searching on the web and tried looking through the Axis2/C
> > source code
> > > but don't have my answer. Here it goes:
> > >
> > > Q1) I have a web service with 4 operations. The first 3
> > parameters are
> > > the same for all the 4 operations. In other words, the first 3
> child
> > > elements inside the  > > Name> are the same for the 4 operations. So I created a
> > > function, called ReadFirst3Params which gets called from all the 4
> > > operations. Since, Axiom is based on a pull parser, I know I
> > have to
> > > have a reference to the 3rd parameter node to be able to read
> > the 4th
> > > parameter. Now my question is, do I need to return a reference
> > to the
> > > 3rd parameter node from my ReadFirst3Params function so that I can
> > > continue reading the other params in the operation.
> > Not really, one can read the rest of the OM tree the way they want,
> as
> > an example, using the qname (see
> > axiom_element_get_children_with_qname).
> >
> > > Or is there any other way of doing this. For e.g. an internal
> > pointer
> > > that Axiom maintains which will tell me the position with in the
> XML
> > > document. (I hope my question makes sense)
> > >
> > > Q2) One of the operation returns an attachment to the client as an
> > > mtom attachment. I use axiom_data_handler_create to read in the
> > binary
> > > file. I have a requirement to be able to read in a part of the
> file
> > > rather than the whole file. Just like pread function in 'C' where
> I
> > > can specify an offset and the file is read from the beginning to
> the
> > > offset. Is there a function in axiom to be able to do that? If
> not,
> > > how do I solve the above problem?
> > We do not have provision to read part of the attachment as of now.
> Is
> > there any way you can break the attachment to multiple parts and
> send
> > that in the SOAP message. If you can do that, then you can read
> > only the
> > first attachment and forget about the rest and pass it on, I hope.
> >
> > Samisa...
> > >
> > >
> > > Thanks again for ur help!
> > >
> > >
> > > Subra
> > >
> > >
> > >
> >
> >
> > --
> > Samisa Abeysinghe : WSO2 WSF/C
> > "
> >
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> > <
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> >"
> >
> >
> >
> -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>
> >
> >
>
>
> --
> http://kaushalye.blogspot.com/
> http://wso2.org/
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: [Axis2/C]: SOAP request with line breaks fails

2007-08-13 Thread Subra A Narayanan
Samisa,

Its still the same case. Request with line breaks fails, without the line
breaks works fine.
I started the simple axis server with gdb. I didnt get a backtrace at all.
See the text below


[EMAIL PROTECTED] bin]# gdb ./axis2_http_server
GNU gdb 6.3
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "x86_64-unknown-linux-gnu"...Using host
libthread_db library "/lib64/tls/libthread_db.so.1".

(gdb) run -p 80
Starting program: /usr/local/axis2c/bin/axis2_http_server -p 80
AXIS2C_HOME is not set - log is written to . dir
Started Simple Axis2 HTTP Server ...

Program terminated with signal SIGTRAP, Trace/breakpoint trap.
The program no longer exists.
(gdb) bt
No stack.
(gdb)



This is my dev set up:

64 bit Linux
Axis2/C - server
Ruby Client


Subra




On 8/12/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
>
> Thanks Samisa..I will run axis http server with gdb and send u the
> trace.
>
>
>
> On 8/9/07, Samisa Abeysinghe < [EMAIL PROTECTED]> wrote:
> >
> > Samisa Abeysinghe wrote:
> > > Subra A Narayanan wrote:
> > >> Hey Samisa,
> > >>
> > >> It still doesn't work. Anything else that I can do to solve this
> > >> problem?
> > > I tested it on my machine, with newlines in the payload, and it works
> > > with the latest svn. I tested with a PHP client and echo service.
> > > You seem to have tested with SOAP 1.1 in place. I am not sure if this
> > > is related to SOAP version. I tested with SOAP 1.2, I will test with
> > > SOAP 1.1 and let you know.
> > I tested with SOAP 1.1 as well, and it seems to work fine with the
> > latest svn when there are newlines in the payload.
> > To help solve the problem, what you can do is to run Axis2/C server with
> > gdb and send us the back trace of the crash point.
> >
> > Thanks,
> > Samisa...
> >
> > --
> > Samisa Abeysinghe : http://wso2.org/projects/wsf/c";>WSO2 Web
> > Services Framework/C - Open source C library for providing and consuming Web
> > services
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>


Re: Axiom Questions

2007-08-13 Thread Subra A Narayanan
Hey Samisa,

With regards to my second question:

I am not talking about reading part of the attachment. What I am asking is
can I read part of the file from the disk and attach it to the message?
'axiom_data_handler_create' takes in a file name but no offset. I can read a
part of the file using pread, but but do I convert the void *buff in to a
data handler?

Subra

On 8/13/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hello everyone,
> >
> > Its Monday morning and I am back with my questions. :-)
> >
> > Not sure if these questions belong here but will ask anyways. Please
> > let me know if I should be sending this mail to some other mailing list.
> >
> > I am using Axis2 and have 2 basic questions about Axiom. I did some
> > searching on the web and tried looking through the Axis2/C source code
> > but don't have my answer. Here it goes:
> >
> > Q1) I have a web service with 4 operations. The first 3 parameters are
> > the same for all the 4 operations. In other words, the first 3 child
> > elements inside the  > Name> are the same for the 4 operations. So I created a
> > function, called ReadFirst3Params which gets called from all the 4
> > operations. Since, Axiom is based on a pull parser, I know I have to
> > have a reference to the 3rd parameter node to be able to read the 4th
> > parameter. Now my question is, do I need to return a reference to the
> > 3rd parameter node from my ReadFirst3Params function so that I can
> > continue reading the other params in the operation.
> Not really, one can read the rest of the OM tree the way they want, as
> an example, using the qname (see axiom_element_get_children_with_qname).
>
> > Or is there any other way of doing this. For e.g. an internal pointer
> > that Axiom maintains which will tell me the position with in the XML
> > document. (I hope my question makes sense)
> >
> > Q2) One of the operation returns an attachment to the client as an
> > mtom attachment. I use axiom_data_handler_create to read in the binary
> > file. I have a requirement to be able to read in a part of the file
> > rather than the whole file. Just like pread function in 'C' where I
> > can specify an offset and the file is read from the beginning to the
> > offset. Is there a function in axiom to be able to do that? If not,
> > how do I solve the above problem?
> We do not have provision to read part of the attachment as of now. Is
> there any way you can break the attachment to multiple parts and send
> that in the SOAP message. If you can do that, then you can read only the
> first attachment and forget about the rest and pass it on, I hope.
>
> Samisa...
> >
> >
> > Thanks again for ur help!
> >
> >
> > Subra
> >
> >
> >
>
>
> --
> Samisa Abeysinghe : WSO2 WSF/C
> "
> http://wso2.org/projects/wsf/c?WSO2 Web Services Framework/C - Open source C library for providing and consuming Web services
> "
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Axiom Questions

2007-08-12 Thread Subra A Narayanan
Hello everyone,

Its Monday morning and I am back with my questions. :-)

Not sure if these questions belong here but will ask anyways. Please let me
know if I should be sending this mail to some other mailing list.

I am using Axis2 and have 2 basic questions about Axiom. I did some
searching on the web and tried looking through the Axis2/C source code but
don't have my answer. Here it goes:

Q1) I have a web service with 4 operations. The first 3 parameters are the
same for all the 4 operations. In other words, the first 3 child elements
inside the  are the
same for the 4 operations. So I created a function, called ReadFirst3Params
which gets called from all the 4 operations. Since, Axiom is based on a pull
parser, I know I have to have a reference to the 3rd parameter node to be
able to read the 4th parameter. Now my question is, do I need to return a
reference to the 3rd parameter node from my ReadFirst3Params function so
that I can continue reading the other params in the operation. Or is there
any other way of doing this. For e.g. an internal pointer that Axiom
maintains which will tell me the position with in the XML document. (I hope
my question makes sense)

Q2) One of the operation returns an attachment to the client as an mtom
attachment. I use axiom_data_handler_create to read in the binary file. I
have a requirement to be able to read in a part of the file rather than the
whole file. Just like pread function in 'C' where I can specify an offset
and the file is read from the beginning to the offset. Is there a function
in axiom to be able to do that? If not, how do I solve the above problem?


Thanks again for ur help!


Subra


Re: [Axis2/C]: SOAP request with line breaks fails

2007-08-12 Thread Subra A Narayanan
Thanks Samisa..I will run axis http server with gdb and send u the
trace.



On 8/9/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Samisa Abeysinghe wrote:
> > Subra A Narayanan wrote:
> >> Hey Samisa,
> >>
> >> It still doesn't work. Anything else that I can do to solve this
> >> problem?
> > I tested it on my machine, with newlines in the payload, and it works
> > with the latest svn. I tested with a PHP client and echo service.
> > You seem to have tested with SOAP 1.1 in place. I am not sure if this
> > is related to SOAP version. I tested with SOAP 1.2, I will test with
> > SOAP 1.1 and let you know.
> I tested with SOAP 1.1 as well, and it seems to work fine with the
> latest svn when there are newlines in the payload.
> To help solve the problem, what you can do is to run Axis2/C server with
> gdb and send us the back trace of the crash point.
>
> Thanks,
> Samisa...
>
> --
> Samisa Abeysinghe : http://wso2.org/projects/wsf/c";>WSO2 Web
> Services Framework/C - Open source C library for providing and consuming Web
> services
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: [Axis2/C]: SOAP request with line breaks fails

2007-08-09 Thread Subra A Narayanan
Hey Samisa,

It still doesn't work. Anything else that I can do to solve this problem?

Initially I was using Ruby to write the client. But that doesn't work
because Ruby inserts line breaks in the SOAP msg. So for the time being I am
using Axis2/C for client code as well. But the consumers of my web service
might write client code in any language/platform and that will break my
server code.


Thanks!
Subra

On 8/8/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Samisa,
> >
> > Where should I run the distclean from? I mean which folder?
> >
> > My original installation was in /usr/local/axis2c. I deleted the whole
> > axis2c folder and built everything from scratch today. Do you think I
> > still need to run distclean and will that solve my problem?
> Nop, if you built everything from scratch, then you do not need to
> distclean.
> Usually, this kind of problems happen due to old libraries on your
> library path. If you have deleted all your all libraries, then it should
> work fine.
>
> Samisa...
>
> >
> > Pls let me know.
> >
> > Thanks so much.
> >
> >
> >
> > On 8/8/07, *Samisa Abeysinghe* <[EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>> wrote:
> >
> > Subra A Narayanan wrote:
> > > Hey Manjula,
> > >
> > > I got the latest source code from svn and built it. I am still
> > getting
> > > an error when there are line breaks in the incoming SOAP request.
> I
> > > did an svn update and this is what it tells me:
> > >
> > > [devwsserver:~/axis2c-svn/c]$ svn update
> > > At revision 563913.
> > This revision should be fine, the problem is solved before this
> > revision.
> >
> > Just try to clean up the whole system (make distclean) and build
> from
> > scratch and try.
> >
> > Samisa...
> >
> > --
> > Samisa Abeysinghe : http://www.wso2.org/ (WSO2 Oxygen Tank - Web
> > Services Developers' Portal)
> >
> >
> >
> -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > <mailto:[EMAIL PROTECTED]>
> >
> >
>
>
> --
> Samisa Abeysinghe : http://wso2.org/projects/wsf/c";>WSO2 Web
> Services Framework/C - Open source C library for providing and consuming Web
> services
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Service compilation problem

2007-08-09 Thread Subra A Narayanan
I followed ur suggestion and looked at the gcc command options as generated
by the make file. That solved the problem. Thanks!

On 8/7/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Thanks Samisa.
> >
> > I tried your solution and it worked for the 'math' sample.
> >
> > So I tried the same thing with my own web service, but that fails.
> > This is what I see in the axis2c log. The processing just stops after
> > this line ==> "class_loader.c(135) Object loaded successfully
> > " as you can see below. So I modified the make file that came with the
> > samples so that it now builds my own webservice too along with the
> > other sample web services. And that makes my web service work!!!
> > I have no idea whats going on here. Any help is greatly appreciated!
> What you can do is, when you run make, see the gcc commands run by make.
> Then you can see the compile options passed by make to gcc. If you copy
> those and run gcc with those options, then that would work.
>
> Samisa...
>
> --
> Samisa Abeysinghe : http://www.wso2.org/ (WSO2 Oxygen Tank - Web Services
> Developers' Portal)
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Unable to run client code

2007-08-09 Thread Subra A Narayanan
That was it! It works now.

Thanks!

On 8/8/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hello folks,
> >
> > I am trying to write a client using Axis2/C to connect to a Axis2/C
> > web service. These are the steps I followed
> >
> > 1. Created a wsdl file by hand for my web service.
> >
> > 2. Used the WSDL2C tool to generate the client stubs. Here is the
> > command I used
> >
> > java org.apache.axis2.wsdl.WSDL2C -D
> >
> org.apache.adb.properties=/org/apache/axis2/schema/c-schema-compile.properties
> > -uri myservice.wsdl -l c -d none
> >
> > 3. Added code to the generated .c file
> >
> > 4. Compiled the client code using the following command
> >
> > gcc -o hello_clnt -I /usr/local/axis2c/include/axis2-1.1/ -L
> > /usr/local/axis2c/lib/ -l axutil -l axis2_engine axis2_stub_myservice.c
> >
> > 5. Tried running the client and got this error
> >
> > ./hello_clnt: error while loading shared libraries: libaxutil.so.0:
> > cannot open shared object file: No such file or directory
> You probably need to add your Axis2/C lib folder to LD_LIBRARY_PATH
> environment variable.
> e.g. If you have installed Axis2/C to /usr/local/axis2c
> then you will find the .so files in /usr/local/axis2c/lib, hence you can
> use:
> export LD_LIBRARY_PATH=/usr/local/axis2c/lib:$LD_LIBRARY_PATH
>
> HTH
>
> Samisa...
>
> >
> >
> > What am I doing wrong? Am I missing any compiler options?
> >
> > Thank you everyone for the help!
> >
> >
> > Subra
>
>
> --
> Samisa Abeysinghe : http://www.wso2.org/ (WSO2 Oxygen Tank - Web Services
> Developers' Portal)
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: [Axis2/C]: SOAP request with line breaks fails

2007-08-08 Thread Subra A Narayanan
Samisa,

Where should I run the distclean from? I mean which folder?

My original installation was in /usr/local/axis2c. I deleted the whole
axis2c folder and built everything from scratch today. Do you think I still
need to run distclean and will that solve my problem?

Pls let me know.

Thanks so much.



On 8/8/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hey Manjula,
> >
> > I got the latest source code from svn and built it. I am still getting
> > an error when there are line breaks in the incoming SOAP request. I
> > did an svn update and this is what it tells me:
> >
> > [devwsserver:~/axis2c-svn/c]$ svn update
> > At revision 563913.
> This revision should be fine, the problem is solved before this revision.
>
> Just try to clean up the whole system (make distclean) and build from
> scratch and try.
>
> Samisa...
>
> --
> Samisa Abeysinghe : http://www.wso2.org/ (WSO2 Oxygen Tank - Web Services
> Developers' Portal)
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Unable to run client code

2007-08-08 Thread Subra A Narayanan
Hello folks,

I am trying to write a client using Axis2/C to connect to a Axis2/C web
service. These are the steps I followed

1. Created a wsdl file by hand for my web service.

2. Used the WSDL2C tool to generate the client stubs. Here is the command I
used

java org.apache.axis2.wsdl.WSDL2C -D
org.apache.adb.properties=/org/apache/axis2/schema/c-schema-compile.properties-uri
myservice.wsdl -l c -d none

3. Added code to the generated .c file

4. Compiled the client code using the following command

gcc -o hello_clnt -I /usr/local/axis2c/include/axis2-1.1/ -L
/usr/local/axis2c/lib/ -l axutil -l axis2_engine axis2_stub_myservice.c

5. Tried running the client and got this error

./hello_clnt: error while loading shared libraries: libaxutil.so.0: cannot
open shared object file: No such file or directory


What am I doing wrong? Am I missing any compiler options?

Thank you everyone for the help!


Subra


Re: [Axis2/C]: SOAP request with line breaks fails

2007-08-08 Thread Subra A Narayanan
Hey Manjula,

I got the latest source code from svn and built it. I am still getting an
error when there are line breaks in the incoming SOAP request. I did an svn
update and this is what it tells me:

[devwsserver:~/axis2c-svn/c]$ svn update
At revision 563913.

Was the bug fixed in the above mentioned revision or some other revision.

The server just hangs up when the request is received.

Sanjaya,

I installed the latest version of pkg-config and that solved my build
issues. Thanks!!

Subra


On 8/8/07, Sanjaya Ratnaweera <[EMAIL PROTECTED]> wrote:
>
>  Subra A Narayanan wrote:
>
> Hey Manjula,
>
> I checked out the latest source code from svn and built it.
>
> But when I try to build the samples, I get an error. Since there is no
> configue.sh file in the samples directory, I had to run the build.shscript 
> file. It dies half way through. This is the error I get
>
> ...
> ...
> checking for string.h... (cached) yes
> checking for an ANSI C-conforming const... yes
> ./configure: line 20467: syntax error near unexpected token `LIBXML2,'
> ./configure: line 20467: `PKG_CHECK_MODULES(LIBXML2, libxml-2.0)'
> make: *** No targets specified and no makefile found.  Stop.
> make: *** No rule to make target `install'.  Stop.
>
> Hi Subra,
>
> Can you please send your output to a file when you run build sh and
> attach it.
>
> ./build.sh > out 2>&1
>
> Because these details are not enough to identify the problem :-( Anyway
> you need following packages to build axis2/c
>
>   Autoconf 2.59 or higher
>   Automake 1.9 or higher
>   Aclocal 1.9 or higher
>   libtool 1.9 or higher
>   libxml2-dev
>   zlib1g-dev
>   pkg-config
>
> Thanks
>
>  ~sanjaya
>
>
>
>
> I would like to mention that when I tried building axis2/c from source, it
> complained about pkg-config version should be atleast 0.20 and I had 0.19.
> So I downloaded, built and installed pkg-config 0.22 version. It was
> installed in the /usr/local/bin directory as compared to version 0.19which 
> was installed in /usr/bin directory.
>
> Thanks for the help!
>
> Subra
>
>
> On 8/7/07, Manjula Peiris <[EMAIL PROTECTED]> wrote:
> >
> > Hi subra,
> >
> > This is a bug in Axis2/C 1.0. But it has been fixed after 1.0 and in the
> > current svn trunk it is working.
> >
> > -Manjula.
> >
> > On Mon, 2007-08-06 at 22:57 -0400, Subra A Narayanan wrote:
> > > Hey Samisa,
> > >
> > > I am using Axis2/C 1.0, source distribution on Linux. I compiled the
> > > source with the apache http module.
> > >
> > > Thanks for your follow-up abt my earlier issue. I will respond to that
> > > email separately so that someone following that thread will also
> > > benefit.
> > >
> > > Thanks again for ur quick response!
> > >
> > > Subra
> > >
> > > On 8/6/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
> > > What version of Axis2/C you are using? We had a problem like
> > > this, but
> > > if I remember right we have fixed it.
> > >
> > > BTW, have you been able to solve the service compilation
> > > problem that
> > > you discussed in the other thread?
> > >
> > > Samisa...
> > >
> > >
> > > Subra A Narayanan wrote:
> > > > Hello everyone,
> > > >
> > > > I found an interesting issue today and was wondering if
> > > someone else
> > > > has seen tha same issue before. I am using Axis2/C on Linux.
> > > >
> > > > I have a web service running. When the client tries calling
> > > the web
> > > > service using SOAP, the web service works if there are no
> > > line breaks
> > > > in the SOAP request. If there are any line breaks, the
> > > server just
> > > > crashes. So for eg
> > > >
> > > > ==> This works (SOAP msg with no line breaks)
> > > >
> > > > http://schemas.xmlsoap.org/soap/envelope/";>jordan
> > sircharles.gif1234
> >
> > > >
> > > >
> > > > ==> while this fails (formatted SOAP msg with line breaks)
> > > >
> > > > http://www.w3.org/2001/XMLSchema-instance";
> > > > xmlns:env="http://sche

Re: [Axis2/C]: SOAP request with line breaks fails

2007-08-07 Thread Subra A Narayanan
Hello all,

After I sent my first mail this afternoon, I thought of starting fresh and
building axis2/c from source again. So I deleted the axis2/c source
directory from my  file system, created a new directory, checked out latest
axis2/c code from svn and try building again. this time by axis2/c build
itself failed (as comapred to the samples build fail earlier) with a similar
error. Here it is



...
checking for sys/appleapiopts.h... no
checking whether to build libxml2 xml parser library... configure: line
21319: syntax error near unexpected token `PARSER,'
configure: line 21319: `PKG_CHECK_MODULES(PARSER, libxml-2.0)'


looks like it doesn't like something about PKG_CHECK_MODULES.

Any help is greatly appreciated.


Subra


On 8/7/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
>
> Hey Manjula,
>
> I checked out the latest source code from svn and built it.
>
> But when I try to build the samples, I get an error. Since there is no
> configue.sh file in the samples directory, I had to run the build.shscript 
> file. It dies half way through. This is the error I get
>
> ...
> ...
> checking for string.h... (cached) yes
> checking for an ANSI C-conforming const... yes
> ./configure: line 20467: syntax error near unexpected token `LIBXML2,'
> ./configure: line 20467: `PKG_CHECK_MODULES(LIBXML2, libxml-2.0)'
> make: *** No targets specified and no makefile found.  Stop.
> make: *** No rule to make target `install'.  Stop.
>
>
> I would like to mention that when I tried building axis2/c from source, it
> complained about pkg-config version should be atleast 0.20 and I had 0.19.
> So I downloaded, built and installed pkg-config 0.22 version. It was
> installed in the /usr/local/bin directory as compared to version 0.19which 
> was installed in /usr/bin directory.
>
> Thanks for the help!
>
> Subra
>
>
> On 8/7/07, Manjula Peiris <[EMAIL PROTECTED]> wrote:
> >
> > Hi subra,
> >
> > This is a bug in Axis2/C 1.0. But it has been fixed after 1.0 and in the
> > current svn trunk it is working.
> >
> > -Manjula.
> >
> > On Mon, 2007-08-06 at 22:57 -0400, Subra A Narayanan wrote:
> > > Hey Samisa,
> > >
> > > I am using Axis2/C 1.0, source distribution on Linux. I compiled the
> > > source with the apache http module.
> > >
> > > Thanks for your follow-up abt my earlier issue. I will respond to that
> > > email separately so that someone following that thread will also
> > > benefit.
> > >
> > > Thanks again for ur quick response!
> > >
> > > Subra
> > >
> > > On 8/6/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
> > > What version of Axis2/C you are using? We had a problem like
> > > this, but
> > > if I remember right we have fixed it.
> > >
> > > BTW, have you been able to solve the service compilation
> > > problem that
> > > you discussed in the other thread?
> > >
> > > Samisa...
> > >
> > >
> > > Subra A Narayanan wrote:
> > > > Hello everyone,
> > > >
> > > > I found an interesting issue today and was wondering if
> > > someone else
> > > > has seen tha same issue before. I am using Axis2/C on Linux.
> > > >
> > > > I have a web service running. When the client tries calling
> > > the web
> > > > service using SOAP, the web service works if there are no
> > > line breaks
> > > > in the SOAP request. If there are any line breaks, the
> > > server just
> > > > crashes. So for eg
> > > >
> > > > ==> This works (SOAP msg with no line breaks)
> > > >
> > > > http://schemas.xmlsoap.org/soap/envelope/";>jordan
> > sircharles.gif1234
> >
> > > >
> > > >
> > > > ==> while this fails (formatted SOAP msg with line breaks)
> > > >
> > > > http://www.w3.org/2001/XMLSchema-instance";
> > > > xmlns:env="http://schemas.xmlsoap.org/soap/envelope/";
> > > xmlns:xsd="
> > > > http://www.w3.org/2001/XMLSchema";>
> > > >   
> > > >   
> > > &

Re: [Axis2/C]: SOAP request with line breaks fails

2007-08-07 Thread Subra A Narayanan
Hey Manjula,

I checked out the latest source code from svn and built it.

But when I try to build the samples, I get an error. Since there is no
configue.sh file in the samples directory, I had to run the build.sh script
file. It dies half way through. This is the error I get

...
...
checking for string.h... (cached) yes
checking for an ANSI C-conforming const... yes
./configure: line 20467: syntax error near unexpected token `LIBXML2,'
./configure: line 20467: `PKG_CHECK_MODULES(LIBXML2, libxml-2.0)'
make: *** No targets specified and no makefile found.  Stop.
make: *** No rule to make target `install'.  Stop.


I would like to mention that when I tried building axis2/c from source, it
complained about pkg-config version should be atleast 0.20 and I had 0.19.
So I downloaded, built and installed pkg-config 0.22 version. It was
installed in the /usr/local/bin directory as compared to version 0.19 which
was installed in /usr/bin directory.

Thanks for the help!

Subra


On 8/7/07, Manjula Peiris <[EMAIL PROTECTED]> wrote:
>
> Hi subra,
>
> This is a bug in Axis2/C 1.0. But it has been fixed after 1.0 and in the
> current svn trunk it is working.
>
> -Manjula.
>
> On Mon, 2007-08-06 at 22:57 -0400, Subra A Narayanan wrote:
> > Hey Samisa,
> >
> > I am using Axis2/C 1.0, source distribution on Linux. I compiled the
> > source with the apache http module.
> >
> > Thanks for your follow-up abt my earlier issue. I will respond to that
> > email separately so that someone following that thread will also
> > benefit.
> >
> > Thanks again for ur quick response!
> >
> > Subra
> >
> > On 8/6/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
> > What version of Axis2/C you are using? We had a problem like
> > this, but
> > if I remember right we have fixed it.
> >
> > BTW, have you been able to solve the service compilation
> > problem that
> > you discussed in the other thread?
> >
> > Samisa...
> >
> >
> > Subra A Narayanan wrote:
> > > Hello everyone,
> > >
> > > I found an interesting issue today and was wondering if
> > someone else
> > > has seen tha same issue before. I am using Axis2/C on Linux.
> > >
> > > I have a web service running. When the client tries calling
> > the web
> > > service using SOAP, the web service works if there are no
> > line breaks
> > > in the SOAP request. If there are any line breaks, the
> > server just
> > > crashes. So for eg
> > >
> > > ==> This works (SOAP msg with no line breaks)
> > >
> > > http://schemas.xmlsoap.org/soap/envelope/";>jordan
> sircharles.gif
> 1234
> > >
> > >
> > > ==> while this fails (formatted SOAP msg with line breaks)
> > >
> > > http://www.w3.org/2001/XMLSchema-instance";
> > > xmlns:env="http://schemas.xmlsoap.org/soap/envelope/";
> > xmlns:xsd="
> > > http://www.w3.org/2001/XMLSchema";>
> > >   
> > >   
> > > http://www.xyz.com/2007/07/ ">
> > >   harry
> > >   del1.jpg 
> > >   checksum
> > > 
> > >   
> > > 
> > >
> > > ==>This is what I see in the axis2.log file
> > >
> > > [Mon Aug  6 13:59:22 2007] [debug] engine.c(571) Invoking
> > phase Dispatch
> > > [Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the
> > handler
> > > soap_message_body_based_dispatcher within the phase
> > Dispatch
> > > [Mon Aug  6 13:59:22 2007] [debug] soap_body_disp.c(217)
> > Checking for
> > > operation using SOAP message body's first child's local
> > name : RemoveFile
> > > [Mon Aug  6 13:59:22 2007] [debug] soap_body_disp.c(226)
> > Operation
> > > found using SOAP message body's first child's local name
> > > [Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the
> > handler
> > > addressing_based_dispatcher within the phase Dispatch
> > > [Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Inv

Re: Service compilation problem

2007-08-06 Thread Subra A Narayanan
Thanks Samisa.

I tried your solution and it worked for the 'math' sample.

So I tried the same thing with my own web service, but that fails. This is
what I see in the axis2c log. The processing just stops after this line ==>
"class_loader.c(135) Object loaded successfully
" as you can see below. So I modified the make file that came with the
samples so that it now builds my own webservice too along with the other
sample web services. And that makes my web service work!!!
I have no idea whats going on here. Any help is greatly appreciated!

[Mon Aug  6 23:13:33 2007] [debug] apache2_worker.c(143) Client HTTP version
HTTP/1.1
[Mon Aug  6 23:13:33 2007] [debug] req_uri_disp.c(103) Checking for service
using target endpoint address :
/axis2/services/object/RemoveFile?filetype=image×tamp=1234&filename=
psa.jpg
[Mon Aug  6 23:13:33 2007] [debug] req_uri_disp.c(124) Service found using
target endpoint address
[Mon Aug  6 23:13:33 2007] [debug] req_uri_disp.c(169) Checking for
operation using  target endpoint uri fragment :
RemoveFile
[Mon Aug  6 23:13:33 2007] [debug] req_uri_disp.c(178) Operation found using
target endpoint uri fragment
[Mon Aug  6 23:13:33 2007] [debug] engine.c(571) Invoking phase Transport
[Mon Aug  6 23:13:33 2007] [debug] phase.c(195) Invoke the handler
request_uri_based_dispatcher within the phase Transport
[Mon Aug  6 23:13:33 2007] [debug] engine.c(571) Invoking phase PreDispatch
[Mon Aug  6 23:13:33 2007] [debug] phase.c(195) Invoke the handler
AddressingInHandler within the phase PreDispatch
[Mon Aug  6 23:13:33 2007] [info]  Starting addressing in handler .
[Mon Aug  6 23:13:33 2007] [info]  addr_in_handler.c
[Mon Aug  6 23:13:33 2007] [debug] phase.c(195) Invoke the handler
LoggingInHandler within the phase PreDispatch
[Mon Aug  6 23:13:33 2007] [info]  Starting logging in handler .
[Mon Aug  6 23:13:33 2007] [info]  Input message: http://schemas.xmlsoap.org/soap/envelope/
">image1234
psa.jpg
[Mon Aug  6 23:13:33 2007] [debug] engine.c(571) Invoking phase Dispatch
[Mon Aug  6 23:13:33 2007] [debug] phase.c(195) Invoke the handler
soap_message_body_based_dispatcher within the phase Dispatch
[Mon Aug  6 23:13:33 2007] [debug] phase.c(195) Invoke the handler
addressing_based_dispatcher within the phase Dispatch
[Mon Aug  6 23:13:33 2007] [debug] phase.c(195) Invoke the handler
soap_action_based_dispatcher within the phase Dispatch
[Mon Aug  6 23:13:33 2007] [debug] engine.c(571) Invoking phase PostDispatch
[Mon Aug  6 23:13:33 2007] [debug] phase.c(195) Invoke the handler
dispatch_post_conditions_evaluator within the phase PostDispatch
[Mon Aug  6 23:13:33 2007] [debug] phase.c(195) Invoke the handler
context_handler within the phase PostDispatch
[Mon Aug  6 23:13:33 2007] [debug] class_loader.c(135) Object loaded
successfully





On 8/5/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
>
> > it doesn't work if I try to compile using these commands
> >
> > gcc -c -omath.o -I/usr/local/axis2c/include/axis2-1.0/
> > -L/usr/local/axis2c/lib -fPIC math.c
> > gcc -c -omath_skeleton.o -I/usr/local/axis2c/include/axis2-1.0/
> > -L/usr/local/axis2c/lib -fPIC math_skeleton.c
> > gcc -shared math.o math_skeleton.o -L/usr/local/axis2c/lib -laxis2
> > -olibmath.so
> In place of the last command, try using the following:
> gcc -shared math.o math_skeleton.o -ldl -lpthread  -olibmath.so
>
> Then copy the libmath.so to the services folder and try.
>
> Samisa...
>
> --
> Samisa Abeysinghe : http://www.wso2.org/ (WSO2 Oxygen Tank - Web Services
> Developers' Portal)
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: [Axis2/C]: SOAP request with line breaks fails

2007-08-06 Thread Subra A Narayanan
Hey Samisa,

I am using Axis2/C 1.0, source distribution on Linux. I compiled the source
with the apache http module.

Thanks for your follow-up abt my earlier issue. I will respond to that email
separately so that someone following that thread will also benefit.

Thanks again for ur quick response!

Subra

On 8/6/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> What version of Axis2/C you are using? We had a problem like this, but
> if I remember right we have fixed it.
>
> BTW, have you been able to solve the service compilation problem that
> you discussed in the other thread?
>
> Samisa...
>
>
> Subra A Narayanan wrote:
> > Hello everyone,
> >
> > I found an interesting issue today and was wondering if someone else
> > has seen tha same issue before. I am using Axis2/C on Linux.
> >
> > I have a web service running. When the client tries calling the web
> > service using SOAP, the web service works if there are no line breaks
> > in the SOAP request. If there are any line breaks, the server just
> > crashes. So for eg
> >
> > ==> This works (SOAP msg with no line breaks)
> >
> > http://schemas.xmlsoap.org/soap/envelope/
> ">jordan
> sircharles.gif
> 1234
> >
> >
> > ==> while this fails (formatted SOAP msg with line breaks)
> >
> > http://www.w3.org/2001/XMLSchema-instance";
> > xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"; xmlns:xsd="
> > http://www.w3.org/2001/XMLSchema";>
> >   
> >   
> > http://www.xyz.com/2007/07/ ">
> >   harry
> >   del1.jpg
> >   checksum
> > 
> >   
> > 
> >
> > ==>This is what I see in the axis2.log file
> >
> > [Mon Aug  6 13:59:22 2007] [debug] engine.c(571) Invoking phase Dispatch
> > [Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the handler
> > soap_message_body_based_dispatcher within the phase Dispatch
> > [Mon Aug  6 13:59:22 2007] [debug] soap_body_disp.c(217) Checking for
> > operation using SOAP message body's first child's local name :
> RemoveFile
> > [Mon Aug  6 13:59:22 2007] [debug] soap_body_disp.c(226) Operation
> > found using SOAP message body's first child's local name
> > [Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the handler
> > addressing_based_dispatcher within the phase Dispatch
> > [Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the handler
> > soap_action_based_dispatcher within the phase Dispatch
> > [Mon Aug  6 13:59:22 2007] [debug] engine.c(571) Invoking phase
> > PostDispatch
> > [Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the handler
> > dispatch_post_conditions_evaluator within the phase PostDispatch
> > [Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the handler
> > context_handler within the phase PostDispatch
> > [Mon Aug  6 13:59:22 2007] [debug] class_loader.c(135) Object loaded
> > successfully
> > [Mon Aug  6 13:59:23 2007] [info]  Starting log with log level 5
> >
> >
> > ==> so basically the server restarts after the "class_loader.c(135)
> > Object loaded successfully" step.
> >
> > The client code was written in Ruby. I dont know how I can tell Ruby
> > not to insert line breaks. But have you guys seen this issue before?
> > Do you know a solution to this problem?
> >
> > TIA
> > Subra
>
>
> --
> Samisa Abeysinghe : http://www.wso2.org/ (WSO2 Oxygen Tank - Web Services
> Developers' Portal)
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


[Axis2/C]: SOAP request with line breaks fails

2007-08-06 Thread Subra A Narayanan
Hello everyone,

I found an interesting issue today and was wondering if someone else has
seen tha same issue before. I am using Axis2/C on Linux.

I have a web service running. When the client tries calling the web service
using SOAP, the web service works if there are no line breaks in the SOAP
request. If there are any line breaks, the server just crashes. So for eg

==> This works (SOAP msg with no line breaks)

http://schemas.xmlsoap.org/soap/envelope/
">jordan
sircharles.gif
1234

==> while this fails (formatted SOAP msg with line breaks)

http://www.w3.org/2001/XMLSchema-instance";
xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"; xmlns:xsd="
http://www.w3.org/2001/XMLSchema";>
  
  
http://www.xyz.com/2007/07/";>
  harry
  del1.jpg
  checksum

  


==>This is what I see in the axis2.log file

[Mon Aug  6 13:59:22 2007] [debug] engine.c(571) Invoking phase Dispatch
[Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the handler
soap_message_body_based_dispatcher within the phase Dispatch
[Mon Aug  6 13:59:22 2007] [debug] soap_body_disp.c(217) Checking for
operation using SOAP message body's first child's local name : RemoveFile
[Mon Aug  6 13:59:22 2007] [debug] soap_body_disp.c(226) Operation found
using SOAP message body's first child's local name
[Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the handler
addressing_based_dispatcher within the phase Dispatch
[Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the handler
soap_action_based_dispatcher within the phase Dispatch
[Mon Aug  6 13:59:22 2007] [debug] engine.c(571) Invoking phase PostDispatch
[Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the handler
dispatch_post_conditions_evaluator within the phase PostDispatch
[Mon Aug  6 13:59:22 2007] [debug] phase.c(195) Invoke the handler
context_handler within the phase PostDispatch
[Mon Aug  6 13:59:22 2007] [debug] class_loader.c(135) Object loaded
successfully
[Mon Aug  6 13:59:23 2007] [info]  Starting log with log level 5


==> so basically the server restarts after the "class_loader.c(135) Object
loaded successfully" step.

The client code was written in Ruby. I dont know how I can tell Ruby not to
insert line breaks. But have you guys seen this issue before? Do you know a
solution to this problem?

TIA
Subra


Re: Service compilation problem

2007-08-05 Thread Subra A Narayanan
Hello Sahan,

I am not using the simple axis server but the apache HTTP server. I built
from axis2/c source and specified the correct option to build the apache
http server module.

my math service works if i use the following commands

./configure
make
make install

it doesn't work if I try to compile using these commands

gcc -c -omath.o -I/usr/local/axis2c/include/axis2-1.0/
-L/usr/local/axis2c/lib -fPIC math.c
gcc -c -omath_skeleton.o -I/usr/local/axis2c/include/axis2-1.0/
-L/usr/local/axis2c/lib -fPIC math_skeleton.c
gcc -shared math.o math_skeleton.o -L/usr/local/axis2c/lib -laxis2 -
olibmath.so


what am i doing wrong?

TIA
Subra


On 8/5/07, Sahan Gamage <[EMAIL PROTECTED]> wrote:
>
> Hi Subra,
>
> You're trying to do a REST style invocation. Are you running
> axis2_http_server on port 80 ? If you're trying the default options
> (by just typing ./axis2_http_server) the default port is 9090. So you
> have to try the URL:
> http://localhost:9090/axis2/services/math/add?param1=5¶m2=9
>
> -sahan
>
> On 8/6/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
> > I am still waiting to hear from you guys as to what you think is causing
> the
> > problem. Any help/pointers is greatly appreciated.
> >
> >
> > -- Forwarded message --
> > From: Subra A Narayanan <[EMAIL PROTECTED]>
> > Date: Aug 3, 2007 9:39 AM
> > Subject: Re: Service compilation problem
> > To: Apache AXIS C User List < axis-c-user@ws.apache.org>
> >
> > Hello,
> >
> > Thanks for all your responses.
> >
> > Sahan, I am using the same services.xml file that came with the math
> sample.
> >
> > Here is what I see
> >
> > 1. I type in
> > http://localhost/axis2/services/math/add?param1=5¶m2=9
> >
> >
> > 2. I get a "Page cannot be displayed" error in my web browser
> >
> > 3. In the log file I see this
> >
> > [Fri Aug  3 09:10:55 2007] [debug] apache2_worker.c(143)
> > Client HTTP version HTTP/1.1
> > [Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(103) Checking for
> service
> > using target endpoint address :
> > /axis2/services/math/add?param1=5¶m2=9
> > [Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(124) Service found
> using
> > target endpoint address
> > [Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(169) Checking for
> > operation using  target
> > endpoint uri fragment : add
> > [Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(178) Operation found
> using
> > target endpoint uri fragment
> > [Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase
> Transport
> > [Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
> > request_uri_based_dispatcher within the phase Transport
> > [Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase
> PreDispatch
> > [Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
> > AddressingInHandler within the phase PreDispatch
> > [Fri Aug  3 09:10:55 2007] [info]  Starting addressing in handler
> .
> > [Fri Aug  3 09:10:55 2007] [info]  addr_in_handler.c
> > [Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
> > LoggingInHandler within the phase PreDispatch
> > [Fri Aug  3 09:10:55 2007] [info]  Starting logging in handler .
>
> > [Fri Aug  3 09:10:55 2007] [info]  Input message:  > xmlns:soapenv="
> > http://schemas.xmlsoap.org/soap/envelope/";>59
> > >
> > [Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase Dispatch
> > [Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
> > soap_message_body_based_dispatcher within the phase
> > Dispatch
> > [Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
> > addressing_based_dispatcher within the phase Dispatch
> > [Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
> > soap_action_based_dispatcher within the phase Dispatch
> > [Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase
> PostDispatch
> > [Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
> > dispatch_post_conditions_evaluator within the phase
> > PostDispatch
> > [Fri Aug  3 09:10:55 2007] [debug] phase.c (195) Invoke the handler
> > context_handler within the phase PostDispatch
> >
> >
> > As you can see from the above log file, the server just hangs after
> "Invoke
> > the handler context_handler within the phase PostDispatch" step.
> >
> > I found a similar post in the archive, probabl

Re: Service compilation problem

2007-08-05 Thread Subra A Narayanan
I am still waiting to hear from you guys as to what you think is causing the
problem. Any help/pointers is greatly appreciated.

-- Forwarded message --
From: Subra A Narayanan <[EMAIL PROTECTED]>
Date: Aug 3, 2007 9:39 AM
Subject: Re: Service compilation problem
To: Apache AXIS C User List 

Hello,

Thanks for all your responses.

Sahan, I am using the same services.xml file that came with the math sample.

Here is what I see

1. I type in http://localhost/axis2/services/math/add?param1=5¶m2=9

2. I get a "Page cannot be displayed" error in my web browser

3. In the log file I see this

[Fri Aug  3 09:10:55 2007] [debug] apache2_worker.c(143) Client HTTP version
HTTP/1.1
[Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(103) Checking for service
using target endpoint address : /axis2/services/math/add?param1=5¶m2=9
[Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(124) Service found using
target endpoint address
[Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(169) Checking for
operation using  target endpoint uri fragment :
add
[Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(178) Operation found using
target endpoint uri fragment
[Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase Transport
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
request_uri_based_dispatcher within the phase Transport
[Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase PreDispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
AddressingInHandler within the phase PreDispatch
[Fri Aug  3 09:10:55 2007] [info]  Starting addressing in handler .
[Fri Aug  3 09:10:55 2007] [info]  addr_in_handler.c
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
LoggingInHandler within the phase PreDispatch
[Fri Aug  3 09:10:55 2007] [info]  Starting logging in handler .
[Fri Aug  3 09:10:55 2007] [info]  Input message: http://schemas.xmlsoap.org/soap/envelope/";>59
[Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase Dispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
soap_message_body_based_dispatcher within the phase Dispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
addressing_based_dispatcher within the phase Dispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
soap_action_based_dispatcher within the phase Dispatch
[Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase PostDispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
dispatch_post_conditions_evaluator within the phase PostDispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c (195) Invoke the handler
context_handler within the phase PostDispatch


As you can see from the above log file, the server just hangs after "Invoke
the handler context_handler within the phase PostDispatch" step.

I found a similar post in the archive, probably this will give you guys more
idea as to what is happening.

http://marc.info/?l=axis-c-user&m=118125285316252&w=2

Thanks everyone for ur help. Its greatly appreciated.

Subra






On 8/3/07, Dr. Florian Steinborn <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> > I see a libmath.so file being generated. But my service doesn't work. I
>
> what does it mean, "doesn't work"? Does not work at all, you cannot see an
>
> invocation, the service crashes? What about logging?
>
> Greeting,
> Flori
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Service compilation problem

2007-08-03 Thread Subra A Narayanan
Hello,

Thanks for all your responses.

Sahan, I am using the same services.xml file that came with the math sample.

Here is what I see

1. I type in http://localhost/axis2/services/math/add?param1=5¶m2=9

2. I get a "Page cannot be displayed" error in my web browser

3. In the log file I see this

[Fri Aug  3 09:10:55 2007] [debug] apache2_worker.c(143) Client HTTP version
HTTP/1.1
[Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(103) Checking for service
using target endpoint address : /axis2/services/math/add?param1=5¶m2=9
[Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(124) Service found using
target endpoint address
[Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(169) Checking for
operation using  target endpoint uri fragment :
add
[Fri Aug  3 09:10:55 2007] [debug] req_uri_disp.c(178) Operation found using
target endpoint uri fragment
[Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase Transport
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
request_uri_based_dispatcher within the phase Transport
[Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase PreDispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
AddressingInHandler within the phase PreDispatch
[Fri Aug  3 09:10:55 2007] [info]  Starting addressing in handler .
[Fri Aug  3 09:10:55 2007] [info]  addr_in_handler.c
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
LoggingInHandler within the phase PreDispatch
[Fri Aug  3 09:10:55 2007] [info]  Starting logging in handler .
[Fri Aug  3 09:10:55 2007] [info]  Input message: http://schemas.xmlsoap.org/soap/envelope/";>59
[Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase Dispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
soap_message_body_based_dispatcher within the phase Dispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
addressing_based_dispatcher within the phase Dispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
soap_action_based_dispatcher within the phase Dispatch
[Fri Aug  3 09:10:55 2007] [debug] engine.c(571) Invoking phase PostDispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
dispatch_post_conditions_evaluator within the phase PostDispatch
[Fri Aug  3 09:10:55 2007] [debug] phase.c(195) Invoke the handler
context_handler within the phase PostDispatch


As you can see from the above log file, the server just hangs after "Invoke
the handler context_handler within the phase PostDispatch" step.

I found a similar post in the archive, probably this will give you guys more
idea as to what is happening.

http://marc.info/?l=axis-c-user&m=118125285316252&w=2

Thanks everyone for ur help. Its greatly appreciated.

Subra






On 8/3/07, Dr. Florian Steinborn <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> > I see a libmath.so file being generated. But my service doesn't work. I
>
> what does it mean, "doesn't work"? Does not work at all, you cannot see an
> invocation, the service crashes? What about logging?
>
> Greeting,
> Flori
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Service compilation problem

2007-08-02 Thread Subra A Narayanan
Hello folks,

I am trying to compile the 'math' service from the samples directory without
using the make file provided with the samples. I used the instructions from
the Axic2/C manual (http://ws.apache.org/axis2/c/docs/axis2c_manual.html)

I used the following commands to compile:

gcc -c -omath.o -I/usr/local/axis2c/include/axis2-1.0/
-L/usr/local/axis2c/lib -fPIC math.c
gcc -c -omath_skeleton.o -I/usr/local/axis2c/include/axis2-1.0/
-L/usr/local/axis2c/lib -fPIC math_skeleton.c
gcc -shared math.o math_skeleton.o -L/usr/local/axis2c/lib -laxis2 -
olibmath.so


I see a libmath.so file being generated. But my service doesn't work. I do
realize that the above commands do not generate the following files which
are generated if I use the make file:

libmath.a
libmath.la
libmath.so.0
libmath.so.0.0.0


What am I doing wrong? I am trying this so that I can compile my own web
services without having to rely on the make file. I have written my web
service but I cannot test it as I am stuck at this point.

Any help or pointers in the right direction would be greatly helpful.

TIA

Subra


Re: Generating WSDL for a Axcis2/C Web service

2007-08-02 Thread Subra A Narayanan
That worked!!! Thanks!!

On 8/2/07, Mark Nüßler <[EMAIL PROTECTED]> wrote:
>
> hello Subra,
>
> set the parameter in the services.xml
>
>  name="wsdl_path">X:/ws/axis2_c/services/mtom/mtom.wsdl
>
> then you kann retrieve the wsdl with your broser :
>
> http://localhost:8081/axis2/services/mtom?wsdl
>
> mfg derMark
>
>
>
> Subra A Narayanan schrieb:
> > Hey Samisa,
> >
> > I dug through the axis2c source code and found that I should be naming
> my
> > wsdl file service.wsdl and place it in the 'myservice' sub directory
> under
> > services directory (basically the same directory as the services.xmlfile).
> >
> > Even that doesn't work? What am I doing wrong? Do I need to set
> 'wsdl_path'
> > to something in my services.xml file?
> >
> > Thanks a lot for ur help!
> >
> >
> > On 8/2/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
> >> Hey Samisa,
> >>
> >> I created the wsdl for my service by hand. Where exactly are we
> supposed
> >> to place it and what exactly should it be named?
> >>
> >> I named it mywebservicename.wsdl and placed it in the services
> directory.
> >> that didnt work.
> >> i placed it in the mywebservicename folder under services diretory,
> that
> >> didnt work either.
> >>
> >> do i hv to create a wsdls folder somewhere and place it there?
> >>
> >> ur help is greatly appreciated.
> >>
> >> Subra
> >>
> >>
> >>  On 7/30/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
> >>> Subra A Narayanan wrote:
> >>>> Hello,
> >>>>
> >>>> How do I generate a wsdl for a Axis2/C web service. I
> >>>> tried http://192.168.0.102/axis2/services/echo?wsdl but it gives me
> >>>> the following error
> >>> We do not have WSDL serving implemented in Axis2/C. However, if you
> have
> >>>
> >>> the WSDL, you can host it along with the service in services folder to
> >>> be served for ?wsdl requests.
> >>>
> >>> Samisa...
> >>>
> >>> --
> >>> Samisa Abeysinghe : http://www.wso2.org/ (WSO2 Oxygen Tank - Web
> >>> Services Developers' Portal)
> >>>
> >>>
> >>> -
> >>> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >>> For additional commands, e-mail: [EMAIL PROTECTED]
> >>>
> >>>
> >
> >
> > 
> >
> > No virus found in this incoming message.
> > Checked by AVG Free Edition.
> > Version: 7.5.476 / Virus Database: 269.11.2/931 - Release Date:
> 01.08.2007 16:53
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Re: Generating WSDL for a Axcis2/C Web service

2007-08-02 Thread Subra A Narayanan
Hey Samisa,

I dug through the axis2c source code and found that I should be naming my
wsdl file service.wsdl and place it in the 'myservice' sub directory under
services directory (basically the same directory as the services.xml file).

Even that doesn't work? What am I doing wrong? Do I need to set 'wsdl_path'
to something in my services.xml file?

Thanks a lot for ur help!


On 8/2/07, Subra A Narayanan <[EMAIL PROTECTED]> wrote:
>
> Hey Samisa,
>
> I created the wsdl for my service by hand. Where exactly are we supposed
> to place it and what exactly should it be named?
>
> I named it mywebservicename.wsdl and placed it in the services directory.
> that didnt work.
> i placed it in the mywebservicename folder under services diretory, that
> didnt work either.
>
> do i hv to create a wsdls folder somewhere and place it there?
>
> ur help is greatly appreciated.
>
> Subra
>
>
>  On 7/30/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
> >
> > Subra A Narayanan wrote:
> > > Hello,
> > >
> > > How do I generate a wsdl for a Axis2/C web service. I
> > > tried http://192.168.0.102/axis2/services/echo?wsdl but it gives me
> > > the following error
> > We do not have WSDL serving implemented in Axis2/C. However, if you have
> >
> > the WSDL, you can host it along with the service in services folder to
> > be served for ?wsdl requests.
> >
> > Samisa...
> >
> > --
> > Samisa Abeysinghe : http://www.wso2.org/ (WSO2 Oxygen Tank - Web
> > Services Developers' Portal)
> >
> >
> > -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>


Re: Generating WSDL for a Axcis2/C Web service

2007-08-02 Thread Subra A Narayanan
Hey Samisa,

I created the wsdl for my service by hand. Where exactly are we supposed to
place it and what exactly should it be named?

I named it mywebservicename.wsdl and placed it in the services directory.
that didnt work.
i placed it in the mywebservicename folder under services diretory, that
didnt work either.

do i hv to create a wsdls folder somewhere and place it there?

ur help is greatly appreciated.

Subra


On 7/30/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hello,
> >
> > How do I generate a wsdl for a Axis2/C web service. I
> > tried http://192.168.0.102/axis2/services/echo?wsdl but it gives me
> > the following error
> We do not have WSDL serving implemented in Axis2/C. However, if you have
> the WSDL, you can host it along with the service in services folder to
> be served for ?wsdl requests.
>
> Samisa...
>
> --
> Samisa Abeysinghe : http://www.wso2.org/ (WSO2 Oxygen Tank - Web Services
> Developers' Portal)
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Fwd: [Axis2/C] Attachments in Axis2/C

2007-07-30 Thread Subra A Narayanan
Hello Samisa,

Any input from ur side abt the issue described below would be greatly
appreciated.

Subra

-- Forwarded message --
From: Subra A Narayanan <[EMAIL PROTECTED]>
Date: Jul 26, 2007 10:22 PM
Subject: Re: [Axis2/C] Attachments in Axis2/C
To: Apache AXIS C User List 

Hello Samisa,

Thanks for the quick reply. Your answers are helping me understand whats
doable and whats not.

One of the requirements for the project that I am working on is that we have
to let the clients make REST calls to our web service.

Having said that, one more clarification. Pls tell me if this is
theoretically possible to achieve in Axis2/C. And I apologize in advance if
what I am saying doesn't make much sense:

--> I will have a Axis2/C web service with REST enabled.
--> A non Axis2/C client would make a REST (HTTP POST) call to this web
service with a MIME attachment (along with some other parameters that tell
the WS what to do with the attachment).
--> Axis2/C framework on the server side delivers this request to the server
code as a SOAP message.
--> The code retrieves the attachment and the other parameters, processes
the request and returns a response.

Please let me know if what I said makes sense and if its doable.

Thanks a lot for your help!!

Subra



On 7/26/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hello folks,
> >
> > Another newbie question:
> >
> > From what I understand, when a web service is called in a RESTful way,
> > Axis2/C framework intercepts and automatically puts the parameters in
> > a SOAP envelop before delivering it to the web service code. This
> > means that a as far as the WS code goes, all client calls are SOAP
> calls.
> >
> > Now MTOM is specifically for SOAP. So how can a Axis2/C web service
> > which is called my lets say a .Net client in a RESTful way, make use
> > of MTOM since as far as the client goes, there is no SOAP involved.
> >
> If the client wants to do MTOM with server, then the client got to use
> SOAP, because MTOM is for SOAP anyway.
> You cannot do MTOM with REST.
> > How do we handle attachments in such cases on the client side and
> > server side? Any simple server side example would be much appreciated.
> I am not sure how REST deals with attachments. Axis2/C currently only
> supports the MTOM way of attachments. Hence there is no way as of now
> that you can make a REST client access attachments with an Axis2/C
> service doing MTOM.
>
> Samisa...
> >
> > Subra
>
>
> --
> Samisa Abeysinghe : http://www.wso2.org/ (WSO2 Oxygen Tank - Web Services
> Developers' Portal)
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


Generating WSDL for a Axcis2/C Web service

2007-07-27 Thread Subra A Narayanan
Hello,

How do I generate a wsdl for a Axis2/C web service. I tried
http://192.168.0.102/axis2/services/echo?wsdl but it gives me the following
error


The XML page cannot be displayed

Cannot view XML input using style sheet. Please correct the error and then
click the Refresh  button, or try again later.

--

Invalid at the top level of the document. Error processing resource '
http://192.168.0.102/axis2/services/echo?wsdl'. Line 1...

Unable to retreive wsdl for this service
^


 I get the above error for all the sample web services.

Any pointers in the right direction would be much appreciated.

Subra


Re: [Axis2/C] Attachments in Axis2/C

2007-07-26 Thread Subra A Narayanan
Hello Samisa,

Thanks for the quick reply. Your answers are helping me understand whats
doable and whats not.

One of the requirements for the project that I am working on is that we have
to let the clients make REST calls to our web service.

Having said that, one more clarification. Pls tell me if this is
theoretically possible to achieve in Axis2/C. And I apologize in advance if
what I am saying doesn't make much sense:

--> I will have a Axis2/C web service with REST enabled.
--> A non Axis2/C client would make a REST (HTTP POST) call to this web
service with a MIME attachment (along with some other parameters that tell
the WS what to do with the attachment).
--> Axis2/C framework on the server side delivers this request to the server
code as a SOAP message.
--> The code retrieves the attachment and the other parameters, processes
the request and returns a response.

Please let me know if what I said makes sense and if its doable.

Thanks a lot for your help!!

Subra


On 7/26/07, Samisa Abeysinghe <[EMAIL PROTECTED]> wrote:
>
> Subra A Narayanan wrote:
> > Hello folks,
> >
> > Another newbie question:
> >
> > From what I understand, when a web service is called in a RESTful way,
> > Axis2/C framework intercepts and automatically puts the parameters in
> > a SOAP envelop before delivering it to the web service code. This
> > means that a as far as the WS code goes, all client calls are SOAP
> calls.
> >
> > Now MTOM is specifically for SOAP. So how can a Axis2/C web service
> > which is called my lets say a .Net client in a RESTful way, make use
> > of MTOM since as far as the client goes, there is no SOAP involved.
> >
> If the client wants to do MTOM with server, then the client got to use
> SOAP, because MTOM is for SOAP anyway.
> You cannot do MTOM with REST.
> > How do we handle attachments in such cases on the client side and
> > server side? Any simple server side example would be much appreciated.
> I am not sure how REST deals with attachments. Axis2/C currently only
> supports the MTOM way of attachments. Hence there is no way as of now
> that you can make a REST client access attachments with an Axis2/C
> service doing MTOM.
>
> Samisa...
> >
> > Subra
>
>
> --
> Samisa Abeysinghe : http://www.wso2.org/ (WSO2 Oxygen Tank - Web Services
> Developers' Portal)
>
>
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


  1   2   >