Apache Axis

来自开放百科 - 灰狐
(版本间的差异)
跳转到: 导航, 搜索
 
(未显示2个用户的16个中间版本)
第1行: 第1行:
[[Image:Axis3.jpg|right]]
+
{{top news}}
 +
{{SeeWikipedia}}
 +
[[Image:Axis2.jpg|right]]
  
==Apache Axis 简介==
+
==Apache Axis2==
 +
Axis2 组件视图
  
Apache Axis 是Apache WebService项目中的子项目,其最初起源于IBM的"SOAP4J",应该属于最早的一批用于构造基于SOAP应用的Framework。
+
[[Image:axis2_components.jpg]]
 +
[[Image:axis2_arch.gif|thumb|right|Axis2 体系结构关系图]]
 +
 
 +
Apache Axis2 是 Apache Axis SOAP 项目的后继项目。此项目是 Web 服务核心引擎的重要改进,目标是成为 Web 服务和面向服务的体系结构(Service-Oriented Architecture,SOA)的下一代平台。
 +
 
 +
新特性:
 +
*新 XML 对象模型 (AXIOM)
 +
Axis2 对象模型(AXIs2 Object Model,AXIOM)是 Axis2 的基础,任何 SOAP 消息在 Axis2 中都表示为 AXIOM。AXIOM 相对于其他 XML 表示形式的优势在于,它基于 pull 解析器技术,而其他大多数则基于 push 解析器技术。pull 与 push 的主要不同之处在于,在 pull 技术中,调用者对解析器具有完全控制权,可以要求下一个事件;而对于 push,当要求解析器继续处理时,它将触发事件,直到达到文档最后为止。
 +
*基于消息传递的核心
 +
Axis2 具有流的概念,流是阶段的集合,而阶段是处理程序的集合。根据给定方法调用的 MEP,与其关联的流的数量可能会有所变化。
 +
*经过改进的部署模型
 +
Axis2 部署引入了类似于 Java™ 2 Platform Enterprise Edition (J2EE) 部署机制的概念,开发人员可以在其中将所有类文件、库文件、资源文件和配置文件一起打包为存档文件,并将其放置在文件系统中的指定位置。支持热部署和热更新
 +
*模块体系结构
 +
Axis2 为模块采用了一个新扩展文件名 .mar。模块存档文件中最重要的文件是模块配置文件或 module.xml。
 +
*新客户端 API
 +
此 API 包含两个类,分别名为 ServiceClient 和 OperationClient。
 +
 
 +
==Apache Axis 简介==
 +
Apache [[Image:Axis_90.jpg]] 是Apache WebService项目中的子项目,其最初起源于IBM的"SOAP4J",应该属于最早的一批用于构造基于SOAP应用的Framework。
  
 
目前Apache Axis已经发展到了第三代,其核心是一个SOAP处理器,用于开发包括客户端,服务器端,SOAP Gateway等各种应用。事实上Apache Axis在了1.0版后,其发行版本还包括了完整的J2EE服务器插件, WSDL支持和生成,TCP/IP监视器等组件,从这个意义上来说Apahce Axis已不仅仅是个SOAP框架了,它包含了除了UDDI外对整个Web Service协议栈(Protocol Stack)的支持。
 
目前Apache Axis已经发展到了第三代,其核心是一个SOAP处理器,用于开发包括客户端,服务器端,SOAP Gateway等各种应用。事实上Apache Axis在了1.0版后,其发行版本还包括了完整的J2EE服务器插件, WSDL支持和生成,TCP/IP监视器等组件,从这个意义上来说Apahce Axis已不仅仅是个SOAP框架了,它包含了除了UDDI外对整个Web Service协议栈(Protocol Stack)的支持。
第32行: 第53行:
  
 
==相关链接==
 
==相关链接==
*http://ws.apache.org/axis/
+
*Apache Axis2 - http://ws.apache.org/axis2/
 +
*Apache Axis - http://ws.apache.org/axis/
 +
*http://wiki.apache.org/ws/FrontPage/Axis
 +
*Apache Axis2 Version 1.0 Documentation - http://docs.huihoo.com/apache/axis2-1.0-docs/xdocs/1_0/
 +
*http://download.huihoo.com/apache/axis2/
 +
*http://docs.huihoo.com/apache/axis/
  
 
==安装指南==
 
==安装指南==
 +
wget axis2-1.3-bin.zip from http://download.huihoo.com/apache/axis2/
 +
