Axis2 Web Service Development & Deployment Guide

Posted ymjingspace

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Axis2 Web Service Development & Deployment Guide相关的知识,希望对你有一定的参考价值。

Menu:

  • Requirement
  • Development - Client Generation
  • Development - Server Generation
  • References

Requirement

  • Apache Axis 2 1.5.6 (and above)  下载地址:http://archive.apache.org/dist/axis/axis2/java/core/1.6.1/axis2-1.6.1-bin.zip
  • Apache Tomcat 6 (and above)
  • Apache Ant 1.8.3 (and above)
  • Java JDK 1.5 (and above)
  • WSDL

Development - Client Generation

  1. in folder:Create a folder as clientSide under C:\\
  2. in cmd:Now open a cmd
  3. in cmd:Change your path to C:\\axis2-1.5.6\\bin
  4. in cmd:Set your JAVA_HOME to your java SDK home (eg : set JAVA_HOME=c:\\Program Files\\Java\\jdk1.6.0_33)技术图片
  5. in cmd:Enter: wsdl2java.bat -uri CBS-CustAcctListProfile-I-Concrete_HTTP.wsdl -u -o c:\\clientSide
  6. in folder:The commend above will generate the client side java files under C:\\clientSide
  7. in folder:Go to C:\\clientSide in windows explorer and open the build.xml file
  8. in build.xml file:Change memoryMaximumSize="256m" memoryInitialSize="256m" to memoryMaximumSize="512m" memoryInitialSize="512m"
    技术图片技术图片
  9. in build.xml file:Change axis2.home 技术图片
  10. in build.xml file:Change <jar destfile="${lib}/${name}-test-client.jar"> to <jar destfile="${lib}/appropriatename-client.jar">
  11. Appropriate name depends on the service, example for CBS-CustAcctDetails-I appropriate name for the jar would be cbs-CustAcctDetails-client.jar
  12. in cmd:Open back the existing (or new cmd and set the java), point to the bin folder (eg : C:\\apache\\apache-ant-1.8.3\\bin),enter : ant -f c:\\clientSide\\build.xml
  13. in folder:The client jar will be created at C:\\clientSide\\build\\lib\\

Development - Server Generation

  1. in folder:Create a folder serverSide under C:\\
  2. in cmd:Now open cmd
  3. in cmd:Change your path to C:\\axis2-1.5.6\\bin
  4. in cmd:Set your JAVA_HOME to your java SDK home (eg : set JAVA_HOME=c:\\Program Files\\Java\\jdk1.6.0_33)
  5. in folder:put your WSDL file into:C:\\serverSide\\build\\classes\\META-INF
  6. in cmd:Then enter: wsdl2java.bat -uri <filename.wsdl> -ss -sd -o c:\\serverSide   (note:filename need to change to your WSDL file name)
  7. in folder:This command will generate server side (service provider) java files under C:\\serverSide.
  8. in folder:Go to C:\\serverSide in windows explorer and open the build.xml file.
  9. in build.xml file:Change memoryMaximumSize="256m" memoryInitialSize="256m" to memoryMaximumSize="512m" memoryInitialSize="512m"
    技术图片技术图片
  10. in build.xml file:Change axis2.home 技术图片
  11. in cmd:Open back the existing (or new cmd and set the java), enter : ant -f c:\\serverSide\\build.xml      (OR:in cmd:Change your path to C:\\axis2-1.5.6\\bin,enter: ant )
  12. in folder:This will build the java files in C:\\serverSide\\build\\lib\\

转载自: Technical Repository

原文地址: https://conf-server.hitachi-ebworx.com/pages/viewpage.action?pageId=6848538

如有侵权,请联系作者删除

以上是关于Axis2 Web Service Development & Deployment Guide的主要内容,如果未能解决你的问题,请参考以下文章

Axis2实现 web service接口开发 + 客户端调用

Web Service Security with Axis2

2.4 Apache Axis2 快速学习手册之XMLBeans 构建Web Service

新手Axis2 发布Web Service之路

Eclipse+Axis2发布WSDL类型的Web Service并用SoapUI测试调用(2021.11.15)

Eclipse+Axis2发布WSDL类型的Web Service并用SoapUI测试调用(2021.11.15)