Start/Stop Axis2 web services contexts
Hi folks, I have deployed three different web services all of them implemented using Axis2 in the same Tomcat Axis2 container. What I need is to be able to start/stop one of those web services on demand without affecting the others. I have checked my Tomcat Manager web page at: http://sess-mission2.deimos-space.com:8080/manager/html And I have seen there that suing the following urls I can stop/start the whole Axis2 context: http://localhost:8080/manager/html/start?path=/axis2 http://localhost:8080/manager/html/stop?path=/axis2 But this will stop all my web services running in Axis2 container... If you deploy a web service into Tomcat as a *.war file the you can start/stop it directly and the other web services running are not affected, can this be done with Axis2 web services deployed as *.aar files?
Axis2 timeouts configuration
Hi folks! I have implemented an Axis2 web service to retrieve some publication data stored remotely in a web server. I have done some tests and everything runs well but I have noticed that if I do several consecutive calls to the web service I receive Timeouts responses in the client side and I see that Axis exception in my log files. Is there any way to configure the timeout response in my web service? Or that timeout should be configured in the Client-side? thank you, Mh
Re: Axis2 timeouts configuration
Hi again, I am getting the following exception: org.apache.axis2.AxisFault: Read timed out I have generated the Client-side stub classes to connect with my web service using the wsdl2java Tool, in which class of the Client-side stub should i set this options.setTimeOutInMilliSeconds(60); code? In the Skeleton one? Also, is possible to configure the timeout in the server side using the axsi2.xml paremeter ConfigContextTimeoutInterval? The default value for Axis2 web services timeout is 60 seconds, isn't it? thank you, Mh 2009/9/16 Chinmoy Chakraborty cch...@gmail.com what exception you are getting? can you share your log? yes you can configure timeout in the client side..like options.setTimeOutInMilliSeconds(60); On Wed, Sep 16, 2009 at 2:12 PM, Moley Harey moleyha...@gmail.com wrote: Hi folks! I have implemented an Axis2 web service to retrieve some publication data stored remotely in a web server. I have done some tests and everything runs well but I have noticed that if I do several consecutive calls to the web service I receive Timeouts responses in the client side and I see that Axis exception in my log files. Is there any way to configure the timeout response in my web service? Or that timeout should be configured in the Client-side? thank you, Mh
Re: Axis2 timeouts configuration
Hi, yes here is the error trace in the server side: org.apache.axis2.AxisFault at org.apache.axis2.AxisFault.makeFault(AxisFault.java:430) at org.apache.axis2.transport.http.SOAPMessageFormatter.writeTo(SOAPMessageFormatter.java:83) at org.apache.axis2.transport.http.CommonsHTTPTransportSender.sendUsingOutputStream(CommonsHTTPTransportSender.java:337) at org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:214) at org.apache.axis2.engine.AxisEngine.sendFault(AxisEngine.java:530) at org.apache.axis2.transport.http.AxisServlet.handleFault(AxisServlet.java:416) at org.apache.axis2.transport.http.AxisServlet.processAxisFault(AxisServlet.java:379) at org.apache.axis2.transport.http.AxisServlet.doPost(AxisServlet.java:167) at javax.servlet.http.HttpServlet.service(HttpServlet.java:637) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447) at java.lang.Thread.run(Thread.java:619) Caused by: com.ctc.wstx.exc.WstxIOException: null at com.ctc.wstx.sw.BaseStreamWriter.flush(BaseStreamWriter.java:313) at org.apache.axiom.om.impl.MTOMXMLStreamWriter.flush(MTOMXMLStreamWriter.java:146) at org.apache.axiom.om.impl.llom.OMNodeImpl.serializeAndConsume(OMNodeImpl.java:472) at org.apache.axis2.transport.http.SOAPMessageFormatter.writeTo(SOAPMessageFormatter.java:79) ... 20 more Caused by: ClientAbortException: java.net.SocketException: Broken pipe at org.apache.catalina.connector.OutputBuffer.doFlush(OutputBuffer.java:319) at org.apache.catalina.connector.OutputBuffer.flush(OutputBuffer.java:288) at org.apache.catalina.connector.CoyoteOutputStream.flush(CoyoteOutputStream.java:98) at com.ctc.wstx.io.UTF8Writer.flush(UTF8Writer.java:99) at com.ctc.wstx.sw.BufferingXmlWriter.flush(BufferingXmlWriter.java:214) at com.ctc.wstx.sw.BaseStreamWriter.flush(BaseStreamWriter.java:311) 2009/9/16 Chinmoy Chakraborty cch...@gmail.com do you have any exception in the server side? send me the complete stack trace...you can also put a breakpoint and debug... On Wed, Sep 16, 2009 at 3:24 PM, Moley Harey moleyha...@gmail.com wrote: Hi again, I am getting the following exception: org.apache.axis2.AxisFault: Read timed out I have generated the Client-side stub classes to connect with my web service using the wsdl2java Tool, in which class of the Client-side stub should i set this options.setTimeOutInMilliSeconds(60); code? In the Skeleton one? Also, is possible to configure the timeout in the server side using the axsi2.xml paremeter ConfigContextTimeoutInterval? The default value for Axis2 web services timeout is 60 seconds, isn't it? thank you, Mh 2009/9/16 Chinmoy Chakraborty cch...@gmail.com what exception you are getting? can you share your log? yes you can configure timeout in the client side..like options.setTimeOutInMilliSeconds(60); On Wed, Sep 16, 2009 at 2:12 PM, Moley Harey moleyha...@gmail.comwrote: Hi folks! I have implemented an Axis2 web service to retrieve some publication data stored remotely in a web server. I have done some tests and everything runs well but I have noticed that if I do several consecutive calls to the web service I receive Timeouts responses in the client side and I see that Axis exception in my log files. Is there any way to configure the timeout response in my web service? Or that timeout should be configured in the Client-side? thank you, Mh
Re: Accessing a Java Axis2 web service from C++ code
Thanks a lot Amila, I am going to check that!! 2009/9/1 Amila Suriarachchi amilasuriarach...@gmail.com On Tue, Sep 1, 2009 at 1:43 PM, Moley Harey moleyha...@gmail.com wrote: Hi folks, I have implemented an Axis2 web service in Java and I need to access its public methods from a C++ code. When I generate the Axis2 web service I generate too a client.jar library that is used as the interface to access the Java Web Service from other Java classes that just have to import that library, but from C++ how can I do that? Do I have to implement a JNI interface with the client.jar classes to do that? Has anyone tried to access a Java Axis2 web service using C++? Any examples? you can try with wsfcpp[1] using wsdl2cpp tool. thanks, Amila. [1] http://wso2.org/projects/wsf/cpp Thanks in advance, Mh -- Amila Suriarachchi WSO2 Inc. blog: http://amilachinthaka.blogspot.com/
Best way to load a configuration file in Axis2?
Hi, I am implementing a web service using Axis2 that can be tunned using several configuration parameters. My web service is deployed as *.aar file into the axis2/WEB-INF/services folder. I have done a separate XML configuration file that store those parameters, my idea was to include the configuration file into de final *.aar file and then try to load that configuration file in my code without the need to specify the full path on disk where it is placed. Is is possible to do this in Axis2? Can I use some kind of ServiceContext to do this? Thanks in advance, Mh
Is better to deploy my services into Axis2 container?
Hi folks, I have several Axis2-based web services that perform different features, each service is implemented separately and has its own WSDL etc... My question is about what is the best way to deploy those services, the possibilities are: 1. generate the *.aar for each service and deploy of all them into axis2.war container. 2. generate for each service a *.war file and deploy them directly into Tomcat. Which advantages provide the axis2.war container? And about performances which solution is best? Thanks in advance, Mh
HttpClient redirection problem
Hi, I have an Axis2 service which include the functionality that a SOAP Client can send a remote url and a path to a local stored file and then the Service reads the request and copy the file to the remote location using HTTP PUT protocol using Jakarta Commons HttpClient API. At first I got the following error in the class that do the HTTP-PUT transfer: *May 9, 2008 4:33:05 PM org.apache.commons.httpclient.HttpMethodDirector isRedirectNeeded INFO: Redirect requested but followRedirects is disabled HTTP-PUT transfer status: HTTP/1.1 301 Moved Permanently* I fixed it by setting httpPutmethod.setFollowRedirects(true) in my code but now it seems Axis2 is reporting the same problem as I am getting this error message: *org.apache.axis2.AxisFault: Entity enclosing requests cannot be redirected without user intervention *Why is this happening? Is is possible to execute a HTTP-PUT request inside the code of an Axis2 service? How can I set in my Service that redirections are enabled? I have done too another method that performs an HTTP-GET request and it works fine! Thanks in advance! -- ~~~ Para atras, solo para tomar impulso! http://moleyharey.blogspot.com/
Axis2 Single-Sign-On support?
Hi, This is a security-related question... I have developed an Axis2 service that is working fine and now I would like to add Single-Sign-On to allow the users to access secured resources through my service. Has anyone worked with it? Does Axis2 include support for this protocol? In case it does not include it, which are the security APIs used by Axis2 to ensure secure access? Thanks in advance, esther -- ~~~ Para atras, solo para tomar impulso! http://moleyharey.blogspot.com/
Re: Axis2 Single-Sign-On support?
Hi, Thanks for your response, do you know if Rampart is supported in Axis2 1.2version? I have been checking at: http://ws.apache.org/axis2/modules/rampart/1_2/security-module.html But I am not sure :/ 2008/3/31, Sanjay Vivek [EMAIL PROTECTED]: Axis2 uses WS-Security for authentication and authorisation. Apache Rampart in turn implements WS-Security standards. Cheers. Sanjay -- *From:* Moley Harey [mailto:[EMAIL PROTECTED] *Sent:* 31 March 2008 10:20 *To:* axis-user@ws.apache.org *Subject:* Axis2 Single-Sign-On support? Hi, This is a security-related question... I have developed an Axis2 service that is working fine and now I would like to add Single-Sign-On to allow the users to access secured resources through my service. Has anyone worked with it? Does Axis2 include support for this protocol? In case it does not include it, which are the security APIs used by Axis2 to ensure secure access? Thanks in advance, esther -- ~~~ Para atras, solo para tomar impulso! http://moleyharey.blogspot.com/ -- ~~~ Para atras, solo para tomar impulso! http://moleyharey.blogspot.com/
Load text/image files from Axis2 classpath?
Hi, Is it possible to load text or image files placed under WEB-INF/classes directory? If those files are in the classes folder then they are supposed to be in the application classpath and then there is a method to retrieve them so is not necessary to specify the full path to the file? Thanks in advance! -- ~~~ Para atras, solo para tomar impulso! http://chromewaves.blogspot.com/
How to get the MessageContext of my application?
Hi, I have stored some parameters in my Axis2 application services.xml file and I would like to retrieve them, for that I use: = org.apache.axis2.context.MessageContext msgCtx = new org.apache.axis2.context.MessageContext(); Parameter parameter = msgCtx.getParameter(myParameter); = The problem is that I get a NullPointerException because msgCtx is null... How can I get the correct value of msgCtx for my application? Thanks in advance! -- ~~~ Para atras, solo para tomar impulso! http://chromewaves.blogspot.com/
Where can I store some general parameters of my Axis2 Web Service?
Hi, I have developed a web service using Axis2 and I would like to store in a file some common configuration parameters of my service. What is the best way to do so? I was thinking about doing an XML file by myself, store there the parameters and implement some methods to parse the file and retrieve the values... This file will be placed under WEB-INF folder, so how can I access this resource from my Java code? Does Axis2 provide any XML file and methods to store and retrieve service configuration parameters? Thanks in advance! -- ~~~ Para atras, solo para tomar impulso! http://chromewaves.blogspot.com/
Show Axis2 log messages in a separate file not in console
Hi, I have implemented and Axis2 service and I would like to display all log messages in a separate file that the catalina.out file of my Tomcat, to do so I am using Apache Commons library. The problem is that I have disabled the console option and enabled the log file one but it does not create the new log file into ~/tomcat/logs folder and still is showing all messages into catalina.out... Here is my log4j.properties file code: === # Set root category priority to INFO and its only appender to LOGFILE. log4j.rootCategory=INFO, LOGFILE # Set the enterprise logger priority to FATAL log4j.logger.org.apache.axis2.enterprise=FATAL log4j.logger.de.hunsicker.jalopy.io=FATAL log4j.logger.httpclient.wire.header=FATAL log4j.logger.org.apache.commons.httpclient=FATAL # CONSOLE is set to be a ConsoleAppender using a PatternLayout. log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout log4j.appender.CONSOLE.layout.ConversionPattern=%d %-5p %c - %m%n # LOGFILE is set to be a File appender using a PatternLayout. log4j.appender.LOGFILE=org.apache.log4j.FileAppender log4j.appender.LOGFILE.File=/home/users/tomcat/logs/myservice.log log4j.appender.LOGFILE.Append=true log4j.appender.LOGFILE.layout=org.apache.log4j.PatternLayout log4j.appender.LOGFILE.layout.ConversionPattern=%d [%t] %-5p %c %x - %m%n === Any idea of what is happening? -- ~~~ Para atras, solo para tomar impulso! http://chromewaves.blogspot.com/
How to perform REST requests in a Service?
Hi, I have implemented an Axis2 web service following the Axis2 Tutorials and using Axis Data Binding, I have implemented a client that test the SOAP over HTTP requests/responses. My question is what should I do to support not only SOAP but REST requests? I have seen in my axis2.xml file some parameters such as restPath, disableREST etc... that I should tune to get this but is there anything I have to add to my SOAP service implementation? Thanks, Mh -- ~~~ Para atras, solo para tomar impulso! http://chromewaves.blogspot.com/
Re: Deploy my Service in a different war than axis2.war
Thanks Antonio, the tutorial was very useful!! 2008/2/20, Antonio Manuel Muñiz Martín [EMAIL PROTECTED]: See this: http://wso2.org/library/90 2008/2/19, Moley Harey [EMAIL PROTECTED]: Hi folks! I have developed an Axis2 Web Service and to deploy and use it in Tomcat I generate the MyService.aar file and copy it into the $CATALINA_HOME/webapps/axis2/WEB-INF/services folder so it gets deployed correctly and is accesses in the url: http://localhost:8080/axis2/services/MyService My question is if I could build my own mydeployment.war file (instead of using the standard axis2.war) and put there all the necessary jars, configuration files and my own MyService.aar and deploy it directly into Tomcat so the url to access it would be something like: http://localhost:8080/mydeployment/services/MyService Is it possible to do it? Or all services implemented using Axis2 have to be deployed into axis.war file?? Thanks in advance, Mh -- ~~~ Para atras, solo para tomar impulso! http://chromewaves.blogspot.com/
Deploy my Service in a different war than axis2.war
Hi folks! I have developed an Axis2 Web Service and to deploy and use it in Tomcat I generate the MyService.aar file and copy it into the $CATALINA_HOME/webapps/axis2/WEB-INF/services folder so it gets deployed correctly and is accesses in the url: http://localhost:8080/axis2/services/MyService My question is if I could build my own mydeployment.war file (instead of using the standard axis2.war) and put there all the necessary jars, configuration files and my own MyService.aar and deploy it directly into Tomcat so the url to access it would be something like: http://localhost:8080/mydeployment/services/MyService Is it possible to do it? Or all services implemented using Axis2 have to be deployed into axis.warfile?? Thanks in advance, Mh
Error deploying Axis2 application into Spring
Hi, I have developed an Axis 2 interface for a POJO-based J2EE application implemented using Spring. When I deploy the application I get the following error message in Tomcat log file: === Caused by: java.lang.IllegalStateException: No valid ObjectCreator found. at org.apache.axiom.om.util.StAXUtils$Pool.init(StAXUtils.java:64) at org.apache.axiom.om.util.StAXUtils.clinit(StAXUtils.java:88) === Could this be related to the way the application is deployed or maybe is a problem of the version of the Axiom/Stax jar files I am using? Thanks in advance -- ~~~ Para atras, solo para tomar impulso! http://chromewaves.blogspot.com/
Filename must not be null exception deploying Axis2 service
Hi, I have an Axis2 interface embedded into Spring and when I deploy it into Tomcat I get the following error: java.lang.IllegalArgumentException: Filename must not be null at org.apache.axis2.deployment.repository.util.DeploymentFileData .init(DeploymentFileData.java:43) I think maybe the problem is related with the way the Axis2 service is deployed, I have done the following: 1.Add the services.xml file into WEB-INF and WEB-INF/services folder. 2. Pack all Axis2 interface code into a jar file and put it into WEB-INF/lib folder. Any idea on what the problem can be? What is the correct way to deploy Axis2 code into Spring-based applications? -- ~~~ Para atras, solo para tomar impulso! http://chromewaves.blogspot.com/
Upgrade to Filename must not be null exception deploying Axis2 service
Hi I have found that this maybe a bug: https://issues.apache.org/jira/browse/AXIS2-3246?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel Currently I am using version 1.3, should I downgrade to any other previous version? :/ -- ~~~ Para atras, solo para tomar impulso! http://chromewaves.blogspot.com/