ConnectionOrientedTransportBindingElement.MaxPendingAccepts 属性

定义

获取或设置服务可等待许可证处理至服务的传入连接的最大通道数量。

public:
 property int MaxPendingAccepts { int get(); void set(int value); };
public int MaxPendingAccepts { get; set; }
member this.MaxPendingAccepts : int with get, set
Public Property MaxPendingAccepts As Integer

属性值

Int32

服务可拥有的侦听器上正在等待的最大通道数。 属性的默认值为 2 * 处理器数。

例外

值小于或等于零。

注解

此属性会限制服务器可具有的等待侦听器的通道数目。 当 MaxPendingAccepts 太低时,会有一个较小的时间间隔,在此间隔内,所有等待的通道都已开始服务连接,但没有新通道已开始侦听。 连接可在此间隔内到达,但将会因服务器上没有等待它的内容而失败。 可通过将 MaxPendingConnections 属性设置为较大的数字来配置此属性。

适用于