unzip axis2-1.3-bin.zip
 +
cd bin
 +
./setenv.sh
 +
Using AXIS2_HOME:  /home/allen/axis2-1.3
 +
Using JAVA_HOME:      /usr/local/jdk1.5.0_07
 +
cd samples/pojo
 +
ant
 +
cp build/AddressBookService.aar to <AXIS2_HOME>/repository/services
 +
cd  <AXIS2_HOME>/bin
 +
./axis2server.sh
 +
http://localhost:8080/axis2/services/AddressBookService?wsdl
 +
Running the Client
 +
$ant rpc.client
 +
generate the stub
 +
$ant adb.client -Dwsdl=http://localhost:8080/axis2/services/AddressBookService?wsdl
 +
Building jar: /home/allen/axis2-1.3/samples/pojo/build/lib/adb-client.jar
 +
$ant rpc.client -Dwsdl=http://localhost:8080/axis2/services/AddressBookService?wsdl
 +
Building jar: /home/allen/axis2-1.3/samples/pojo/build/lib/rpc-client.jar
 +
获得 axis2 http://apache.justdn.org/ws/axis2/1_0/axis2.war
 +
http://localhost:8080/axis2/
 +
使用admin/axis2 登录,进入Axis2 Web Admin Module
 +
 
获得 http://mirror.vmmatrix.net/apache/ws/axis/1_4/axis-bin-1_4.tar.gz
 
获得 http://mirror.vmmatrix.net/apache/ws/axis/1_4/axis-bin-1_4.tar.gz
 
  tar zxvf axis-bin-1_4.tar.gz
 
  tar zxvf axis-bin-1_4.tar.gz
第42行: 第91行:
  
 
==精彩图集==
 
==精彩图集==
[[Image:axis-subsystems.jpg|thumb|left|Subsystems]] [[Image:axis-ServerMessagePath.jpg|thumb|left|Message Path on the Server]] [[Image:axis-ClientMessagePath.jpg|thumb|left|Message Path on the Client]]
+
<gallery perrow=5>
 +
Image:axis-subsystems.jpg|Subsystems
 +
Image:axis-ServerMessagePath.jpg|Message Path on the Server
 +
Image:axis-ClientMessagePath.jpg|Message Path on the Client
 +
</gallery>
 +
 
 +
{{Comment}}
 +
 
 +
[[Category:SOA]]
 +
[[Category:Apache]]

2010年9月26日 (日) 08:57的最后版本

Wikipedia-35x35.png 您可以在Wikipedia上了解到此条目的英文信息 Apache Axis Thanks, Wikipedia.
Axis2.jpg

目录

[编辑] Apache Axis2

Axis2 组件视图

Axis2 components.jpg

Axis2 体系结构关系图

Apache Axis2 是 Apache Axis SOAP 项目的后继项目。此项目是 Web 服务核心引擎的重要改进,目标是成为 Web 服务和面向服务的体系结构(Service-Oriented Architecture,SOA)的下一代平台。

新特性:

  • 新 XML 对象模型 (AXIOM)

Axis2 对象模型(AXIs2 Object Model,AXIOM)是 Axis2 的基础,任何 SOAP 消息在 Axis2 中都表示为 AXIOM。AXIOM 相对于其他 XML 表示形式的优势在于,它基于 pull 解析器技术,而其他大多数则基于 push 解析器技术。pull 与 push 的主要不同之处在于,在 pull 技术中,调用者对解析器具有完全控制权,可以要求下一个事件;而对于 push,当要求解析器继续处理时,它将触发事件,直到达到文档最后为止。

  • 基于消息传递的核心

Axis2 具有流的概念,流是阶段的集合,而阶段是处理程序的集合。根据给定方法调用的 MEP,与其关联的流的数量可能会有所变化。

  • 经过改进的部署模型

Axis2 部署引入了类似于 Java™ 2 Platform Enterprise Edition (J2EE) 部署机制的概念,开发人员可以在其中将所有类文件、库文件、资源文件和配置文件一起打包为存档文件,并将其放置在文件系统中的指定位置。支持热部署和热更新

  • 模块体系结构

Axis2 为模块采用了一个新扩展文件名 .mar。模块存档文件中最重要的文件是模块配置文件或 module.xml。

  • 新客户端 API

此 API 包含两个类,分别名为 ServiceClient 和 OperationClient。

[编辑] Apache Axis 简介

