When I am trying to open a report PDF in my web application, I get the below error - The maximum message size quota for incoming messages (65536) has been exceeded. To increase the quota, use the MaxReceivedMessageSize property on the appropriate binding element.

asked 07 Jun '18, 13:26

Nitin%20Chhabra's gravatar image

Nitin Chhabra
101273034
accept rate: 31%


By default, the binding configuration for Graphite Reporting Service (BasicHttpBinding_ISqlServerReporting) has maxBufferSize, maxReceivedMessageSize, maxStringContentLength set to 65536.

<binding name="BasicHttpBinding_ISqlServerReporting" closeTimeout="00:01:00" openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00" allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard" maxBufferSize="65536" maxBufferPoolSize="524288" maxReceivedMessageSize="65536" messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered" useDefaultWebProxy="true"> <readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384" maxBytesPerRead="4096" maxNameTableCharCount="16384" /> ... </binding>

To resolve this issue:
Changes have to be made to the web.config of the deployed application (in the inetpub folder).
Response limits have to be updated to 2147483647 (maxint) for the following:
1. maxBufferSize
2. maxReceivedMessageSize
3. maxStringContentLength

<binding name="BasicHttpBinding_ISqlServerReporting" closeTimeout="00:01:00" openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00" allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard" maxBufferSize="2147483647" maxBufferPoolSize="524288" maxReceivedMessageSize="2147483647" messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered" useDefaultWebProxy="true"> <readerQuotas maxDepth="32" maxStringContentLength="2147483647" maxArrayLength="16384" maxBytesPerRead="4096" maxNameTableCharCount="16384" /> ... </binding>

Updating the Response limits should let the report (pdf) show up in the application.

CAUTION: The web.config will revert to default values every time a project is built in Graphite studio.

NOTE: A future version of Graphite Studio will allow specifying these settings in Environment settings.

link

answered 07 Jun '18, 14:03

Nitin%20Chhabra's gravatar image

Nitin Chhabra
101273034
accept rate: 31%

edited 07 Jun '18, 14:15

ChrisG's gravatar image

ChrisG
1001k798289

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×2
×2
×1
×1

Asked: 07 Jun '18, 13:26

Seen: 2,533 times

Last updated: 07 Jun '18, 14:15

Powered By:   Graphite