I've deployed Axis2 on a tomcat7 web server (linux machine).
To achieve this situation I copy the axis2.war into my /usr/share/tomcat7/webapps directory.
Then from my tomcat "localhostPath:8080/manager/html" I deploy the axis2.war just copied.
So browsing "localhostPath:8080/axis2/" I'm able to add a .aar service file which I wrote for axis2.
My service works well. All perfect! Service responses are in SOAP messages.
Now how can I have a JSON response from my service. I can't follow http://axis.apache.org/axis2/java/core/docs/json_support.html because axis2.xml is inside my axis2.war file and it is not possible to edit it.
Can someone help me? thanks a lot
Massimo
To get responses in JSON message fromat, you need to enable the message fromatter. For that you have to edit axis2.xml.
You might need to create the war again and deploy in the tomcat.
Related
I have got a webService without ui. It simple jax-ws app that will allow to manage users via soap requests. I tried to deploy it on websphere. It was deployed, But! my app doesn't appear in Service Providers and i can't get access to wsdl file via url that i pass in wsdlsoap:aderess location. It haven't got any servlets and other stuff. I create my app using template that deploy with success, it appear in Service Providers. I research all internet, but idk what go wrong.
P.S: Template project was eclipse project. I just add maven and has no idea why it wouldn't work.
The fact that your web service hasn't appeared in the Service Providers section means you've deployed it the wrong way.
Check whether you've selected the "Deploy web-services" option during deployment.
You probably got an issue in your trace.log file which possibly references to the ffdc, check it to investigate the problem.
You also haven't mentioned if you using servlet or EJB-based web services.
I had a EAR deployed to a Websphere server by our middleware group. When I look at the EAR properties in my local server console they show the Web Service Properties like this screenshot. This is a web service application that works using my local server in RAD.
The screenshot from the deployed application is missing the Web Services Properties section. I do not have direct access to the server, this was sent to me by my middleware resource.
There is only one EAR file that was sent to be deployed. The problem of course is that the services of the deployed application are not there. I believe that the EAR configuration is the root cause, and I am asking how to fix this issue. I am fairly new to Websphere, and at a loss on how to proceed. Thanks in advance!
The issue is the EAR is not deployed correctly. You may have to check the logs during deployment. The logs will give you the exact reason why the EAR is not completely deployed.
Seems you missed to change the project facets.Please find below:
enter image description here
It worked for me.
Basic question.
I've compiled and deployed to a local tomcat the war file that gets created in the sample cxf project java_first_spring_support (I followed the tutorial given here but using latest versions from cxf site : http://cxf.apache.org/docs/writing-a-service-with-spring.html ) but can't figure out how to test if it's working? my tomcat manager list apps page says it's running but not sure what to do beyond that.
Can I hit it with a http request via the browser to see the wsdl? If so what url should I use beyond my 'http://localhost:8080' url?
Is there no wsdl with this project and I should just craft my own soap request? and if so what should the structure be and what url should I use?
Well, figured it out. Went back to web.xml 101 and found my answer.
The generated wsdl is available from :-
http://localhost:8080/JavaFirstSpringSupport/services/HelloWorld?wsdl
Context of the app was : 'JavaFirstSpringSupport' (got this from my apps list page in tomcat) Got the services part by refering to the url pattern element in the deployed web.xml
I am returning a Zipped file say My_File.txt.zip from the My server side using JAX-RS (Jersey). My server-side is Java.
So I am getting the My_File.txt.zip in the client side while downloading.
But I want the actual file My_File.txt while downloading in the browser.
Is it possible?
I am working with Glassfish 3.x. So I there any configuration on Glassfish to do this?
Or can i change the configuration in Firefox (or other browsers) to do this?
Please suggest me the correct answer.
Thanks in advance.
I am developing a web service with Eclipse. This service will be accessed from Android with ksoap2.
I successfully tested the service on my local apache tomcat (http://localhost:8080/) and now want to set this service up on a different server (i.e. http://giraffe/).
The .wsdl file generated by Eclipse contains the following line:
<wsdlsoap:address location="http://localhost:8080/AndroidService/services/AndroidService"/>
I guess this won't work out if I just add the .war file to giraffe and try to reach the service.
My question now is the following: What do I need to change in order to be able to use this service on a different server? Do I just have to change this address location?
If you need me to post some of the code/files, just tell me.
My eclipse project structure looks like this:
You can replace http://localhost:8080 on wsdl with http://giraffe/
Are you facing any issue once you deploy on the server?