<!DOCTYPE html>
<html>
<head>
<title></title>
</head>
<body><div>I don't set a content-length myself when using that method to send text (or binary) data.<br></div>
<div><br></div>
<div>-pete</div>
<div><br></div>
<div id="sig39947097"><div class="signature">--<br></div>
<div class="signature">(peter.royal|osi)@pobox.com - http://fotap.org/~osi<br></div>
</div>
<div><br></div>
<div><br></div>
<div>On Wed, Feb 8, 2017, at 10:41 AM, Hicks, Matt wrote:<br></div>
<blockquote type="cite"><div dir="ltr"><div>Well, I just added an IoCallback and now I'm getting an error:&nbsp;Attempted to write 144780 bytes however content-length has been set to 144772<br></div>
<div><br></div>
<div>This, I think, raises both a question and an issue:<br></div>
<div><br></div>
<div>Question: Should I not be setting the Content-Length myself even when using exchange.getResponseSender().send?<br></div>
<div>Issue: Seems like a bug that without an IoCallback the error is just absorbed and never logged anywhere.<br></div>
</div>
<div><br></div>
<div defang_data-gmailquote="yes"><div dir="ltr">On Wed, Feb 8, 2017 at 10:35 AM Hicks, Matt &lt;<a href="mailto:matt@matthicks.com">matt@matthicks.com</a>&gt; wrote:<br></div>
<blockquote defang_data-gmailquote="yes" style="margin-top:0px;margin-right:0px;margin-bottom:0px;margin-left:0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204, 204, 204);padding-left:1ex;"><div dir="ltr"><div>I'm having a very strange problem sending a generated HTML file back to the browser using `exchange.getResponseSender().send(s)`.&nbsp; It seems to work fine if the content is a short bit of text like "Hello World", but the content is 144,772 bytes and if I use Curl to test it I get a 200 OK, but it says the Content-Length is 0 and no content comes back.&nbsp; If I set the content to a short String like I said, then the Content-Length is properly set and the content comes back like expected.<br></div>
<div><br></div>
<div>Should I not be using `exchange.getResponseSender().send` for large amounts of text?<br></div>
<div><br></div>
<div>I just updated to 1.4.10.Final hoping that it was a bug that was fixed since 1.4.8.Final, but it's still happening.<br></div>
<div><br></div>
<div>Any insights would be greatly appreciated.<br></div>
</div>
</blockquote></div>
<div><u>_______________________________________________</u><br></div>
<div>undertow-dev mailing list<br></div>
<div><a href="mailto:undertow-dev@lists.jboss.org">undertow-dev@lists.jboss.org</a><br></div>
<div><a href="https://lists.jboss.org/mailman/listinfo/undertow-dev">https://lists.jboss.org/mailman/listinfo/undertow-dev</a><br></div>
</blockquote><div><br></div>
</body>
</html>