Apache Axis 90.jpg 是Apache WebService项目中的子项目,其最初起源于IBM的"SOAP4J",应该属于最早的一批用于构造基于SOAP应用的Framework。

目前Apache Axis已经发展到了第三代,其核心是一个SOAP处理器,用于开发包括客户端,服务器端,SOAP Gateway等各种应用。事实上Apache Axis在了1.0版后,其发行版本还包括了完整的J2EE服务器插件, WSDL支持和生成,TCP/IP监视器等组件,从这个意义上来说Apahce Axis已不仅仅是个SOAP框架了,它包含了除了UDDI外对整个Web Service协议栈(Protocol Stack)的支持。

对大多数关心Macromedia产品的人来说,Macromedia是Axis小组的核心成员之一,他们在几乎所有J2EE服务器端的产品线中包含了Axis,也就是说Macromedia对WebService的支持是通过Apache Axis实现的,这其中包括了JRun, Flex, ColdFusion。即便是Flash Remoting,由于其核心还是SOAP,所以也是使用了Axis的SOAP框架。

和.NET的WS不同,Axis是一个非常易于扩展的体系结构,其设计的核心思想是建立一个数据处理的管道,通过把handler编织成一条处理链从而无限扩展其可能性。打个比方,在输入部分开发人员既可以编写基于HTTP Basic Authentication的用户验证模块也可以插入SOAP Auth模块用于验证请求,而输出部分既可以通过XML binding把结果输出为SOAP XML也可以象Flash Remoting那样把结果输出成binary格式。

同时Axis也提供了所有的处理模块,使得用户能在最快的时间把服务器组件发布成WS.总的来说Axis有以下几个特点:

  • 速度 - Axis 使用 SAX 而不是 DOM 来处理XML请求,所以速度上有很大的改善。
  • 灵活性 - 刚才也提到了,Axis的体系结构是一个全开放式的处理器,所以扩展模块极为方便。
  • 面向组件的发布方式 - 处理链上可重复使用组件来完成类似的操作。
  • Transport 框架 - Axis的核心和底层的transport完全分离,也就是说不管WS的Transport是HTTP, FTP, MAIL, MESSAGE QUEUE,只要插入对应的Transport模块即可,而不需改动其他部分。
  • WSDL1.1支持 - 可自动由Java Object生成WSDL

[编辑] Apache SOAP与Axis的比较

Apache SOAP                   Axis
----                          ----
really old                    third generation
really slow                   much faster, but not as fast as many
no WSDL support               WSDL support
proprietary API               JAX-RPC API
RPC/encoded only              RPC/encoded and Doc/literal
interoperability issues       very interoperable
extensiblity issues           very extensible
low level API for headers     easy handler support for headers

[编辑] 相关链接

[编辑] 安装指南

wget axis2-1.3-bin.zip from http://download.huihoo.com/apache/axis2/
unzip axis2-1.3-bin.zip 
cd bin
./setenv.sh 
Using AXIS2_HOME:   /home/allen/axis2-1.3
Using JAVA_HOME:       /usr/local/jdk1.5.0_07
cd samples/pojo
ant
cp build/AddressBookService.aar to <AXIS2_HOME>/repository/services
cd  <AXIS2_HOME>/bin
./axis2server.sh
http://localhost:8080/axis2/services/AddressBookService?wsdl

Running the Client

$ant rpc.client

generate the stub

$ant adb.client -Dwsdl=http://localhost:8080/axis2/services/AddressBookService?wsdl
Building jar: /home/allen/axis2-1.3/samples/pojo/build/lib/adb-client.jar
$ant rpc.client -Dwsdl=http://localhost:8080/axis2/services/AddressBookService?wsdl
Building jar: /home/allen/axis2-1.3/samples/pojo/build/lib/rpc-client.jar

获得 axis2 http://apache.justdn.org/ws/axis2/1_0/axis2.war

http://localhost:8080/axis2/
使用admin/axis2 登录,进入Axis2 Web Admin Module

获得 http://mirror.vmmatrix.net/apache/ws/axis/1_4/axis-bin-1_4.tar.gz

tar zxvf axis-bin-1_4.tar.gz
cd /axis-1_4/webapps
mv -R axis /usr/local/tomcat/webapps/
http://localhost:8080/axis/

[编辑] 精彩图集

Comment-32x32.png

<discussion>characters_max=300</discussion>

分享您的观点
个人工具
名字空间

变换
操作
导航
工具箱