Share via


How to Change the Value for the Maximum WCF Message Size

In a three-tier deployment, if your commerce client application is receiving messages that contain large amounts of data, consider setting the maximum WCF message size (maxReceivedMessageSize parameter) to a higher value.

There are a number of factors that must be considered when determining the required value for the maximum WCF message size, such as

  • The number of items you allow inside your application.

  • The number of operations being bundled within each message.

  • The number of items in the cart.

  • The number of products shown inside a category page or a search result page.

In a site implementation based on the Microsoft SharePoint 2010 Solution Storefront, operation bundling is used to optimize performance. The number of operations contained within a message has impact on the message size.

The <binding> section of the Web.config file allows you to tune this value.

If your commerce client application is receiving messages that contain large amounts of data, set the maximum WCF message size (maxReceivedMessageSize parameter) to an appropriate size.

The following example shows the default configuration for the maximum WCF message size received from the IOperationService connection. The default value is suitable to accommodate most scenarios.

      <wsHttpBinding>
        <binding name="OperationServiceConfiguration" maxReceivedMessageSize="1000000"/>
      </wsHttpBinding>