From 4783adc14c2d6b96260052d3b634eafa500c6ddf Mon Sep 17 00:00:00 2001
From: boli <boli@localhost>
Date: Thu, 01 Mar 2007 03:27:06 +0000
Subject: [PATCH] This removes old debug logging framework method calls that are going to be automatically instrumented by AspectJ. Non instrumented debug method calls are updated to use the new debug framework methods. However, the new debug logging framework is not yet active as the Aspects are not weaved in. After this revision, debug logging will be disabled in the server until the new AOP framework is complete.
---
opendj-sdk/opends/src/server/org/opends/server/extensions/StartTLSExtendedOperation.java | 27 ++++++++++++---------------
1 files changed, 12 insertions(+), 15 deletions(-)
diff --git a/opendj-sdk/opends/src/server/org/opends/server/extensions/StartTLSExtendedOperation.java b/opendj-sdk/opends/src/server/org/opends/server/extensions/StartTLSExtendedOperation.java
index 6430b65..769e45c 100644
--- a/opendj-sdk/opends/src/server/org/opends/server/extensions/StartTLSExtendedOperation.java
+++ b/opendj-sdk/opends/src/server/org/opends/server/extensions/StartTLSExtendedOperation.java
@@ -22,7 +22,7 @@
* CDDL HEADER END
*
*
- * Portions Copyright 2006 Sun Microsystems, Inc.
+ * Portions Copyright 2006-2007 Sun Microsystems, Inc.
*/
package org.opends.server.extensions;
@@ -41,7 +41,9 @@
import org.opends.server.types.InitializationException;
import org.opends.server.types.ResultCode;
-import static org.opends.server.loggers.Debug.*;
+import static org.opends.server.loggers.debug.DebugLogger.debugCought;
+import static org.opends.server.loggers.debug.DebugLogger.debugEnabled;
+import org.opends.server.types.DebugLogLevel;
import static org.opends.server.loggers.Error.*;
import static org.opends.server.messages.ExtensionsMessages.*;
import static org.opends.server.messages.MessageHandler.*;
@@ -59,11 +61,6 @@
public class StartTLSExtendedOperation
extends ExtendedOperationHandler
{
- /**
- * The fully-qualified name of this class for debugging purposes.
- */
- private static final String CLASS_NAME =
- "org.opends.server.extensions.StartTLSExtendedOperation";
@@ -76,7 +73,6 @@
{
super();
- assert debugConstructor(CLASS_NAME);
}
@@ -101,8 +97,6 @@
public void initializeExtendedOperationHandler(ConfigEntry configEntry)
throws ConfigException, InitializationException
{
- assert debugEnter(CLASS_NAME, "initializeExtendedOperationHandler",
- String.valueOf(configEntry));
// FIXME -- Are there any configurable options that we should support?
DirectoryServer.registerSupportedExtension(OID_START_TLS_REQUEST, this);
@@ -116,7 +110,6 @@
*/
public void finalizeExtendedOperationHandler()
{
- assert debugEnter(CLASS_NAME, "finalizeExtendedOperationHandler");
DirectoryServer.deregisterSupportedExtension(OID_START_TLS_REQUEST);
}
@@ -130,8 +123,6 @@
*/
public void processExtendedOperation(ExtendedOperation operation)
{
- assert debugEnter(CLASS_NAME, "processExtendedOperation",
- String.valueOf(operation));
// We should always include the StartTLS OID in the response (the same OID
@@ -186,7 +177,10 @@
}
catch (DirectoryException de)
{
- assert debugException(CLASS_NAME, "processExtendedOperation", de);
+ if (debugEnabled())
+ {
+ debugCought(DebugLogLevel.ERROR, de);
+ }
logError(ErrorLogCategory.CORE_SERVER, ErrorLogSeverity.MILD_ERROR,
MSGID_STARTTLS_ERROR_ON_ENABLE,
@@ -205,7 +199,10 @@
}
catch (Exception e)
{
- assert debugException(CLASS_NAME, "processExtendedOperation", e);
+ if (debugEnabled())
+ {
+ debugCought(DebugLogLevel.ERROR, e);
+ }
logError(ErrorLogCategory.CORE_SERVER, ErrorLogSeverity.MILD_ERROR,
MSGID_STARTTLS_ERROR_SENDING_CLEAR_RESPONSE,
--
Gitblit v1.10.0