gpt4 book ai didi

azure - ServiceFabric警告 "Endpoint with ExplicitPort is within application port range. This can cause port conflicts."

转载 作者:行者123 更新时间:2023-12-03 00:38:38 25 4
gpt4 key购买 nike

将我的 ServiceFabric 集群更新到版本 6.5 后,我的应用程序开始弹出警告。

Endpoint MyEndpoint with ExplicitPort 27000 is within application port range. This can cause port conflicts. Please select a port from outside application port range.

为什么会发生此错误?我需要做什么来修复它?

最佳答案

从 ServiceFabric 6.5CU2 开始,ServiceFabric 开始显示这些错误配置的警告。这些警告将来可能会变成错误。

By design static ports should not overlap with application port range specified in the ClusterManifest. If you specify a static port, assign it outside of application port range, otherwise it will result in port conflicts. With release 6.5CU2 we will issue a Health Warning when we detect such a conflict but let the deployment continue in sync with the shipped 6.5 behaviour. However, we may prevent the application deployment from the next major releases.

(https://learn.microsoft.com/en-gb/azure/service-fabric/service-fabric-service-manifest-resources)

应用程序端口范围是集群范围的,默认为 20000-30000。

您可以更改它,例如通过 ARM 模板或 https://resources.azure.com

    "nodeTypes": [
{
"name": "nt",
...

"applicationPorts": {
"startPort": 20000,
"endPort": 30000
},
...
}
],

可以在服务的 servicemanifest.json 中配置静态端点端口。

<?xml version="1.0" encoding="utf-8"?>
<ServiceManifest ...>
<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 Name="MyEndpoint" Protocol="http" Port="27000" PathSuffix="/xxx" UriScheme="http" Type="Input" />
</Endpoints>
</Resources>
</ServiceManifest>

关于azure - ServiceFabric警告 "Endpoint with ExplicitPort is within application port range. This can cause port conflicts.",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/58097093/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com