You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by sw...@apache.org on 2026/10/18 03:54:52 UTC

(logging-log4cxx) 01/01: Document behaviour changes in 2.0

This is an automated email from the ASF dual-hosted git repository.

swebb2066 pushed a commit to branch document_behaviour_changes
in repository https://gitbox.apache.org/repos/asf/logging-log4cxx.git

commit f052b8ceef1037ff1411791abb5783ca3b4c56bc
Author: Stephen Webb <sw...@gmail.com>
AuthorDate: Sun Oct 18 14:54:30 2026 +1100

    Document behaviour changes in 2.0
---
 src/main/cpp/defaultconfigurator.cpp           | 14 +-------------
 src/main/include/log4cxx/defaultconfigurator.h |  6 +++---
 src/site/markdown/change-report-gh.md          |  8 ++++++++
 3 files changed, 12 insertions(+), 16 deletions(-)

diff --git a/src/main/cpp/defaultconfigurator.cpp b/src/main/cpp/defaultconfigurator.cpp
index 9d56a8ab..23eec327 100644
--- a/src/main/cpp/defaultconfigurator.cpp
+++ b/src/main/cpp/defaultconfigurator.cpp
@@ -119,12 +119,7 @@ ConfigurationStatus DefaultConfigurator::configure(const LoggerRepositoryPtr& re
 
 const LogString DefaultConfigurator::getConfiguratorClass()
 {
-	auto result = System::getProperty(LOG4CXX_STR("LOG4CXX_CONFIGURATOR_CLASS"));
-#if LOG4CXX_VERSION_MAJOR <= 1
-	if (result.empty())
-		result = System::getProperty(LOG4CXX_STR("log4j.configuratorClass"));
-#endif
-	return result;
+	return System::getProperty(LOG4CXX_STR("LOG4CXX_CONFIGURATOR_CLASS"));
 }
 
 
@@ -138,13 +133,6 @@ const LogString DefaultConfigurator::getConfigurationFileName()
 		configurationFileName = System::getProperty(LOG4CXX_STR("LOG4CXX_CONFIGURATION"));
 		isEnvVar = true;
 	}
-#if LOG4CXX_VERSION_MAJOR <= 1
-	if (configurationFileName.empty())
-	{
-		configurationFileName = System::getProperty(LOG4CXX_STR("log4j.configuration"));
-		isEnvVar = true;
-	}
-#endif
 #if !LOG4CXX_EXPAND_CONFIG_ENV_VAR
 	if (isEnvVar)
 		return configurationFileName;
diff --git a/src/main/include/log4cxx/defaultconfigurator.h b/src/main/include/log4cxx/defaultconfigurator.h
index 41e38a8a..d9903a77 100644
--- a/src/main/include/log4cxx/defaultconfigurator.h
+++ b/src/main/include/log4cxx/defaultconfigurator.h
@@ -39,7 +39,7 @@ class LOG4CXX_EXPORT DefaultConfigurator
 		Configure \c repository.
 
 		If the configuration file name has not been provided by a call to setConfigurationFileName(),
-		the environment variable "LOG4CXX_CONFIGURATION" or "log4j.configuration" value is used,
+		the environment variable "LOG4CXX_CONFIGURATION" value is used,
 		with ${varname} instances using either a system environment variable value (if found)
 		otherwise using the helpers::Properties object
 		provided by spi::Configurator::properties.
@@ -50,8 +50,8 @@ class LOG4CXX_EXPORT DefaultConfigurator
 		~~~
 
 		Unless a custom configurator is specified using the
-		"LOG4CXX_CONFIGURATOR_CLASS" or "log4j.configuratorClass"
-		environment variable, the PropertyConfigurator will be used to
+		"LOG4CXX_CONFIGURATOR_CLASS" environment variable,
+		the PropertyConfigurator will be used to
 		configure log4cxx unless the file name ends with the ".xml"
 		extension, in which case the DOMConfigurator will be used. If a
 		custom configurator is specified, the environment variable should
diff --git a/src/site/markdown/change-report-gh.md b/src/site/markdown/change-report-gh.md
index 815d99d7..3da9d02e 100644
--- a/src/site/markdown/change-report-gh.md
+++ b/src/site/markdown/change-report-gh.md
@@ -103,6 +103,14 @@ The following issues have been addressed:
    * [#629](https://github.com/apache/logging-log4cxx/pull/629)
    , [#637](https://github.com/apache/logging-log4cxx/pull/637)
 
+The other Log4cxx behaviour changes are:
+
+* Use 'find_package(log4cxx COMPONENTS qt)' instead of 'find_package(log4cxx-qt)' to access Log4cxx Qt support
+  \[[#600](https://github.com/apache/logging-log4cxx/pull/600)\]
+
+* The environment variables 'log4j.configuration' and 'log4j.configuratorClass' are no longer checked during default configuration
+  \[[#784](https://github.com/apache/logging-log4cxx/pull/784)\]
+
 ## Release 1.8.0 - 2026-07-29 {#rel_1_8_0}
 
 Release 1.8.0 includes the following new features: