【问题标题】:Changing default address in fuse osgi for web service在 fuse osgi 中更改 Web 服务的默认地址
【发布时间】:2014-02-06 17:28:47
【问题描述】:

默认情况下,fuse ESB 会给出一个以 cxf 开头的端点 url。例如,如果我有

<jaxws:endpoint id="HTTPEndpoint"
    implementor="org.fusesource.example.PersonImpl"
    address="/PersonServiceCF"/>

在spring bean中配置的端点,将其部署为bundle后,fuse会将此端点发布为http://localhost:8181/cxf/PersonServiceCF?wsdl

现在我想将默认的前导 url cxf 更改为 xyz。它应该看起来像 http://localhost:8181/xyz/PersonServiceCF?wsdl 。我该怎么做,我google了很多,但找不到配置文件。任何提示都非常感谢。

【问题讨论】:

    标签: cxf fuseesb


    【解决方案1】:

    根据this 文档:

    更改 /cxf servlet 别名

    默认情况下,CXF Servlet 被分配一个“/cxf”别名。您可以通过以下几种方式对其进行更改:

    一个。将 org.apache.cxf.osgi.cfg 添加到 /etc 目录并设置 'org.apache.cxf.servlet.context' 属性,例如:

     org.apache.cxf.servlet.context=/custom
    

    b.使用 shell 配置命令,例如:

     config:edit org.apache.cxf.osgi   
     config:propset org.apache.cxf.servlet.context /super
     config:update
    

    【讨论】:

    • 有没有办法以编程方式做到这一点?在我的用例中,我需要运行两个 cxf 总线......有什么想法吗?
    猜你喜欢
    • 2021-04-17
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2012-09-26
    • 1970-01-01
    • 2021-10-09
    相关资源
    最近更新 更多