1、官网下载 Download Mule ESB v.3.3 --> MuleStudio-CE-for-win-32bit-1.3.2-201212121943.zip
http://www.mulesoft.org/download-mule-esb-community-edition
2、解压后,启动Mule Studio
[img]http://dl.iteye.com/upload/attachment/0079/1136/9975b916-32c6-3fd2-91bd-a6d2bb5f4015.jpg[/img]
3、新建mule_project,命名为mule_demo
[img]http://dl.iteye.com/upload/attachment/0079/1140/4b7fa4d3-2a1e-3012-9772-b7561879e204.jpg[/img]
如图所示,在右边Endpoints中选择Http Enpoint并拖拽到左边空白区
在components中选择Echo拖拽到HTTP后面。对应的XML如下:
4、在mule_demo.mflow右键选择:Run As Mule Application
5、在浏览器访问:http://localhost:8081/helloworld
6、结果浏览器显示:/helloworld
各种原理暂不解释 :oops: 我也不懂...。
http://www.mulesoft.org/download-mule-esb-community-edition
2、解压后,启动Mule Studio
[img]http://dl.iteye.com/upload/attachment/0079/1136/9975b916-32c6-3fd2-91bd-a6d2bb5f4015.jpg[/img]
3、新建mule_project,命名为mule_demo
[img]http://dl.iteye.com/upload/attachment/0079/1140/4b7fa4d3-2a1e-3012-9772-b7561879e204.jpg[/img]
如图所示,在右边Endpoints中选择Http Enpoint并拖拽到左边空白区
在components中选择Echo拖拽到HTTP后面。对应的XML如下:
<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns:http="http://www.mulesoft.org/schema/mule/http" xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation" xmlns:spring="http://www.springframework.org/schema/beans" version="CE-3.3.1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="
http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd ">
<flow name="mule_demoFlow1" doc:name="mule_demoFlow1">
<http:inbound-endpoint exchange-pattern="request-response" host="localhost" port="8081" doc:name="HTTP"/>
<echo-component doc:name="Echo"/>
</flow>
</mule>
4、在mule_demo.mflow右键选择:Run As Mule Application
5、在浏览器访问:http://localhost:8081/helloworld
6、结果浏览器显示:/helloworld
各种原理暂不解释 :oops: 我也不懂...。