首页 新闻 会员 周边

ESB Mule 如何配置实现更改访问的url

0
悬赏园豆:200 [待解决问题]

大家好!

我想请教一个问题:
我想用mule 将我现在的页面访问地址地址"http://localhost:8080/sbtc/index.html" 改写成 “http://localhost:1234/sbtc/index.html”。我用的是mule-standalone-3.1.1. 这是我的xml配置:<http:connector name="HttpConnector" enableCookies="true" keepAlive="true"/>
 
 <model>
  <service name="BridgeRequester">
  <inbound>
  <http:inbound-endpoint address="http://localhost:1234/"  contentType="text/html" method="GET" exchange-pattern="request-response"
  />
  </inbound>
  <outbound>
  <chaining-router>
  <http:outbound-endpoint host="localhost" port="8080" path="#[header:inbound:http.request]"  followRedirects="true" exchange-pattern="request-response"/>
  </chaining-router>
  </outbound>
 </service>
 </model>
可以成功访问到内容,在index.html里有好多ajax请求,有GET方法,也有POST方法。上面我在inbound里method 配置的是GET,导致一些post 方法的ajax请求不能正常工作,症状是 使用post的方法,后台接受的参数都是null,如果我把xml中inbound中的method改为POST方法,访问http://localhost:1234/sbtc/index.html这时,就会报错,什么都出不来。我想使用mule里的重定向功能,但是按照doc里的内容配置不能运行,现在我不知道怎么配置xml文件。这个问题困扰我好久了,请帮帮我。我就是想使用 一个新的url 代替 http://localhost:8080/sbtc/index.html 这个原来的地址。就是使得真实的url 用户不能看见,用户使用的url是经过mule 配置过的url。

我给出了我所有的分  拜托大家了。

DreamThinkinger的主页 DreamThinkinger | 初学一级 | 园豆:0
提问于:2011-03-24 14:24
< >
分享
所有回答(0)
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册