From 1d5d1a6a4a0a58d6bb4803527dacb6641c027816 Mon Sep 17 00:00:00 2001
From: Nicolas Capponi <nicolas.capponi@forgerock.com>
Date: Tue, 28 Jan 2014 13:34:12 +0000
Subject: [PATCH] Checkpoint commit for OPENDJ-1288 :    Migrate I18n and logging support to i18n framework and SLF4J

---
 opendj3-server-dev/src/server/org/opends/server/extensions/DictionaryPasswordValidator.java |   13 +++----------
 1 files changed, 3 insertions(+), 10 deletions(-)

diff --git a/opendj3-server-dev/src/server/org/opends/server/extensions/DictionaryPasswordValidator.java b/opendj3-server-dev/src/server/org/opends/server/extensions/DictionaryPasswordValidator.java
index f8f64bd..91d485d 100644
--- a/opendj3-server-dev/src/server/org/opends/server/extensions/DictionaryPasswordValidator.java
+++ b/opendj3-server-dev/src/server/org/opends/server/extensions/DictionaryPasswordValidator.java
@@ -45,8 +45,7 @@
 import org.opends.server.config.ConfigException;
 import org.opends.server.types.*;
 import org.forgerock.opendj.ldap.ByteString;
-import static org.opends.server.loggers.debug.DebugLogger.*;
-import org.opends.server.loggers.debug.DebugTracer;
+import org.forgerock.i18n.slf4j.LocalizedLogger;
 import static org.opends.messages.ExtensionMessages.*;
 import org.forgerock.i18n.LocalizableMessageBuilder;
 import static org.opends.server.util.StaticUtils.*;
@@ -61,10 +60,7 @@
        extends PasswordValidator<DictionaryPasswordValidatorCfg>
        implements ConfigurationChangeListener<DictionaryPasswordValidatorCfg>
 {
-  /**
-   * The tracer object for the debug logger.
-   */
-  private static final DebugTracer TRACER = getTracer();
+  private static final LocalizedLogger logger = LocalizedLogger.getLoggerForThisClass();
 
   // The current configuration for this password validator.
   private DictionaryPasswordValidatorCfg currentConfig;
@@ -223,10 +219,7 @@
     }
     catch (Exception e)
     {
-      if (debugEnabled())
-      {
-        TRACER.debugCaught(DebugLogLevel.ERROR, e);
-      }
+      logger.traceException(e);
 
       LocalizableMessage message = ERR_DICTIONARY_VALIDATOR_CANNOT_READ_FILE.get(
           configuration.getDictionaryFile(), String.valueOf(e));

--
Gitblit v1.10.0