logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Remko Popma (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (LOG4J2-1595) (GC) Avoid allocating temporary objects in Filter implementations
Date Sun, 06 Nov 2016 14:32:58 GMT

     [ https://issues.apache.org/jira/browse/LOG4J2-1595?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Remko Popma updated LOG4J2-1595:
--------------------------------
    Description: 
Review current Filter implementation classes and change them to be garbage-free where feasible.
Document on the web site which filters are garbage free and which are not.

h4. Current status

* (-) BurstFilter (allocates, non-trivial to change)
* (/) CompositeFilter (adding & removing elements produces garbage for thread safety,
no allocation in steady state)
* (/) DynamicThresholdFilter (garbage free)
* (/) LevelRangeFilter (can be garbage free after overriding unrolled vararg methods)
* MapFilter (creates iterator for each event to loop over the map. Easy to change by constructing
MapFilter with an ArrayContextData instead of a Map, and overriding unrolled vararg methods)
* (/) MarkerFilter  (can be garbage free after overriding unrolled vararg methods)
* (-) RegexFilter (not garbagefree due to JDK regex library)
* (-) ScriptFilter (not garbagefree: creates new Binding object for each event)
* StructuredDataFilter (TBD)
* ThreadContextMapFilter  (creates iterator for each event to loop over the map. Easy to change
by constructing ThreadContextMapFilter with an ArrayContextData instead of a Map, and overriding
unrolled vararg methods)
* (/) ThresholdFilter (can be garbage free after overriding unrolled vararg methods)
* TimeFilter

  was:
Review current Filter implementation classes and change them to be garbage-free where feasible.
Document on the web site which filters are garbage free and which are not.

h4. Current status

* (-) BurstFilter (allocates, non-trivial to change)
* (/) CompositeFilter (adding & removing elements produces garbage for thread safety,
no allocation in steady state)
* (/) DynamicThresholdFilter (garbage free)
* (/) LevelRangeFilter (can be garbage free after overriding unrolled vararg methods)
* MapFilter (creates iterator for each event to loop over the map. Easy to change by constructing
MapFilter with an ArrayContextData instead of a Map, and overriding unrolled vararg methods)
* (/) MarkerFilter  (can be garbage free after overriding unrolled vararg methods)
* (-) RegexFilter (not garbagefree due to JDK regex library)
* (-) ScriptFilter (not garbagefree: creates new Binding object for each event)
* StructuredDataFilter (TBD)
* ThreadContextMapFilter  (creates iterator for each event to loop over the map. Easy to change
by constructing ThreadContextMapFilter with an ArrayContextData instead of a Map, and overriding
unrolled vararg methods)
* ThresholdFilter (can be garbage free after overriding unrolled vararg methods)
* TimeFilter


> (GC) Avoid allocating temporary objects in Filter implementations
> -----------------------------------------------------------------
>
>                 Key: LOG4J2-1595
>                 URL: https://issues.apache.org/jira/browse/LOG4J2-1595
>             Project: Log4j 2
>          Issue Type: New Feature
>          Components: Filters
>    Affects Versions: 2.6.2
>            Reporter: Remko Popma
>            Assignee: Remko Popma
>             Fix For: 2.8
>
>
> Review current Filter implementation classes and change them to be garbage-free where
feasible. Document on the web site which filters are garbage free and which are not.
> h4. Current status
> * (-) BurstFilter (allocates, non-trivial to change)
> * (/) CompositeFilter (adding & removing elements produces garbage for thread safety,
no allocation in steady state)
> * (/) DynamicThresholdFilter (garbage free)
> * (/) LevelRangeFilter (can be garbage free after overriding unrolled vararg methods)
> * MapFilter (creates iterator for each event to loop over the map. Easy to change by
constructing MapFilter with an ArrayContextData instead of a Map, and overriding unrolled
vararg methods)
> * (/) MarkerFilter  (can be garbage free after overriding unrolled vararg methods)
> * (-) RegexFilter (not garbagefree due to JDK regex library)
> * (-) ScriptFilter (not garbagefree: creates new Binding object for each event)
> * StructuredDataFilter (TBD)
> * ThreadContextMapFilter  (creates iterator for each event to loop over the map. Easy
to change by constructing ThreadContextMapFilter with an ArrayContextData instead of a Map,
and overriding unrolled vararg methods)
> * (/) ThresholdFilter (can be garbage free after overriding unrolled vararg methods)
> * TimeFilter



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org


Mime
View raw message