Использую Spring MVC, сервер Tomcat 7.
При локализации сайта возникает ошибка HTTP Status 500 - javax.servlet.ServletException: javax.servlet.jsp.JspTagException: No message found under code 'home' for locale 'ru_RU'. НО я не использую русскую локализацию вообще только английский и украинский. Соответственно есть два файла messages_en.properties и messages_ua.properties.
Данная ошибка возникает только на первой страницы которая указана в на других же страницах все нормально, и смена сообщений происходит правильно.
Код -servlet.xml
<bean class="org.springframework.context.support.ReloadableResourceBundleMessageSource" id="messageSource">
<property name="basename" value="classpath:/messages"></property>
<property name="defaultEncoding" value="UTF-8"></property>
</bean>
<bean class="org.springframework.web.servlet.i18n.LocaleChangeInterceptor" id="localeChangeInterceptor">
<property name="paramName" value="lang"></property>
</bean>
<bean class="org.springframework.web.servlet.i18n.CookieLocaleResolver" id="localeResolver">
<property name="defaultLocale" value="en"></property>
</bean>
На странице index.jsp выводится <spring:message code="home"/>
.
Очищать кеш Inteliji, chrome, tomcat пробовала - не помогло.
Ссылка на гит с проектом https://github.com/seltsamD/trouble_localization
<property name="fallbackToSystemLocale" value="false"></property>
в обьявление бинаmessageSource
. Также советую переименоватьmessages_en.properties
вmessages.properties
.