【问题标题】:Mule Implementing API gatewayMule实现API网关
【发布时间】:2015-01-23 20:47:15
【问题描述】:

嗨,我正在运行一个应用程序

example.cloudhub.io

现在我在云集线器上创建了一个 API 并将实现 URI 作为

example.cloudhub.io

现在我如何使用soap UI访问云API网关

这个 API 网关的 URL 是什么,我在哪里可以找到它

【问题讨论】:

    标签: cloud mule esb mule-component


    【解决方案1】:

    假设您的应用程序中有一个入站 http 端点,地址为:“http://localhost:8081/order”,则 CH URL 为:“http://example.cloudhub.io/order

    HTH

    【讨论】:

    • 您好,您是说直接点击应用程序,但我希望它通过我创建的 API。 example.cloudhub.io/mypath 是应用程序路径,但在 cloudhub 中我创建了一个名为 proxy 的 API,现在我必须通过这个 API
    • 如果我的理解正确,这应该是 RAML 文件中“baseUri”条目的值。
    【解决方案2】:

    如果您的应用中有 http/https 入站端点。那么 URL 将是您使用的方案(http/https)加上域(example.cloudhub.io)加上端点路径属性或地址属性中的路径的串联。

    所以:

    <http:inbound:endpoint host="localhost" port=${http.port} path="/mypath" >
    

    应该是

    http://example.cloudhub.io/mypath

    注意分别使用 ${http.port} 和 ${https.port},它们会自动分配给 80 和 443,Cloudhub 仅支持这些端口上的传入流量。

    http://www.mulesoft.org/documentation/display/current/Developing+a+CloudHub+Application

    【讨论】:

    • 您好,您是说直接点击应用程序,但我希望它通过我创建的 API。 example.cloudhub.io/mypath 是应用程序路径,但在 cloudhub 中我创建了一个名为 proxy 的 API,现在我必须通过这个 API
    猜你喜欢
    • 2018-01-23
    • 2017-04-05
    • 2021-02-25
    • 2015-03-30
    • 1970-01-01
    • 1970-01-01
    • 2020-04-16
    • 2017-08-19
    • 2017-05-12
    相关资源
    最近更新 更多