You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by GitBox <gi...@apache.org> on 2021/01/03 20:57:24 UTC
[GitHub] [struts] JCgH4164838Gh792C124B5 opened a new pull request #467: Proposed TextProvider feature addition (and cleanup)
JCgH4164838Gh792C124B5 opened a new pull request #467:
URL: https://github.com/apache/struts/pull/467
TextProvider feature addition and cleanup:
- Introduce (optional) control flag STRUTS_I18N_SEARCH_DEFAULTBUNDLES_FIRST to request TextProviders read from default resource bundles first, instead of their standard lookup ordering. Defaults to false.
- Minor refactor of AbstractLocalizedTextProvider hierarchy to introduce getDefaultMessageWithAlternateKey() method that repackages existing logic used by the SrutsLocalizedTextProvider and GlobalLocalizedTextProvider.
- Update GlobalLocalizedTextProvider method comments to properly reflect the actual logic of some of its methods.
- New unit tests to confirm standard and default bundle first lookup ordering.
- Cleanup of some unused imports, a few typos, and code formatting items.
- Cleanup of default.properties comments to make them more consistent.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org
[GitHub] [struts] JCgH4164838Gh792C124B5 commented on pull request #467: Proposed TextProvider feature addition (and cleanup)
Posted by GitBox <gi...@apache.org>.
JCgH4164838Gh792C124B5 commented on pull request #467:
URL: https://github.com/apache/struts/pull/467#issuecomment-753679025
Hello Apache Struts Team.
This is an initial attempt to add a feature to the I18N TextProvider hierarchy to read resource entries from the default bundles first, and then continue with "normal" lookup if nothing is found. It arose from a discussion on the developer list raised by G. Huber concerning the number of lookup calls when most resource entries are defined in the main application bundle.
This implementation allows a developer to "opt-in" to an alternative lookup strategy where the default bundles take precedence over entries anywhere else (if an entry does not exist in the default bundles, the class hierarchy bundles are then searched normally). It should be slightly more efficient for applications that only use a "global" properties file (default resource bundle), while still providing lookups along the class hierarchy for any entries that are not defined in the default (global) resource bundles. The default value of the flag is false, which preserves the normal (original) behaviour for resource lookup (requires explicitly setting the configuration to use the alternative lookup flow).
There is no JIRA yet for this item. If after reviewing this PR there is support for the change, a JIRA can be opened to cover it for tracking.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [struts] lukaszlenart merged pull request #467: Proposed TextProvider feature addition (and cleanup)
Posted by GitBox <gi...@apache.org>.
lukaszlenart merged pull request #467:
URL: https://github.com/apache/struts/pull/467
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org
[GitHub] [struts] JCgH4164838Gh792C124B5 commented on pull request #467: Proposed TextProvider feature addition (and cleanup)
Posted by GitBox <gi...@apache.org>.
JCgH4164838Gh792C124B5 commented on pull request #467:
URL: https://github.com/apache/struts/pull/467#issuecomment-754939683
A new JIRA WW-5112 has been opened to track the proposed change in this PR.
If there are any additional changes to consider, please let me know.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [struts] coveralls commented on pull request #467: Proposed TextProvider feature addition (and cleanup)
Posted by GitBox <gi...@apache.org>.
coveralls commented on pull request #467:
URL: https://github.com/apache/struts/pull/467#issuecomment-753676700
[](https://coveralls.io/builds/36049668)
Coverage increased (+0.04%) to 49.863% when pulling **f62384a471bdf93ce53d7bf9f6e86b4287f4e23a on JCgH4164838Gh792C124B5:localS2_26_TextProvider_improvement_1** into **dcc53aebf983f6c0a48932262facb81f5d82815c on apache:master**.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org