<div dir="ltr">These two predicates from undertow are named/implemented backwards.  The &quot;max&quot; should be ensuring the provided value is at least <b>as small or smaller</b> and the &quot;min&quot; should be ensuring the provided value is at least <b>as big or bigger</b>.  But here are the descriptions of each one.<div><br><b>MinContentSizePredicate</b><br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Predicate that returns true if the Content-Size of a request is below a given value.</blockquote><br></div><div><br></div><div><b>MaxContentSizePredicate</b><br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Predicate that returns true if the Content-Size of a request is above a given value.</blockquote><div><br></div><div>So to spell it out, if someone uses the following predicate:</div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><font face="monospace">max-content-size(5)</font></blockquote><div><br></div><div>That means they are saying the maximum content size is 5 bytes.  So, here&#39;s a quick truth table:</div><div><ul><li>If content length is <b>4 bytes </b>-&gt; should return <b>true </b>(under the max)</li><li>if content length is <b>5 bytes </b>-&gt; should return <b>true </b>(at the max, but not over)</li><li>if content length is <b>6 bytes </b>-&gt; should return <b>false </b>(over the max)</li></ul></div><div>But this is the exact opposite of how these predicates have been implemented.  The javadoc matches the behavior, but not the name.</div><div><br></div><div>Can I get a quick confirmation this is, in fact, backwards before I enter a ticket and/or pull request.  Note, this will be a breaking change to fix.<br></div><div><br clear="all"><div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div></div><div>Thanks!</div><div><br></div><div>~Brad</div><div><br></div><div><b>Developer Advocate</b></div><div><i>Ortus Solutions, Corp </i></div><div><b><br></b></div><div>E-mail: <a href="mailto:brad@coldbox.org" target="_blank">brad@coldbox.org</a></div><div>ColdBox Platform: <a href="http://www.coldbox.org" target="_blank">http://www.coldbox.org</a> </div><div>Blog: <a href="http://www.codersrevolution.com" target="_blank">http://www.codersrevolution.com</a></div><div><br></div></div></div></div></div></div></div></div></div>