MtomMessageEncodingBindingElement.MaxReadPoolSize 屬性


取得或設定 XML 讀取器的數目上限,這些是配置於集區、準備用來處理傳入訊息的讀取器。Gets or sets the maximum number of XML readers that is allocated to a pool and is ready for use to process incoming messages.

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


要保存在集區中的讀取器數目上限。The maximum number of readers to be kept in the pool. 預設值為 64 個讀取器。The default value is 64 readers.


這個值小於或等於零。The value is less than or equal to zero.


增加這個數字會增加記憶體消耗量,但是可讓編碼器做好處理傳入訊息量突然暴增的準備,因為編碼器可以使用集區中已經建立的讀取器,而不必建立新的讀取器。Increasing this number increases memory consumption, but prepares the encoder to deal with sudden bursts of incoming messages because it is able to use readers from the pool that are already created instead of creating new ones.