title: Spring does not find messages.properties
body: <p>I'm working on a maven project using Spring framework.</p>
  
  <p>Instead of writing raw text in JSPs I prefer to use <code>&lt;spring:message .../&gt;</code> tag and register my messages in a .properties file.</p>
  
  <p>I get this warning when requesting a page : </p>
  
  <blockquote>
    <p>ResourceBundle [messages] not found for MessageSource: Can't
    find bundle for base name messages, locale fr</p>
  </blockquote>
  
  <p>Which then brings an exception about the message not being found (obviously).</p>
  
  <p>Here's my project's hierarchy :</p>
  
  <p><a href="https://i.stack.imgur.com/XsJPl.png" rel="nofollow noreferrer">my project's hierarchy</a></p>
  
  <p>Here's my springapp-servlet.xml :</p>
  
  <pre><code>&lt;beans xmlns="http://www.springframework.org/schema/beans"
     xmlns:mvc="http://www.springframework.org/schema/mvc"
     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
     xmlns:aop="http://www.springframework.org/schema/aop"
     xmlns:context="http://www.springframework.org/schema/context"
     xsi:schemaLocation="http://www.springframework.org/schema/beans
                         http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
                         http://www.springframework.org/schema/mvc
                         http://www.springframework.org/schema/mvc/spring-mvc-4.3.xsd
                         http://www.springframework.org/schema/aop
                         http://www.springframework.org/schema/aop/spring-aop-3.0.xsd
                         http://www.springframework.org/schema/context
                         http://www.springframework.org/schema/context/spring-context-2.5.xsd"&gt;
  
  &lt;context:component-scan base-package="app.core" /&gt;
  
  &lt;bean id="viewResolver"
        class="org.springframework.web.servlet.view.InternalResourceViewResolver"&gt;
      &lt;property name="prefix" value="/WEB-INF/jsp/"&gt;
      &lt;/property&gt;
      &lt;property name="suffix" value=".jsp"&gt;
      &lt;/property&gt;
  &lt;/bean&gt;
  
  &lt;bean id="localeResolver" class="org.springframework.web.servlet.i18n.SessionLocaleResolver"&gt;
      &lt;property name="defaultLocale" value="fr" /&gt;
  &lt;/bean&gt;
  
  &lt;bean id="messageSource"
        class="org.springframework.context.support.ResourceBundleMessageSource"&gt;
      &lt;property name="basenames"&gt;
          &lt;list&gt;
              &lt;value&gt;messages&lt;/value&gt;
          &lt;/list&gt;
      &lt;/property&gt;
  &lt;/bean&gt;
  
  &lt;mvc:resources mapping="/public/**" location="/WEB-INF/resources/"
                 cache-period="31556926"/&gt;
  
  &lt;mvc:annotation-driven /&gt;
  
  &lt;/beans&gt;
  </code></pre>