Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Can Axis2 app be deployed the same way as Axis1? Put all jars in WEB-INF/lib, create EAR, deploy

 
Sam Gehouse
Ranch Hand
Posts: 281
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can an Axis2 (version 1.5) application be deoployed in the same way as an Axis 1 application?

In Axis1, I can put the jar files in WEB-INF/lib folder of my project, create an EAR file and deploy it in the Application Server of my choice using the Admin console of the chosen application server.

My question:
Is the same approach possible in Axis 2? Meaning, can I put the jar files from Axis2 in WEB-INF/lib folder of my project, create EAR file (e.g. MyApp.ear) and deploy my custom app (MyApp) using the Admin console of the application server of my choice (e.g. WebSphere) ? Will this approach work in Axis 2?

Please answer, only if you have been able to successfully accomplish the above.


The Axis2 documentation is not very clear on that.

I understand that Axis2 provides provides easy way to deploy application (need to rename it as aar) using Axis2 Admin console that requires deployment of axis2.war. But that is not the question here. From all my readings, I have NOT seen any straight answer on that. Unless you are using the Axis2 Admin console, it seems quite convoluted to deploy the application. An approach stated in: http://www.devx.com/Java/Article/33839

Any answer to my question from someone who has successfully done the above (and what steps you have taken) will be appreciated.
 
Sam Gehouse
Ranch Hand
Posts: 281
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If Axis2 website provided any documentation on this, it would have been nice. Will it be possible for this team to add a section on how to deploy an app (JAR, EAR, WAR) using the Application server of choice, instead of using Axis2 admin console?

Following are the steps that I have taken:

I have successfully deployed an Axis 2 application (using version 1.5) as a EAR file using the Admin Console of the application server (WebSphere 6.1 in this case). I did not use Axis2 admin console. I am sure that it would have worked if I packaged this Axis2 app as WAR, instead of EAR.

Following are the steps that I have taken:


Following are the code:

web.xml:


services.xml:


My target endpoint is: "http://localhost:9081/axis2/services/CalculatorService"
Seems like /axis2/services/ are mandatory in the path.

I packaged this application as EAR file. Next, I deployed it using the Admin console of WebSphere 6.1.

I invoked the doGet method of Servlet as: http://localhost:9081/MyAxis2/CalculatorClientServlet.

I am using http://javaboutique.internet.com/tutorials/axis2/ for learning purposes.


Regards,

Sam
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic