title: Spring MVC application.properties not override by profile file application-dev.properties
body: <p>I was looking at a way to configure different application.properties file depending on a JVM environnement variable.</p>
  
  <p>I found this documentation on Spring references.</p>
  
  <blockquote>
    <p>In addition to application.properties files, profile-specific properties can also be defined using the naming convention application-{profile}.properties.</p>
    
    <p>Profile specific properties are loaded from the same locations as standard application.properties, with profile-specific files always overriding the default ones irrespective of whether the profile-specific files are inside or outside your packaged jar.</p>
  </blockquote>
  
  <p>Then I did that :</p>
  
  <p><a href="http://i.stack.imgur.com/dUz3h.png" rel="nofollow">Configuration structure</a></p>
  
  <p>And then added a <code>-Dspring.profiles.active=dev</code> to my JVM options.</p>
  
  <p><a href="http://i.stack.imgur.com/hEfHk.png" rel="nofollow">Profile option for JVM</a></p>
  
  <p>I tried to see that my params in dev are used but it isn't the case. Te application loads the data from the <code>application.properties</code> file.</p>
  
  <p>Any idea why?</p>