Set/Put value into Spring environment of Spring-boot for using later
<p>Did there have any way to set or put some values into <code>org.springframework.core.env.Environment</code>?</p>

<p>We are using Spring-boot as below version.</p>

<pre><code>&lt;parent&gt;
    &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
    &lt;artifactId&gt;spring-boot-starter-parent&lt;/artifactId&gt;
    &lt;version&gt;1.3.1.RELEASE&lt;/version&gt;
&lt;/parent&gt;
</code></pre>

<p>Spring will load <code>application.properties</code> into <code>org.springframework.core.env.Environment</code> by default. We can @Autowired Environment and getString("key") to get the value.</p>

<p>Say we have a license file and will decoding it to load the licensing period to validate if this system is still valid or not, at the <code>initialize()</code> of <code>ApplicationContextInitializer</code>.</p>

<p>We would like to save this licensing period into <code>Environment</code> for using later. For example, We will validate the licensing period again when user has sending some specified requests each time. So that, we don't have to load the license file in and decode it each time.</p>

<p>Or can we achieve this purpose in any others way which is more appropriately?</p>

<p>Any help is appreciated.</p>