【发布时间】:2017-10-01 09:55:15
【问题描述】:
您如何配置不同的应用程序实例?我知道您可以参数化ApplicationManifest 和服务Config 包,但是如何在两个不同的应用程序实例中为Web 服务指定不同的端口? webservice 的端点在ServiceManifest 中定义,无法参数化 afaik。
<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="80" />
</Endpoints>
</Resources>
假设我有一个应用程序类型MyAppType,其中包含一个服务类型MyWebSvcType。我创建了应用程序类型MyAppTenant1 和MyAppTenant2 的两个实例。如何指定MyAppTenant1的webservice监听80端口,MyAppTenant2的webservice监听81端口。这是因为它们可能在同一个节点上,因此应该监听不同的端口。
【问题讨论】:
标签: .net web-services azure-service-fabric