Why I can not access Axis2 service at localhost? - web-services

I am developing a Web Service project using axis2, tomcat and eclipse.
I download axis2 war package and drop it to tomcat/webapps, then I start tomcat , I can access tomcat at http://localhost:8080, but failed to access http://localhost:8080/axis2,please tell me what the problem might be.
Thanks in advance.

Set TOMCAT_HOME environment variable, Set the value to top level directory of your Tomcat install (e.g. D:\programs\apache-tomcat-6.0.29)

what error you are receiving in logs and what version of tomcat using.
If no error is there , please check , the default web services included with Axis2 will be available by visiting http://localhost:8080/axis2/services/
For reference : http://axis.apache.org/axis2/java/core/docs/installationguide.html

Related

Consuming webservice from application deployed on websphere

I have been trying to consume a webservice(WS-JAX) in java.
I have generated JAVA artifacts using wsimport tool. I constructed a standalone test class(on eclipse) and was able to call the webservice successfully.
But when I use the same actifacts and code in my application(deployed on websphere 8) I get below exception
`
[2/5/16 10:54:13:531 MST] FFDC Exception:java.lang.StackOverflowError SourceId:com.ibm.ejs.container.RemoteExceptionMappingStrategy.setUncheckedException ProbeId:200 Reporter:com.ibm.ejs.container.RemoteExceptionMappingStrategy#625fad44
java.lang.StackOverflowError
at java.util.HashMap.<init>(HashMap.java:367)
at com.ibm.wsdl.DefinitionImpl.getAllServices(DefinitionImpl.java:859)
at com.ibm.wsdl.DefinitionImpl.getAllServices(DefinitionImpl.java:873)
at org.apache.axis2.wsdl.util.WSDLWrapperReloadImpl.getAllServices(WSDLWrapperReloadImpl.java:903)
at org.apache.axis2.wsdl.util.WSDLDefinitionWrapper.getAllServices(WSDLDefinitionWrapper.java:478)
at com.ibm.wspolicy.wsdl.internal.subject.DefinitionSubjectProcessor.<init>(DefinitionSubjectProcessor.java:60)
at com.ibm.wspolicy.wsdl.internal.WSDLProcessorImpl.buildWSDLPolicyModel(WSDLProcessorImpl.java:79)
at com.ibm.ws.wspolicy.wsdl.WSDLProcessor.<init>(WSDLProcessor.java:137)
at com.ibm.ws.wspolicy.policyset.WSDLHelperImpl.processWSPolicyInPackagedWSDL(WSDLHelperImpl.java:80)
at com.ibm.ws.websvcs.deployment.WASAxis2PolicySetConfigurator.associatePolicySets(WASAxis2PolicySetConfigurator.java:385)
at com.ibm.ws.websvcs.client.WSClientConfigurationFactory.completeAxis2Configuration(WSClientConfigurationFactory.java:459)
at org.apache.axis2.jaxws.description.impl.EndpointDescriptionImpl.<init>(EndpointDescriptionImpl.java:286)
at org.apache.axis2.jaxws.description.impl.EndpointDescriptionImpl.<init>(EndpointDescriptionImpl.java:223)
at org.apache.axis2.jaxws.description.impl.ServiceDescriptionImpl.updateEndpointDescription(ServiceDescriptionImpl.java:534)
at org.apache.axis2.jaxws.description.impl.DescriptionFactoryImpl.updateEndpoint(DescriptionFactoryImpl.java:382)
at org.apache.axis2.jaxws.description.DescriptionFactory.updateEndpoint(DescriptionFactory.java:180)
at org.apache.axis2.jaxws.spi.ServiceDelegate.getPort(ServiceDelegate.java:597)
at org.apache.axis2.jaxws.spi.ServiceDelegate.getPort(ServiceDelegate.java:513)
at javax.xml.ws.Service.getPort(Service.java:99)`
Could someone shed some light on why the webservice call is failing when it is originating inside a application server?
Note: I have installed proper server certificates in the application server truststore.
So i found the solution, I had 2 different JRE's installed on my computer. One was from Oracle and the other was the jre bundled with websphere application server. For a application to be deployed on Websphere we have to generate the java artifacts using the IBM jre thats bundled with Websphere.
Thanks,
Harsha

how to delete the application context of my web?

