title: Override Spring properties without using profiles
body: <p>I have few property files(application.properties) which contains both custom and spring configuration under classpath, i want load these properties based on system variables.
  I used <code>PropertySourcesPlaceholderConfigurer </code> to load properties as below.</p>
  <pre><code>@Bean
      public PropertySourcesPlaceholderConfigurer loadResources() {
  PropertySourcesPlaceholderConfigurer resourceConfigurer = new PropertySourcesPlaceholderConfigurer();
          resourceConfigurer.setLocations(new ClassPathResource(&quot;file1&quot;), new ClassPathResource(&quot;file2&quot;));
  return resourceConfigurer ;
  }
          
  </code></pre>
  <p>But it failed to override spring configuration(spring configurations added in application.properties), i want to override these files after spring picks application.properties file.
  Idea is to override spring configuration programmatically.
  How this can be achieved?</p>