You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by rg...@apache.org on 2022/12/29 19:21:08 UTC
[logging-log4j2] 06/07: LOG4J2-3644 - Deprecate package scanning
This is an automated email from the ASF dual-hosted git repository.
rgoers pushed a commit to branch release-2.x
in repository https://gitbox.apache.org/repos/asf/logging-log4j2.git
commit ea4cf759bcd680de489808a1827d78448c7bc11b
Author: Ralph Goers <rg...@apache.org>
AuthorDate: Mon Dec 26 21:27:28 2022 -0700
LOG4J2-3644 - Deprecate package scanning
---
.../core/config/plugins/util/PluginManager.java | 16 ++++--
src/site/xdoc/manual/appenders.xml | 60 +++++++++++-----------
src/site/xdoc/manual/configuration.xml.vm | 5 +-
src/site/xdoc/manual/filters.xml | 30 +++++------
src/site/xdoc/manual/plugins.xml | 6 +--
5 files changed, 63 insertions(+), 54 deletions(-)
diff --git a/log4j-core/src/main/java/org/apache/logging/log4j/core/config/plugins/util/PluginManager.java b/log4j-core/src/main/java/org/apache/logging/log4j/core/config/plugins/util/PluginManager.java
index abe2aa91be..8dae9cc3d4 100644
--- a/log4j-core/src/main/java/org/apache/logging/log4j/core/config/plugins/util/PluginManager.java
+++ b/log4j-core/src/main/java/org/apache/logging/log4j/core/config/plugins/util/PluginManager.java
@@ -14,13 +14,8 @@
* See the license for the specific language governing permissions and
* limitations under the license.
*/
-
package org.apache.logging.log4j.core.config.plugins.util;
-import org.apache.logging.log4j.Logger;
-import org.apache.logging.log4j.status.StatusLogger;
-import org.apache.logging.log4j.util.Strings;
-
import java.util.Collection;
import java.util.HashMap;
import java.util.LinkedHashMap;
@@ -28,6 +23,10 @@ import java.util.List;
import java.util.Map;
import java.util.concurrent.CopyOnWriteArrayList;
+import org.apache.logging.log4j.Logger;
+import org.apache.logging.log4j.status.StatusLogger;
+import org.apache.logging.log4j.util.Strings;
+
/**
* Loads and manages all the plugins.
*/
@@ -125,6 +124,9 @@ public class PluginManager {
* @since 2.1
*/
public void collectPlugins(final List<String> packages) {
+ if (isNotEmpty(packages) || isNotEmpty(PACKAGES)) {
+ LOGGER.warn("The use of package scanning to locate plugins is deprecated and will be removed in a future release");
+ }
final String categoryLowerCase = category.toLowerCase();
final Map<String, PluginType<?>> newPlugins = new LinkedHashMap<>();
@@ -173,4 +175,8 @@ public class PluginManager {
}
}
}
+
+ private boolean isNotEmpty(List<String> list) {
+ return list != null && !list.isEmpty();
+ }
}
diff --git a/src/site/xdoc/manual/appenders.xml b/src/site/xdoc/manual/appenders.xml
index 02b59dfb25..37790b0ade 100644
--- a/src/site/xdoc/manual/appenders.xml
+++ b/src/site/xdoc/manual/appenders.xml
@@ -158,7 +158,7 @@
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<File name="MyFile" fileName="logs/app.log">
<PatternLayout>
@@ -471,7 +471,7 @@ CREATE TABLE logs (
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<Console name="STDOUT" target="SYSTEM_OUT">
<PatternLayout pattern="%m%n"/>
@@ -540,7 +540,7 @@ CREATE TABLE logs (
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log" filePattern="logs/app-%d{MM-dd-yyyy}.log.gz"
ignoreExceptions="false">
@@ -701,7 +701,7 @@ CREATE TABLE logs (
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<File name="MyFile" fileName="logs/app.log">
<PatternLayout>
@@ -887,7 +887,7 @@ CREATE TABLE logs (
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<Flume name="eventLogger" compress="true">
<Agent host="192.168.10.101" port="8800"/>
@@ -907,7 +907,7 @@ CREATE TABLE logs (
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<Flume name="eventLogger" compress="true" type="persistent" dataDir="./logData">
<Agent host="192.168.10.101" port="8800"/>
@@ -928,7 +928,7 @@ CREATE TABLE logs (
Agent.
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<Flume name="eventLogger" compress="true" type="Embedded">
<Agent host="192.168.10.101" port="8800"/>
@@ -954,7 +954,7 @@ CREATE TABLE logs (
events to an embedded Flume Agent.
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="error" name="MyApp" packages="">
+<Configuration status="error" name="MyApp">
<Appenders>
<Flume name="eventLogger" compress="true" type="Embedded">
<Property name="channels">file</Property>
@@ -2237,7 +2237,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<MemoryMappedFile name="MyFile" fileName="logs/app.log">
<PatternLayout>
@@ -2820,7 +2820,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RandomAccessFile name="MyFile" fileName="logs/app.log">
<PatternLayout>
@@ -2915,7 +2915,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<Console name="STDOUT" target="SYSTEM_OUT">
<PatternLayout pattern="%m%n"/>
@@ -2957,7 +2957,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
to the MapMessage:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<Console name="STDOUT" target="SYSTEM_OUT">
<PatternLayout pattern="%m%n"/>
@@ -3520,7 +3520,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log"
filePattern="logs/$${date:yyyy-MM}/app-%d{MM-dd-yyyy}-%i.log.gz">
@@ -3543,7 +3543,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
This second example shows a rollover strategy that will keep up to 20 files before removing them.
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log"
filePattern="logs/$${date:yyyy-MM}/app-%d{MM-dd-yyyy}-%i.log.gz">
@@ -3571,7 +3571,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log"
filePattern="logs/$${date:yyyy-MM}/app-%d{yyyy-MM-dd-HH}-%i.log.gz">
@@ -3597,7 +3597,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" filePattern="logs/app-%d{yyyy-MM-dd-HH}-%i.log.gz">
<PatternLayout>
@@ -3620,7 +3620,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" filePattern="logs/app-%d{yyyy-MM-dd-HH}-%i.log.gz">
<PatternLayout>
@@ -3857,7 +3857,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Properties>
<Property name="baseDir">logs</Property>
</Properties>
@@ -3892,7 +3892,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Properties>
<Property name="baseDir">logs</Property>
</Properties>
@@ -3998,7 +3998,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="trace" name="MyApp" packages="">
+<Configuration status="trace" name="MyApp">
<Properties>
<Property name="baseDir">logs</Property>
</Properties>
@@ -4121,7 +4121,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="trace" name="MyApp" packages="">
+<Configuration status="trace" name="MyApp">
<Properties>
<Property name="baseDir">logs</Property>
</Properties>
@@ -4339,7 +4339,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingRandomAccessFile name="RollingRandomAccessFile" fileName="logs/app.log"
filePattern="logs/$${date:yyyy-MM}/app-%d{MM-dd-yyyy}-%i.log.gz">
@@ -4363,7 +4363,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
20 files before removing them.
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingRandomAccessFile name="RollingRandomAccessFile" fileName="logs/app.log"
filePattern="logs/$${date:yyyy-MM}/app-%d{MM-dd-yyyy}-%i.log.gz">
@@ -4398,7 +4398,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingRandomAccessFile name="RollingRandomAccessFile" fileName="logs/app.log"
filePattern="logs/$${date:yyyy-MM}/app-%d{yyyy-MM-dd-HH}-%i.log.gz">
@@ -4641,7 +4641,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<Flume name="AuditLogger" compress="true">
<Agent host="192.168.10.101" port="8800"/>
@@ -4796,7 +4796,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</tr>
</table>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<SMTP name="Mail" subject="Error Log" to="errors@logging.apache.org" from="test@logging.apache.org"
smtpHost="localhost" smtpPort="25" bufferSize="50">
@@ -4952,7 +4952,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
This is an unsecured TCP configuration:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<Socket name="socket" host="localhost" port="9500">
<JsonLayout properties="true"/>
@@ -4969,7 +4969,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
This is a secured <a href="#SSL">SSL</a> configuration:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<Socket name="socket" host="localhost" port="9500">
<JsonLayout properties="true"/>
@@ -5332,7 +5332,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<Syslog name="bsd" host="localhost" port="514" protocol="TCP"/>
<Syslog name="RFC5424" format="RFC5424" host="localhost" port="8514"
@@ -5356,7 +5356,7 @@ public class JpaLogEntity extends AbstractLogEventWrapperEntity {
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<Syslog name="bsd" host="localhost" port="6514" protocol="SSL">
<SSL>
diff --git a/src/site/xdoc/manual/configuration.xml.vm b/src/site/xdoc/manual/configuration.xml.vm
index d616103781..b55edd02d0 100644
--- a/src/site/xdoc/manual/configuration.xml.vm
+++ b/src/site/xdoc/manual/configuration.xml.vm
@@ -594,7 +594,10 @@ public class Bar {
</tr>
<tr>
<td>packages</td>
- <td>A comma separated list of package names to search for plugins. Plugins are only loaded
+ <td><b>Use of the packages attribute is deprecated and will be removed in Log4j 3.0.</b> Plugins
+ should be processed with the Log4j annotation processor.
+
+ A comma separated list of package names to search for plugins. Plugins are only loaded
once per classloader so changing this value may not have any effect upon reconfiguration.</td>
</tr>
<tr>
diff --git a/src/site/xdoc/manual/filters.xml b/src/site/xdoc/manual/filters.xml
index 4095188964..2714e96636 100644
--- a/src/site/xdoc/manual/filters.xml
+++ b/src/site/xdoc/manual/filters.xml
@@ -102,7 +102,7 @@
A configuration containing the BurstFilter might look like:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log"
filePattern="logs/app-%d{MM-dd-yyyy}.log.gz">
@@ -131,7 +131,7 @@
A configuration containing the CompositeFilter might look like:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Filters>
<MarkerFilter marker="EVENT" onMatch="ACCEPT" onMismatch="NEUTRAL"/>
<DynamicThresholdFilter key="loginId" defaultThreshold="ERROR"
@@ -214,7 +214,7 @@
Here is a sample configuration containing the DynamicThresholdFilter:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp" >
<DynamicThresholdFilter key="loginId" defaultThreshold="ERROR"
onMatch="ACCEPT" onMismatch="NEUTRAL">
<KeyValuePair key="User1" value="DEBUG"/>
@@ -277,7 +277,7 @@
As in this configuration, the MapFilter can be used to log particular events:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<MapFilter onMatch="ACCEPT" onMismatch="NEUTRAL" operator="or">
<KeyValuePair key="eventId" value="Login"/>
<KeyValuePair key="eventId" value="Logout"/>
@@ -303,7 +303,7 @@
logger configured is the root.
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log"
filePattern="logs/app-%d{MM-dd-yyyy}.log.gz">
@@ -330,7 +330,7 @@
logger configured is the root and the root is only configured with a single appender reference.
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log"
filePattern="logs/app-%d{MM-dd-yyyy}.log.gz">
@@ -390,7 +390,7 @@
A sample configuration that only allows the event to be written by the appender if the Marker matches:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log"
filePattern="logs/app-%d{MM-dd-yyyy}.log.gz">
@@ -458,7 +458,7 @@
A configuration containing the MutableContextMapFilter might look like:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<MutableContextMapFilter onMatch="ACCEPT" onMismatch="NEUTRAL" operator="or"
configLocation="http://localhost:8080/threadContextFilter.json" pollInterval="300">
</MutableContextMapFilter>
@@ -520,7 +520,7 @@
appender if no marker is there:</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log" filePattern="logs/app-%d{MM-dd-yyyy}.log.gz">
<NoMarkerFilter onMatch="ACCEPT" onMismatch="DENY"/>
@@ -577,7 +577,7 @@
"test":
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log"
filePattern="logs/app-%d{MM-dd-yyyy}.log.gz">
@@ -764,7 +764,7 @@
As in this configuration, the StructuredDataFilter can be used to log particular events:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<StructuredDataFilter onMatch="ACCEPT" onMismatch="NEUTRAL" operator="or">
<KeyValuePair key="id" value="Login"/>
<KeyValuePair key="id" value="Logout"/>
@@ -828,7 +828,7 @@
A configuration containing the ContextMapFilter might look like:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<ContextMapFilter onMatch="ACCEPT" onMismatch="NEUTRAL" operator="or">
<KeyValuePair key="User1" value="DEBUG"/>
<KeyValuePair key="User2" value="WARN"/>
@@ -853,7 +853,7 @@
The ContextMapFilter can also be applied to a logger for filtering:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log"
filePattern="logs/app-%d{MM-dd-yyyy}.log.gz">
@@ -914,7 +914,7 @@
A sample configuration that only allows the event to be written by the appender if the level matches:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log"
filePattern="logs/app-%d{MM-dd-yyyy}.log.gz">
@@ -983,7 +983,7 @@
day using the default timezone:
</p>
<pre class="prettyprint linenums"><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
-<Configuration status="warn" name="MyApp" packages="">
+<Configuration status="warn" name="MyApp">
<Appenders>
<RollingFile name="RollingFile" fileName="logs/app.log"
filePattern="logs/app-%d{MM-dd-yyyy}.log.gz">
diff --git a/src/site/xdoc/manual/plugins.xml b/src/site/xdoc/manual/plugins.xml
index 3254129360..094672b71a 100644
--- a/src/site/xdoc/manual/plugins.xml
+++ b/src/site/xdoc/manual/plugins.xml
@@ -50,11 +50,11 @@
the build (more details below).</li>
<li>(OSGi only) Serialized plugin listing files in each active OSGi bundle. A <code>BundleListener</code>
is added on activation to continue checking new bundles after <code>log4j-core</code> has started.</li>
- <li>A comma-separated list of packages specified by the <code>log4j.plugin.packages</code>
+ <li><b>(Deprecated)</b> A comma-separated list of packages specified by the <code>log4j.plugin.packages</code>
system property.</li>
- <li>Packages passed to the static <code>PluginManager.addPackages</code> method (before Log4j configuration
+ <li><b>(Deprecated)</b> Packages passed to the static <code>PluginManager.addPackages</code> method (before Log4j configuration
occurs).</li>
- <li>The <a href="./configuration.html#ConfigurationSyntax">packages</a> declared in your log4j2
+ <li><b>(Deprecated)</b> The <a href="./configuration.html#ConfigurationSyntax">packages</a> declared in your log4j2
configuration file.</li>
</ol>
<p>