I've a web (jsf) running in tomcat on EC2 server amazon and my domain www.mydomain.tk and I'd like to show my web when I type my domain. At the moment I've to type www.mydomain.tk/ContexOfMyApp .
www.mydomain.tk/ContexOfMyApp (at the moment ) --> www.mydomain.tk
How can I do that?
Thanks a lot.
SOL: How to set the context path of a web application in Tomcat 7.0
In tomcat webapps directory try to rename your application as ROOT. ContextOfMyApp will become ROOT

WebService EndPoint Not accessible in Jboss Fuse 6

I developed Simple WebService OSGI Bundle with Eclipse Libra, Apache CXF and deployed it in JBoss Fuse 6. But when i tried to access it with http://x.x.x.x:8181/cxf/TestWs?wsdl it shows nothing.
I also tried following URL http://x.x.x.x:8181/cxf and it says no services.
I check status of this with karaf shell osgi:list and it shows me its Active.
Please let me know if i am doing any wrong?
Following is my Manifest.Mf
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: TestWs
Bundle-SymbolicName: TestWs
Bundle-Version: 1.0.0.qualifier
Bundle-ClassPath: WEB-INF/classes/
Export-Package: com.irk.ws,
com.irk.ws.jaxws
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
Import-Package: javax.el,
javax.servlet,
javax.servlet.http,
javax.servlet.jsp,
javax.servlet.jsp.el,
javax.servlet.jsp.tagext
Web-ContextPath: /TestWs
Regards,
did you try adding camel-cxf feature ?

SOAP client in IIS cannot access web services in Tomcat

I have IIS (localhost:443) and Tomcat (localhost:8080) both running on my local machine. The Tomcat contains Java web services and I can remotely debug it in Eclipse IDE. I have an application installed in my IIS and when I access the page of that application, it requests a web service in Tomcat.
The problem is that when I try to load the page (the one deployed in IIS), my Eclipse won't go to the break point, meaning no request was retrieved on the Tomcat side.
But when I try to execute a request using SoapUI, Tomcat receives it and it enters my breakpoint in Eclipse. (meaning that the web services are accessible)
I cannot debug the application in IIS so I cannot determine why it can't call the web service.
Do I need to setup Windows Firewall for it? I'm just running those apps in my local machine.
Any ideas?
I got it working. My problem was permission issues in c:\windows\temp directory. I found my answer here http://nishantrana.wordpress.com/2008/02/06/unable-to-generate-a-temporary-class-result1-error-cs2001-source-file-cwindowstempfilenamecs-could-not-be-found-error-cs2008-no-inputs-specified/

Axis Bottom-up Webservice IWAB0489E error

I am having a look around bottom-up Webservice in Eclipse. Here is my environment:
Eclipse Helios
Java 1.6.0_29
Apache Axis2
Tomcat 6.x
I create Dynamic Web project and create a simple service class. And then I tried to create Webservice for the class, I got some errors like below:
IWAB0489E Error when deploying Web service to Axis runtime
axis-admin failed with {http://schemas.xmlsoap.org/soap/envelope/}Client The service cannot be found for the endpoint reference (EPR) http://localhost:8080/myws/services/AdminService
Searching web, I could not any clear answer yet. Please help me.
Thanks in advance.
I have the same problem i go Window -> Preferences -> WebServices -> Server and Runtime and set it as you see here:
Previously it was selected Tomcat 6 (i use 7) and axis1 not 2
Try these 3 methods
1) try deleting the .snap file found in
yourprojectworkspace\ .metadata\ .plugins\ org.eclipse.core.resources
2) The most common hiccup is when another web server (or any process for that matter) has laid claim to port 8080. This is the default HTTP port that Tomcat attempts to bind to at start-up. To change this, open the file:
$CATALINA_HOME/conf/server.xml
And search for '8080'. Change it to a port that isn't in use, and is greater than 1024, as ports less than or equal to 1024 require superuser access to bind under UNIX. (Example 8181)
Restart Tomcat and you're in business. Be sure that you replace the "8080" in the URL you're using to access Tomcat. For example, if you change the port to 8181, you would request the URL http://localhost:8181/ in your browser.
3) Open the bin folder which contains the shutdown.bat file residing inside the tomcat directory. Run it, that should solve the port problem.