<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Entity is too large problem]]></title><description><![CDATA[<p>Hi, I'm using jsreport 1.4.0 on windows system. I hit an error of entity is too large. The data sent to jsreport is 29Mb, I read the article that by default the limit is 20 Mb. I googled a lot and found a configuration settings, so I added a settings as below to both &quot;dev.config.json&quot; and &quot;prod.config.json&quot;</p>
<pre><code>    &quot;express&quot;: {
        &quot;inputRequestLimit&quot;: &quot;50mb&quot;
    }
</code></pre>
<p>Now from the log, it throws:</p>
<pre><code>2018-09-14T00:21:40.593Z - error: Error during processing request: http://172.20.42.42:3000/api/report details: request aborted Error: request aborted
    at IncomingMessage.onAborted (C:\Websites\Reports\node_modules\jsreport\node_modules\jsreport-express\node_modules\body-parser\node_modules\raw-body\index.js:270:10)
    at emitNone (events.js:67:13)
    at IncomingMessage.emit (events.js:166:7)
    at abortIncoming (_http_server.js:284:11)
    at Socket.serverSocketCloseListener (_http_server.js:297:5)
    at emitOne (events.js:82:20)
    at Socket.emit (events.js:169:7)
    at TCP._onclose (net.js:486:12)
</code></pre>
<p>We have commercial licence. Can anyone help me how do I increase the request limit? If I did correctly, how can I avoid the &quot;request aborted&quot; error. I know the latest version of jsreport is 2.2, but it seems a big job to upgrade. So try upgrade would be my last choice.</p>
<p>Thanks in advance for any help.</p>
]]></description><link>https://forum.jsreport.net/topic/721/entity-is-too-large-problem</link><generator>RSS for Node</generator><lastBuildDate>Tue, 19 May 2026 04:18:06 GMT</lastBuildDate><atom:link href="https://forum.jsreport.net/topic/721.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 14 Sep 2018 03:11:13 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Entity is too large problem on Invalid Date]]></title><description><![CDATA[<p>Hi, I'm using jsreport 1.4.0 on windows system. I hit an error of entity is too large. The data sent to jsreport is 29Mb, I read the article that by default the limit is 20 Mb. I googled a lot and found a configuration settings, so I added a settings as below to both &quot;dev.config.json&quot; and &quot;prod.config.json&quot;</p>
<pre><code>    &quot;express&quot;: {
        &quot;inputRequestLimit&quot;: &quot;50mb&quot;
    }
</code></pre>
<p>Now from the log, it throws:</p>
<pre><code>2018-09-14T00:21:40.593Z - error: Error during processing request: http://172.20.42.42:3000/api/report details: request aborted Error: request aborted
    at IncomingMessage.onAborted (C:\Websites\Reports\node_modules\jsreport\node_modules\jsreport-express\node_modules\body-parser\node_modules\raw-body\index.js:270:10)
    at emitNone (events.js:67:13)
    at IncomingMessage.emit (events.js:166:7)
    at abortIncoming (_http_server.js:284:11)
    at Socket.serverSocketCloseListener (_http_server.js:297:5)
    at emitOne (events.js:82:20)
    at Socket.emit (events.js:169:7)
    at TCP._onclose (net.js:486:12)
