【问题标题】:Load balanced WCF service unavailability - Hosted as Windows Service and listen at 443 over TCP负载平衡的 WCF 服务不可用 - 作为 Windows 服务托管并通过 TCP 在 443 处侦听
【发布时间】:2023-03-25 23:57:01
【问题描述】:

我们为我们的应用程序开发了几个 WCF 服务。从我们的 Web 应用程序中,我们能够通过单个服务器到达这些端点。当我们尝试通过负载均衡器访问它们时,我们收到以下错误:

There was no endpoint listening at net.tcp://<IP>:443/<Service API> that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details.

Server stack trace: 
   at System.ServiceModel.Channels.ConnectionUpgradeHelper.DecodeFramingFault(ClientFramingDecoder decoder, IConnection connection, Uri via, String contentType, TimeoutHelper& timeoutHelper)
   at System.ServiceModel.Channels.ClientFramingDuplexSessionChannel.SendPreamble(IConnection connection, ArraySegment`1 preamble, TimeoutHelper& timeoutHelper)
   at System.ServiceModel.Channels.ClientFramingDuplexSessionChannel.DuplexConnectionPoolHelper.AcceptPooledConnection(IConnection connection, TimeoutHelper& timeoutHelper)
   at System.ServiceModel.Channels.ConnectionPoolHelper.EstablishConnection(TimeSpan timeout)
   at System.ServiceModel.Channels.ClientFramingDuplexSessionChannel.OnOpen(TimeSpan timeout)
   at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
   at System.ServiceModel.Channels.ServiceChannel.OnOpen(TimeSpan timeout)
   at System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
   at System.ServiceModel.Channels.ServiceChannel.CallOpenOnce.System.ServiceModel.Channels.ServiceChannel.ICallOnce.Call(ServiceChannel channel, TimeSpan timeout)
   at System.ServiceModel.Channels.ServiceChannel.CallOnceManager.CallOnce(TimeSpan timeout, CallOnceManager cascade)
   at System.ServiceModel.Channels.ServiceChannel.EnsureOpened(TimeSpan timeout)
   at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout)
   at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation)
   at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

附加信息:

  • WCF 服务托管为 Windows 服务
  • 443 端口上的 WCF 服务列表
  • TCP 是 Web 和服务之间的通信协议

如果我可以提供任何其他信息,请告诉我。

任何帮助将不胜感激。

【问题讨论】:

    标签: c# wcf load-balancing internal-load-balancer


    【解决方案1】:

    我有同样的问题。我设法通过将其添加到服务器端的配置文件来解决它:

      <system.net>
    <connectionManagement>
      <add address="*" maxconnection="500" />
    </connectionManagement>
    

    默认值为 2。有关更多信息,您可以阅读:scale up WCF service

    【讨论】:

      猜你喜欢
      • 2011-08-09
      • 2012-04-28
      • 2013-04-26
      • 1970-01-01
      • 2019-08-29
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2010-09-12
      相关资源
      最近更新 更多