Axis2 quick start guide-client code

本文详细介绍了如何使用 Axis2 在 Windows 系统中部署 Web Service 的步骤,包括下载、解压缩、放置 WAR 文件、启动 Tomcat 服务器、生成客户端代码及配置依赖等关键步骤。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

#developing in win system

1)download zip file from axis2 website

2)uncompress axis2.1.6.4-bin.zip,axis-1.6.4.war.zip,and must be download tomcat 7 or even later

3)put the unzip file axis2.war into tomcat directorys webapps.,and start tomcat server

call the link  :http://localhost:8080/axis2/

4)genercate client code

cd axis2/bin,type the command

wsdl2java.bat -uri http://localhost:8080/axis2/services/Version?wsdl -o Test

5.)config client code

create a maven project

How to config the axis dependences

copy axis2 example project "axis2-1.6.4\samples\transport\https-sample" pom dependences

and axis2-1.6.4\samples\jaxws-samples\ pom file dependences

<dependencies>
        <dependency>
            <groupId>org.mongodb</groupId>
            <artifactId>mongo-java-driver</artifactId>
            <version>3.2.0</version>
        </dependency>
        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>servlet-api</artifactId>
            <version>2.3</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.axis2</groupId>
            <artifactId>axis2-kernel</artifactId>
            <version>1.6.4</version>
        </dependency>
        <dependency>
            <groupId>org.apache.axis2</groupId>
            <artifactId>axis2-jaxws</artifactId>
            <version>1.6.4</version>
        </dependency>
        <dependency>
            <groupId>org.apache.axis2</groupId>
            <artifactId>axis2-codegen</artifactId>
            <version>1.6.4</version>
        </dependency>
        <dependency>
            <groupId>org.apache.axis2</groupId>
            <artifactId>axis2-adb</artifactId>
            <version>1.6.4</version>
        </dependency>
        <dependency>
            <groupId>org.apache.axis2</groupId>
            <artifactId>addressing</artifactId>
            <version>1.6.4</version>
            <type>mar</type>
        </dependency>
        <dependency>
            <groupId>org.apache.axis2</groupId>
            <artifactId>axis2-transport-http</artifactId>
            <version>1.6.4</version>
        </dependency>
        <dependency>
            <groupId>org.apache.axis2</groupId>
            <artifactId>axis2-transport-local</artifactId>
            <version>1.6.4</version>
        </dependency>


6)  invoke menthod



评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值