[
https://issues.apache.org/jira/browse/LOG4J2-2904?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Tommy.Tesla updated LOG4J2-2904:
--------------------------------
Description:
Currently, there are following strlookups :
public Interpolator(final Map<String, String> properties) {
...
// TODO: this ought to use the PluginManager
strLookupMap.put("log4j", new Log4jLookup());
strLookupMap.put("sys", new SystemPropertiesLookup());
strLookupMap.put("env", new EnvironmentLookup());
strLookupMap.put("main", MainMapLookup.MAIN_SINGLETON);
strLookupMap.put("marker", new MarkerLookup());
strLookupMap.put("java", new JavaLookup());
strLookupMap.put("lower", new LowerLookup());
strLookupMap.put("upper", new UpperLookup());
...
BUT, at sometime, we hope to add a customized LookUp implement to resolve the
variable in log4j2.xml.
Advice: a SPI for StrLookUp could support this feature.
was:
Currently, there are following strlookups :
public Interpolator(final Map<String, String> properties) {
...
// TODO: this ought to use the PluginManager
strLookupMap.put("log4j", new Log4jLookup());
strLookupMap.put("sys", new SystemPropertiesLookup());
strLookupMap.put("env", new EnvironmentLookup());
strLookupMap.put("main", MainMapLookup.MAIN_SINGLETON);
strLookupMap.put("marker", new MarkerLookup());
strLookupMap.put("java", new JavaLookup());
strLookupMap.put("lower", new LowerLookup());
strLookupMap.put("upper", new UpperLookup());
...
BUT, somethings we hope to add a customized LookUp implement to resolve the
variable in log4j2.xml.
Advice: a SPI for StrLookUp could support this feature.
> Provide a way to add customized StrLookUps in Interpolator initialization.
> ---------------------------------------------------------------------------
>
> Key: LOG4J2-2904
> URL: https://issues.apache.org/jira/browse/LOG4J2-2904
> Project: Log4j 2
> Issue Type: Improvement
> Components: Core
> Affects Versions: 2.13.3
> Reporter: Tommy.Tesla
> Priority: Major
>
> Currently, there are following strlookups :
>
> public Interpolator(final Map<String, String> properties) {
> ...
> // TODO: this ought to use the PluginManager
> strLookupMap.put("log4j", new Log4jLookup());
> strLookupMap.put("sys", new SystemPropertiesLookup());
> strLookupMap.put("env", new EnvironmentLookup());
> strLookupMap.put("main", MainMapLookup.MAIN_SINGLETON);
> strLookupMap.put("marker", new MarkerLookup());
> strLookupMap.put("java", new JavaLookup());
> strLookupMap.put("lower", new LowerLookup());
> strLookupMap.put("upper", new UpperLookup());
> ...
>
> BUT, at sometime, we hope to add a customized LookUp implement to resolve the
> variable in log4j2.xml.
> Advice: a SPI for StrLookUp could support this feature.
>
--
This message was sent by Atlassian Jira
(v8.3.4#803005)