我有mule应用程序版本3.8.5,当我运行studio时,它部署成功。然后我使用mvn package命令创建了一个zip包,然后该包被成功部署到了云中心空间,当我访问应用程序URL时,我在浏览器中得到以下错误:"502 Bad Gateway We‘t find any Cloudhub application listening on this API“
请在此处找到HTTP_Listener_Configuration
<http:listener-config name="HTTP_Listener_Configuration" protocol="HTTPS" host="0.0.0.0" port="8081" doc:name="HTTP Listener Configuration">
</http:listener-config>
<http:request-config name="app1" protocol="${app1.protocol}" host="${app1.host}" port="${app1.port}" basePath="/center" doc:name="HTTP Request Configuration">
<http:basic-authentication username="${app1.username}" password="${app1.password}" preemptive="true"/>
<tls:context enabledProtocols="TLSv1.2">
<tls:trust-store path="truststore.ts" password="mule" type="jks" insecure="true"/>
</tls:context>
</http:request-config>
<flow name="configurationsFlow">
<http:listener config-ref="HTTP_Listener_Configuration" path="/center" allowedMethods="GET" doc:name="HTTP"/>
<set-payload value="welocme" doc:name="Set Payload"/>
<response>
<logger level="INFO" doc:name="Logger"/>
</response>
</flow>如果有什么需要的,请告诉我。
发布于 2020-04-30 21:41:18
问题是HTTP侦听器正在端口8081上侦听,但它是为HTTPS配置的。CloudHub负载均衡器希望它在端口8082中侦听HTTPS。CloudHub最好使用预定义的属性${https.port}。对于本地部署,您需要在mule-app.properties中定义它才能工作。CloudHub将覆盖它。
https://stackoverflow.com/questions/61519212
复制相似问题