title: ResourceBundle not found for MessageSource when placed inside a folder
body: <p>I am trying to use resource bundles with Spring's Message Source. Here is the way I am doing it:</p>
  
  <pre><code>@Component
  public class MessageResolver implements MessageSourceAware {
  
      @Autowired
      private MessageSource messageSource;
  
      public void setMessageSource(MessageSource messageSource) {
          this.messageSource = messageSource;
      }
  
      public String getMessage(){
          return messageSource.getMessage("user.welcome", new Object[]{"Rama"} , Locale.US);
      }
  
  }
  </code></pre>
  
  <p>And here is my folder structure:</p>
  
  <p><img src="https://i.stack.imgur.com/esr3a.jpg" alt="enter image description here"></p>
  
  <p>messages_en_US.properties contains just one line:</p>
  
  <pre><code>user.welcome=Welcome {0}
  </code></pre>
  
  <p>Here is the xml configuration used:</p>
  
  <pre><code>&lt;bean name="messageSource" class="org.springframework.context.support.ResourceBundleMessageSource"&gt;
      &lt;property name="basename"&gt;
          &lt;value&gt;resourcebundles/messages&lt;/value&gt;
      &lt;/property&gt;
  &lt;/bean&gt;
  </code></pre>
  
  <p>Here is the error I am getting:</p>
  
  <pre><code>WARNING: ResourceBundle [resourcebundles/messages] not found for MessageSource: Can't find bundle for base name resourcebundles/messages, locale en_US
  Exception in thread "main" org.springframework.context.NoSuchMessageException: No message found under code 'user.welcome' for locale 'en_US'.
  </code></pre>
  
  <p>But if I move my resource bundle to directly under the resources folder, it is working fine. In this case, here is the xml configuration I am using:</p>
  
  <pre><code>&lt;bean name="messageSource" class="org.springframework.context.support.ResourceBundleMessageSource"&gt;
  &lt;property name="basename"&gt;
      &lt;value&gt;messages&lt;/value&gt;
  &lt;/property&gt;
  </code></pre>
  
  <p></p>
  
  <p>Is is that if I have to use ResourceBundleMessageSource, I should put my resource bundles directly under the resources? If i have to keep it in specified folder only, is there any other way to get this one work?</p>
  
  <p>Thanks!</p>