title: Overriding default `maxSize` in domain class
body: <p>I've set a default value, for <code>maxSize</code> constraint, to all my domains, using</p>
  
  <pre><code>config.grails.gorm.default.constraints = {
      ...
      '*'(..., maxSize: 80)
      ...
  }
  </code></pre>
  
  <p>Now, I want to override this value inside my domain class; I can do that by defining it there</p>
  
  <pre><code>static constraints = {
      ...
      prop maxSize: 120
      ...
  }
  </code></pre>
  
  <p><strong>But how could I make it unlimited, for instance?</strong> </p>
  
  <p>I wish it could have been done by providing <code>-1</code>. Or the <code>String</code> and other <code>Collection</code>s could have been handled differently, by using two different <code>constraint</code>s; such as, <code>maxSize</code> or <code>maxLength</code>, or <code>maxSize</code> or <code>maxElems</code>.</p>
  
  <p>Or</p>
  
  <p><strong>Is it possible to define default <code>maxSize</code> just for <code>String</code> types, in the first place?</strong> </p>
  
  <p><strong>Note:</strong> <code>maxSize</code> works for <code>String</code> and <code>Collection</code>, both. For <code>String</code>, defining unlimited <code>maxSize</code>, doesn't make much sense, due to the size limitation on database field. But <code>Collection</code>s are used for relationships, it makes perfect sense to not have any limit here.</p>
  
  <p><strong>Edit:</strong> Somewhat, got an answer of my second question in <a href="https://stackoverflow.com/q/19432543/42769">this thread</a>, provided in the comment; but <a href="https://stackoverflow.com/a/19432976/42769">1st answer</a>, there, is a workaround and not very related to my problem, I want the <code>constraint</code>, and <a href="https://stackoverflow.com/a/19454624/42769">2nd answer</a> will work, but is not to my liking.</p>