title: Setting message i18n dynamically in Grails
body: <p>I am trying to add some additional values into the i18n messageSource in Grails.</p>
  
  <p>The default message.properties work fine but I need some additional values loaded from a remote resource (I know it is not good, but you know, managements... ). </p>
  
  <p>I am trying to load these variables through the Boostrap.groovy
  example: </p>
  
  <pre><code>def messageSource = new StaticMessageSource()
  messageSource.addMessage("key1", new Locale("en"), "English Value")
  messageSource.addMessage("key2", new Locale("de"), "Other Language Value")
  </code></pre>
  
  <p>When I try to access them in any GSP via the </p>
  
  <pre><code>&lt;g:message code="key1" /&gt; 
  </code></pre>
  
  <p>only the key is returned, as if the values where not set at all at the StaticMessageSource. Apparently I am not having much luck with the documentation.</p>
  
  <p>There is nothing on the Grails website and almost nothing on the SpringFramework. 
  Will appreciate any suggestions.</p>
  
  <p>Anyother way to add the a set of messages to the messageSource Session!?</p>