Remko Popma created LOG4J2-1629:
-----------------------------------
Summary: Support for primitive values in StringMap
Key: LOG4J2-1629
URL: https://issues.apache.org/jira/browse/LOG4J2-1629
Project: Log4j 2
Issue Type: Improvement
Reporter: Remko Popma
Assignee: Remko Popma
For some applications like financial trading systems, highly interactive games
or numerical computation-heavy scientific applications, a large portion of data
is stored in primitives. Applications like this sometimes need to set such
values in the logging context (e.g., order ID, algo strategy instance ID, etc)
and would prefer to avoid the overhead of boxing/unboxing these primitives.
Building on top of the work done for LOG4J2-1447 and LOG4J2-1349, this ticket
proposes to add the following methods to the StringMap interface:
{code}
// StringMap additional methods
long getLong(String key);
boolean containsLong(String key);
/** What should {@link #getLong()} return if the map
* doesn't have a long value for the specified key?
*/
long getDefaultLong();
void setDefaultLong(long defaultValue);
{code}
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]