From 455897cc245b67d929f409a93cfa7106e835cc1f 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.
---
opends/src/server/org/opends/server/schema/MatchingRuleUseSyntax.java | 41 +++++++----------------------------------
1 files changed, 7 insertions(+), 34 deletions(-)
diff --git a/opends/src/server/org/opends/server/schema/MatchingRuleUseSyntax.java b/opends/src/server/org/opends/server/schema/MatchingRuleUseSyntax.java
index c28dd53..991041f 100644
--- a/opends/src/server/org/opends/server/schema/MatchingRuleUseSyntax.java
+++ b/opends/src/server/org/opends/server/schema/MatchingRuleUseSyntax.java
@@ -50,7 +50,9 @@
import org.opends.server.types.ResultCode;
import org.opends.server.types.Schema;
-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.messages.MessageHandler.*;
import static org.opends.server.messages.SchemaMessages.*;
import static org.opends.server.schema.SchemaConstants.*;
@@ -66,11 +68,6 @@
public class MatchingRuleUseSyntax
extends AttributeSyntax
{
- /**
- * The fully-qualified name of this class for debugging purposes.
- */
- private static final String CLASS_NAME =
- "org.opends.server.schema.MatchingRuleUseSyntax";
@@ -95,7 +92,6 @@
{
super();
- assert debugConstructor(CLASS_NAME);
}
@@ -106,8 +102,6 @@
public void initializeSyntax(ConfigEntry configEntry)
throws ConfigException, InitializationException
{
- assert debugEnter(CLASS_NAME, "initializeSyntax",
- String.valueOf(configEntry));
defaultEqualityMatchingRule =
DirectoryServer.getEqualityMatchingRule(EMR_CASE_IGNORE_OID);
@@ -147,7 +141,6 @@
*/
public String getSyntaxName()
{
- assert debugEnter(CLASS_NAME, "getSyntaxName");
return SYNTAX_MATCHING_RULE_USE_NAME;
}
@@ -159,7 +152,6 @@
*/
public String getOID()
{
- assert debugEnter(CLASS_NAME, "getOID");
return SYNTAX_MATCHING_RULE_USE_OID;
}
@@ -171,7 +163,6 @@
*/
public String getDescription()
{
- assert debugEnter(CLASS_NAME, "getDescription");
return SYNTAX_MATCHING_RULE_USE_DESCRIPTION;
}
@@ -183,7 +174,6 @@
*/
public EqualityMatchingRule getEqualityMatchingRule()
{
- assert debugEnter(CLASS_NAME, "getEqualityMatchingRule");
return defaultEqualityMatchingRule;
}
@@ -195,7 +185,6 @@
*/
public OrderingMatchingRule getOrderingMatchingRule()
{
- assert debugEnter(CLASS_NAME, "getOrderingMatchingRule");
return defaultOrderingMatchingRule;
}
@@ -207,7 +196,6 @@
*/
public SubstringMatchingRule getSubstringMatchingRule()
{
- assert debugEnter(CLASS_NAME, "getSubstringMatchingRule");
return defaultSubstringMatchingRule;
}
@@ -219,7 +207,6 @@
*/
public ApproximateMatchingRule getApproximateMatchingRule()
{
- assert debugEnter(CLASS_NAME, "getApproximateMatchingRule");
// There is no approximate matching rule by default.
return null;
@@ -233,8 +220,6 @@
public boolean valueIsAcceptable(ByteString value,
StringBuilder invalidReason)
{
- assert debugEnter(CLASS_NAME, "valueIsAcceptable", String.valueOf(value),
- "java.lang.StringBuilder");
// We'll use the decodeMatchingRuleUse method to determine if the value is
@@ -246,7 +231,10 @@
}
catch (DirectoryException de)
{
- assert debugException(CLASS_NAME, "valueIsAcceptable", de);
+ if (debugEnabled())
+ {
+ debugCought(DebugLogLevel.ERROR, de);
+ }
invalidReason.append(de.getErrorMessage());
return false;
@@ -283,8 +271,6 @@
boolean allowUnknownElements)
throws DirectoryException
{
- assert debugEnter(CLASS_NAME, "decodeMatchingRuleUse",
- String.valueOf(value));
// Get string representations of the provided value using the provided form
@@ -689,8 +675,6 @@
int startPos)
throws DirectoryException
{
- assert debugEnter(CLASS_NAME, "readTokenName", String.valueOf(valueStr),
- "java.lang.StringBuilder", String.valueOf(startPos));
// Skip over any spaces at the beginning of the value.
@@ -752,8 +736,6 @@
StringBuilder valueBuffer, int startPos)
throws DirectoryException
{
- assert debugEnter(CLASS_NAME, "readQuotedString", String.valueOf(valueStr),
- "java.lang.StringBuilder", String.valueOf(startPos));
// Skip over any spaces at the beginning of the value.
@@ -843,9 +825,6 @@
StringBuilder lowerBuffer, int startPos)
throws DirectoryException
{
- assert debugEnter(CLASS_NAME, "readQuotedString", String.valueOf(valueStr),
- String.valueOf(lowerStr), "java.lang.StringBuilder",
- "java.lang.StringBuilder", String.valueOf(startPos));
// Skip over any spaces at the beginning of the value.
@@ -929,8 +908,6 @@
int startPos)
throws DirectoryException
{
- assert debugEnter(CLASS_NAME, "readWOID", String.valueOf(lowerStr),
- "java.lang.StringBuilder", String.valueOf(startPos));
@@ -1086,10 +1063,6 @@
List<String> valueList, int startPos)
throws DirectoryException
{
- assert debugEnter(CLASS_NAME, "readExtraParameterValues",
- String.valueOf(valueStr),
- "java.util.concurrent.CopyOnWriteArrayList<String>",
- String.valueOf(startPos));
// Skip over any leading spaces.
--
Gitblit v1.10.0