</code></pre>
<p>We have commercial licence. Can anyone help me how do I increase the request limit? If I did correctly, how can I avoid the &quot;request aborted&quot; error. I know the latest version of jsreport is 2.2, but it seems a big job to upgrade. So try upgrade would be my last choice.</p>
<p>Thanks in advance for any help.</p>
]]></description><link>https://forum.jsreport.net/post/3588</link><guid isPermaLink="true">https://forum.jsreport.net/post/3588</guid><dc:creator><![CDATA[cairabbit]]></dc:creator><pubDate>Invalid Date</pubDate></item><item><title><![CDATA[Reply to Entity is too large problem on Invalid Date]]></title><description><![CDATA[<p>Your configuration is correct.</p>
<p>The &quot;request aborted&quot; should mean that the client sending data disconnected before the input data stream was fully parsed.<br />
Try to check your client code.</p>
]]></description><link>https://forum.jsreport.net/post/3593</link><guid isPermaLink="true">https://forum.jsreport.net/post/3593</guid><dc:creator><![CDATA[jan_blaha]]></dc:creator><pubDate>Invalid Date</pubDate></item><item><title><![CDATA[Reply to Entity is too large problem on Invalid Date]]></title><description><![CDATA[<p>Hi Jan,<br />
Thanks for reply. My client codes work well before I put the settings. The report returns correct data if I select date range from 1 Jan 2018 to 1 Jun 2018. But throw an error of &quot;entity is too large&quot; error if I select date range from 1 Jan 2018 to 10 Aug 2018. So I added the settings, then it throws the above error. At my client side code (c#), I increased the timeout to 10 mins. Below is my client code to get the report:</p>
<pre><code>        public HttpResponseMessage RenderReport(string format, ReportResult data)
        {
            var view = _report.ViewFormats.FirstOrDefault(o =&gt; o.FormatName.ToLower() == format.ToLower());
            if (view == null)
            {
                view = _report.DefaultViewFormat;
            }

            var client = new WebClient2()
            {
                Timeout = 600000
            };
            client.Headers.Add(HttpRequestHeader.ContentType, &quot;application/json&quot;);

            dynamic rptData = new ExpandoObject();
            rptData.template = new ExpandoObject();
            rptData.template.shortid = view.ViewName;
            if (!string.IsNullOrEmpty(view.ViewType))
            {
                rptData.template.recipe = view.ViewType;
                rptData.options = new Dictionary&lt;string, string&gt;()
                {
                    { &quot;Content-Disposition&quot;, $&quot;attachment; filename={_report.ReportName}.{view.FormatName}&quot; }
                };
            }
            rptData.data = data;
            var obj = Newtonsoft.Json.JsonConvert.SerializeObject(rptData);
            byte[] result = client.UploadData(ProviderService.Config.ReportHost, System.Text.UTF8Encoding.UTF8.GetBytes(obj));
            var responseContentType = client.ResponseHeaders.GetValues(&quot;content-type&quot;).FirstOrDefault();
            if (responseContentType == &quot;application/vnd.openxmlformats-officedocument.spreadsheetml.sheetf&quot;)
                responseContentType = &quot;application/vnd.openxmlformats-officedocument.spreadsheetml.sheet&quot;;

            var response = new HttpResponseMessage(HttpStatusCode.OK);
            if (responseContentType == &quot;text/html&quot;)
            {
                response.Content = new StringContent(System.Text.UTF8Encoding.UTF8.GetString(result));
            } else
            {
                response.Content = new ByteArrayContent(result);
                response.Content.Headers.ContentDisposition = new ContentDispositionHeaderValue(&quot;attachment&quot;)
                {
                    FileName = $&quot;{_report.ReportName}.{view.FormatName}&quot;
                };
            }
            response.Content.Headers.ContentType = new MediaTypeHeaderValue(responseContentType);
            response.Content.Headers.ContentLength = result.Length;
            return response;
        }
</code></pre>
<p>Could you please have a look?</p>
<p>Thanks.<br />
Chunsheng Cai</p>
]]></description><link>https://forum.jsreport.net/post/3611</link><guid isPermaLink="true">https://forum.jsreport.net/post/3611</guid><dc:creator><![CDATA[cairabbit]]></dc:creator><pubDate>Invalid Date</pubDate></item><item><title><![CDATA[Reply to Entity is too large problem on Invalid Date]]></title><description><![CDATA[<p>Hm. I don't use WebClient2. So not sure what is the issue.<br />
You can try to make a request from a different lib if it helps.</p>
]]></description><link>https://forum.jsreport.net/post/3622</link><guid isPermaLink="true">https://forum.jsreport.net/post/3622</guid><dc:creator><![CDATA[jan_blaha]]></dc:creator><pubDate>Invalid Date</pubDate></item><item><title><![CDATA[Reply to Entity is too large problem on Invalid Date]]></title><description><![CDATA[<p>Hi Jan,<br />
The WebClient2 is just a class that inherited from normal .net WebClient, it just exposes the timeout for adjustment. Nothing special. You can just consider it as a normal WebClient. Here is WebClient2 code:</p>
<pre><code>    public class WebClient2 : WebClient
    {
        protected override WebRequest GetWebRequest(Uri address)
        {
            var request = base.GetWebRequest(address);
            request.Timeout = Timeout;
            return request;
        }

        public int Timeout { get; set; } = 300000;
    }
</code></pre>
]]></description><link>https://forum.jsreport.net/post/3631</link><guid isPermaLink="true">https://forum.jsreport.net/post/3631</guid><dc:creator><![CDATA[cairabbit]]></dc:creator><pubDate>Invalid Date</pubDate></item><item><title><![CDATA[Reply to Entity is too large problem on Invalid Date]]></title><description><![CDATA[<p>Hm. I don't know. We use HttpClient in jsreport c# sdk.<br />
Maybe you can ask in an c# forum why WebClient aborts the request.</p>
]]></description><link>https://forum.jsreport.net/post/3633</link><guid isPermaLink="true">https://forum.jsreport.net/post/3633</guid><dc:creator><![CDATA[jan_blaha]]></dc:creator><pubDate>Invalid Date</pubDate></item><item><title><![CDATA[Reply to Entity is too large problem on Invalid Date]]></title><description><![CDATA[<p>Hi Jan,</p>
<p>You're right. I changed it to use HttpClient, now it works.</p>
<p>Thanks a lot.</p>
]]></description><link>https://forum.jsreport.net/post/3639</link><guid isPermaLink="true">https://forum.jsreport.net/post/3639</guid><dc:creator><![CDATA[cairabbit]]></dc:creator><pubDate>Invalid Date</pubDate></item></channel></rss>