部署到Azure

时间:2016-08-03 15:21:05

标签: azure azure-service-fabric

我的服务架构应用程序本地运行没问题: http://localhost:8080/api/values

当部署到Azure时,它只是坐着,我最终会超时。 http://cluster-myapp.centralus.cloudapp.azure.com/api/values

在挖掘之后,我发现了一些信息,需要使用新规则和新探测器更新Azure负载平衡器。我做到了,但仍然是同样的问题。这就是我所拥有的:

ServiceManifest.xml

  <Resources>
<Endpoints>
  <!-- This endpoint is used by the communication listener to obtain the port on which to 
       listen. Please note that if your service is partitioned, this port is shared with 
       replicas of different partitions that are placed in your code. -->
  <Endpoint Protocol="http" Name="ServiceEndpoint" Type="Input" Port="8080" />
</Endpoints>

我添加了一个探针如下:

enter image description here

...和这个LB规则

enter image description here

我没有看到任何记录,错误或任何其他内容,所以我此刻难倒。任何帮助将不胜感激。

1 个答案:

答案 0 :(得分:2)

原来我的问题是由&#34; Path&#34;在探头上设置。我的API没有默认控制器,所以路径&#34; /&#34;返回了404.

我在我的web api中创建了一个Ping控制器,并将Probe上的路径更新为&#34; / ping&#34;,这使它运行起来。

我觉得有点奇怪的是,没有&#34;健康&#34; &#34; Service Fabric Explorer&#34;中报告的问题,或者我在这里遗漏了什么?

相关问题