From b0a7e3cf4a65ea95c79cf002596428d0aed2e26e Mon Sep 17 00:00:00 2001
From: boli <boli@localhost>
Date: Tue, 22 May 2007 23:30:15 +0000
Subject: [PATCH] Remove the dependence on AspectJ for all non method-entry and method-exit related debug messages. All debug statements will now work w/o weaving enabled. However, method-entry and method-exit debug messages work only with weaving enabled.
---
opends/src/server/org/opends/server/core/BindOperation.java | 31 ++++++++++++++++++-------------
1 files changed, 18 insertions(+), 13 deletions(-)
diff --git a/opends/src/server/org/opends/server/core/BindOperation.java b/opends/src/server/org/opends/server/core/BindOperation.java
index 23dda16..ce1f22a 100644
--- a/opends/src/server/org/opends/server/core/BindOperation.java
+++ b/opends/src/server/org/opends/server/core/BindOperation.java
@@ -74,9 +74,9 @@
import static org.opends.server.config.ConfigConstants.*;
import static org.opends.server.core.CoreConstants.*;
import static org.opends.server.loggers.AccessLogger.*;
-import static org.opends.server.loggers.debug.DebugLogger.debugCaught;
-import static org.opends.server.loggers.debug.DebugLogger.debugEnabled;
import static org.opends.server.loggers.ErrorLogger.*;
+import static org.opends.server.loggers.debug.DebugLogger.*;
+import org.opends.server.loggers.debug.DebugTracer;
import org.opends.server.types.DebugLogLevel;
import static org.opends.server.messages.CoreMessages.*;
import static org.opends.server.messages.MessageHandler.*;
@@ -101,6 +101,11 @@
implements PreParseBindOperation, PreOperationBindOperation,
PostOperationBindOperation, PostResponseBindOperation
{
+ /**
+ * The tracer object for the debug logger.
+ */
+ private static final DebugTracer TRACER = getTracer();
+
// The credentials used for SASL authentication.
private ASN1OctetString saslCredentials;
@@ -1031,7 +1036,7 @@
{
if (debugEnabled())
{
- debugCaught(DebugLogLevel.ERROR, de);
+ TRACER.debugCaught(DebugLogLevel.ERROR, de);
}
setResultCode(ResultCode.INVALID_CREDENTIALS);
@@ -1184,7 +1189,7 @@
{
if (debugEnabled())
{
- debugCaught(DebugLogLevel.ERROR, de);
+ TRACER.debugCaught(DebugLogLevel.ERROR, de);
}
setResultCode(ResultCode.INVALID_CREDENTIALS);
@@ -1477,7 +1482,7 @@
{
if (debugEnabled())
{
- debugCaught(DebugLogLevel.ERROR, e);
+ TRACER.debugCaught(DebugLogLevel.ERROR, e);
}
int msgID = MSGID_BIND_CANNOT_PROCESS_USER_SIZE_LIMIT;
@@ -1523,7 +1528,7 @@
{
if (debugEnabled())
{
- debugCaught(DebugLogLevel.ERROR, e);
+ TRACER.debugCaught(DebugLogLevel.ERROR, e);
}
int msgID = MSGID_BIND_CANNOT_PROCESS_USER_TIME_LIMIT;
@@ -1569,7 +1574,7 @@
{
if (debugEnabled())
{
- debugCaught(DebugLogLevel.ERROR, e);
+ TRACER.debugCaught(DebugLogLevel.ERROR, e);
}
int msgID =
@@ -1652,7 +1657,7 @@
{
if (debugEnabled())
{
- debugCaught(DebugLogLevel.ERROR, e);
+ TRACER.debugCaught(DebugLogLevel.ERROR, e);
}
int msgID = MSGID_BIND_OPERATION_PASSWORD_VALIDATION_EXCEPTION;
@@ -1743,7 +1748,7 @@
{
if (debugEnabled())
{
- debugCaught(DebugLogLevel.ERROR, de);
+ TRACER.debugCaught(DebugLogLevel.ERROR, de);
}
setResponseData(de);
@@ -1997,7 +2002,7 @@
{
if (debugEnabled())
{
- debugCaught(DebugLogLevel.ERROR, e);
+ TRACER.debugCaught(DebugLogLevel.ERROR, e);
}
int msgID = MSGID_BIND_CANNOT_PROCESS_USER_SIZE_LIMIT;
@@ -2041,7 +2046,7 @@
{
if (debugEnabled())
{
- debugCaught(DebugLogLevel.ERROR, e);
+ TRACER.debugCaught(DebugLogLevel.ERROR, e);
}
int msgID = MSGID_BIND_CANNOT_PROCESS_USER_TIME_LIMIT;
@@ -2085,7 +2090,7 @@
{
if (debugEnabled())
{
- debugCaught(DebugLogLevel.ERROR, e);
+ TRACER.debugCaught(DebugLogLevel.ERROR, e);
}
int msgID =
@@ -2169,7 +2174,7 @@
{
if (debugEnabled())
{
- debugCaught(DebugLogLevel.ERROR, de);
+ TRACER.debugCaught(DebugLogLevel.ERROR, de);
}
setResponseData(de);
--
Gitblit v1.10.0