You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by mg...@apache.org on 2013/05/14 13:38:16 UTC
git commit: WICKET-5188 Use a separate logger for the extra
information logged in RequestCycle#onException()
Updated Branches:
refs/heads/master 6e794ad06 -> 81f5647c1
WICKET-5188 Use a separate logger for the extra information logged in RequestCycle#onException()
Project: http://git-wip-us.apache.org/repos/asf/wicket/repo
Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/81f5647c
Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/81f5647c
Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/81f5647c
Branch: refs/heads/master
Commit: 81f5647c1d60c0f9a643c341f99359c2cfbfb4ea
Parents: 6e794ad
Author: Martin Tzvetanov Grigorov <mg...@apache.org>
Authored: Tue May 14 14:37:58 2013 +0300
Committer: Martin Tzvetanov Grigorov <mg...@apache.org>
Committed: Tue May 14 14:37:58 2013 +0300
----------------------------------------------------------------------
.../apache/wicket/request/cycle/RequestCycle.java | 13 ++++++++++---
1 files changed, 10 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/wicket/blob/81f5647c/wicket-core/src/main/java/org/apache/wicket/request/cycle/RequestCycle.java
----------------------------------------------------------------------
diff --git a/wicket-core/src/main/java/org/apache/wicket/request/cycle/RequestCycle.java b/wicket-core/src/main/java/org/apache/wicket/request/cycle/RequestCycle.java
index b8eb565..aa6b2bc 100644
--- a/wicket-core/src/main/java/org/apache/wicket/request/cycle/RequestCycle.java
+++ b/wicket-core/src/main/java/org/apache/wicket/request/cycle/RequestCycle.java
@@ -72,6 +72,13 @@ public class RequestCycle implements IRequestCycle, IEventSink
private static final Logger log = LoggerFactory.getLogger(RequestCycle.class);
/**
+ * An additional logger which is used to log extra information.
+ * Could be disabled separately than the main logger if the application developer
+ * does not want to see this extra information.
+ */
+ private static final Logger logExtra = LoggerFactory.getLogger("RequestCycleExtra");
+
+ /**
* Returns request cycle associated with current thread.
*
* @return request cycle instance or <code>null</code> if no request cycle is associated with
@@ -337,9 +344,9 @@ public class RequestCycle implements IRequestCycle, IEventSink
* Call out the fact that we are processing an exception in a loud way, helps to notice
* them when developing even if they get wrapped or processed in a custom handler.
*/
- log.warn("********************************");
- log.warn("Handling the following exception", e);
- log.warn("********************************");
+ logExtra.warn("********************************");
+ logExtra.warn("Handling the following exception", e);
+ logExtra.warn("********************************");
}
IRequestHandler handler = listeners.onException(this, e);