Axis2 Web Service Development & Deployment Guide(Axis2使用)
2024-10-15 13:56:39
主要内容:
记录关于Axis2的使用,通过WSDL文件生成Web service的客户端和服务器端的过程.
目录:
- Requirement(必备工具)
- Development - Client Generation(生成客户端)
- Development - Server Generation(生成服务器端)
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(生成客户端)
- in folder:Create a folder as clientSide under C:\
- in cmd:Now open a cmd
- in cmd:Change your path to C:\axis2-1.5.6\bin
- in cmd:Set your JAVA_HOME to your java SDK home (eg : set JAVA_HOME=c:\Program Files\Java\jdk1.6.0_33)
- in cmd:Enter: wsdl2java.bat -uri CBS-CustAcctListProfile-I-Concrete_HTTP.wsdl -u -o c:\clientSide
- in folder:The commend above will generate the client side java files under C:\clientSide
- in folder:Go to C:\clientSide in windows explorer and open the build.xml file
- in build.xml file:Change memoryMaximumSize="256m" memoryInitialSize="256m" to memoryMaximumSize="512m" memoryInitialSize="512m"
- in build.xml file:Change axis2.home
- in build.xml file:Change <jar destfile="${lib}/${name}-test-client.jar"> to <jar destfile="${lib}/appropriatename-client.jar">
- Appropriate
name depends on the service, example for CBS-CustAcctDetails-I
appropriate name for the jar would be cbs-CustAcctDetails-client.jar - 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
- in folder:The client jar will be created at C:\clientSide\build\lib\
Development - Server Generation(生成服务器端)
- in folder:Create a folder serverSide under C:\
- in cmd:Now open cmd
- in cmd:Change your path to C:\axis2-1.5.6\bin
- in cmd:Set your JAVA_HOME to your java SDK home (eg : set JAVA_HOME=c:\Program Files\Java\jdk1.6.0_33)
- in folder:put your WSDL file into:C:\serverSide\build\classes\META-INF
- in cmd:Then enter: wsdl2java.bat -uri <filename.wsdl> -ss -sd -o c:\serverSide (note:filename need to change to your WSDL file name)
- in folder:This command will generate server side (service provider) java files under C:\serverSide.
- in folder:Go to C:\serverSide in windows explorer and open the build.xml file.
- in build.xml file:Change memoryMaximumSize="256m" memoryInitialSize="256m" to memoryMaximumSize="512m" memoryInitialSize="512m"
- in build.xml file:Change axis2.home
- 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 )
- in folder:This will build the java files in C:\serverSide\build\lib\
如有侵权,请联系作者删除
最新文章
- Mybatis传多个参数(三种解决方案)
- Spring Bean
- 开发时建议关闭chrome的缓存[Disable cache(while DevTools open)]
- Salesforce 数据清洗
- oracle中的函数及其应用
- HTML的select控件美化
- dom4j增删改查
- 手势识别官方教程(2)识别常见手势用GestureDetector+手势回调接口/手势抽象类
- DLL模块:C++在VS下创建、调用dll
- 5、Java Swing布局管理器(FlowLayout、BorderLayout、CardLayout、BoxLayout、GirdBagLayout 和 GirdLayout)
- cassandra.yaml 配置 (非原创,侵删)
- codeM美团编程大赛初赛B轮D题
- 用Eclipse 搭建一个Maven Spring SpringMVC 项目
- [复习]动态dp
- IIS7 禁止目录运行脚本
- [2017BUAA软工]第零次博客作业
- luogu2542 航线规划 (树链剖分)
- POJ-3278.CatchThatCow(数字BFS最短路输出)
- mysqlbinlog- 处理二进制日志文件的实用工具 学习笔记
- 关联更新SQL语句