Windows apps
Collapse the table of content
Expand the table of content
Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

BinaryMessageEncodingBindingElement::MaxSessionSize Property

 

Gets or sets the maximum amount of memory available within a session for optimizing transmission procedures.

Namespace:   System.ServiceModel.Channels
Assembly:  System.ServiceModel (in System.ServiceModel.dll)

public:
property int MaxSessionSize {
	int get();
	void set(int value);
}

Property Value

Type: System::Int32

The maximum size, in bytes, of a session. The default value is 2048 bytes.

Exception Condition
ArgumentOutOfRangeException

The value is less than or equal to zero.

The .NET Binary Format for XML can optimize the transmission of strings when they are used in multiple messages within a session. Once a string is sent in a message, additional messages that contain that string can refer to it using only the string's ID. This requires that the strings and their IDs be stored in memory. This allows the ID to be retransmitted in subsequent messages instead of the entire string. This lookup increases the efficiency of message transmission when using the binary format. The MaxSessionSize gets and sets the maximum amount of memory that is allocated to store these strings.

No code example is currently available or this language may not be supported.

Universal Windows Platform
Available since 8
.NET Framework
Available since 3.0
Portable Class Library
Supported in: portable .NET platforms
Return to top
Show:
© 2017 Microsoft