[gatein-issues] [JBoss JIRA] (GTNPORTAL-2852) Clean up and improve the usage of Resource Bundle files

Trong Tran (JIRA) jira-events at lists.jboss.org
Mon Mar 25 06:15:42 EDT 2013


    [ https://issues.jboss.org/browse/GTNPORTAL-2852?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12762879#comment-12762879 ] 

Trong Tran commented on GTNPORTAL-2852:
---------------------------------------

We find that removing of *_en.properties and only keeping base ones will raise an issue: English translations would not be displayed anymore when specifically requested (by the browser or by the user setting) IF "en" is not the default locale of GateIn.
The big issue by removing "_en" is that information is simply *lost*. The system doesn't know anymore that the base bundle file is English locale.

Therefore we decided to keep *_en* bundle files only (do NOT generate base ones anymore) AND the *_en* locale will be taken as a last fallback locale by ResourceBundleService.

So the overall sequence of candidate locales will be :
- User locale
- Portal locale
- Base files
- *_en* locale
                
> Clean up and improve the usage of Resource Bundle files
> -------------------------------------------------------
>
>                 Key: GTNPORTAL-2852
>                 URL: https://issues.jboss.org/browse/GTNPORTAL-2852
>             Project: GateIn Portal
>          Issue Type: Task
>      Security Level: Public(Everyone can see) 
>          Components: Internationalization and Localization
>    Affects Versions: 3.5.0.Final
>            Reporter: Trong Tran
>             Fix For: 3.6.0.Final
>
>
> Basically, there are two things :
> 1. Remove ant configuration in the root POM which copies all *_en.properties to the base ones (webui_en.properties to webui.properties for instance). The copy is not efficient and not a clean way to maintain resource bundle files. What we need is just to keep the base properties file only, the default English language properties should be loaded fallback by the base one normally.
> 2. Move resource bundle files from src/main/webapp/WEB-INF/classes to src/main/resources. It is more compliant to Maven standard structure.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the gatein-issues mailing list