--- java/src/com/postgres/util/Logger/LogRepl.java~	2003-08-26 22:02:32.000000000 +0300
+++ java/src/com/postgres/util/Logger/LogRepl.java	2003-08-29 21:16:28.000000000 +0300
@@ -26,51 +26,51 @@
         appenderProperties.put("log4j.appender.A2.layout","org.apache.log4j.TTCCLayout");
         appenderProperties.put("log4j.appender.A2.layout.ContextPrinting","true");
         appenderProperties.put("log4j.appender.A2.layout.DateFormat","ISO8601");
-        appenderProperties.put("log4j.rootCategory","DEBUG,A2");
+        appenderProperties.put("log4j.rootLogger","DEBUG,A2");
     }
 
-    private static MyCategory categoryR = null;
+    private static MyLogger loggerR = null;
     private static boolean initialized;
 
     private static String replicHome;
 
-    public void warn(Object value) { getCategory().warn(value); }
+    public void warn(Object value) { getLogger().warn(value); }
 
     public void warn(Object value, Throwable t)
-    { getCategory().warn(value, t); }
+    { getLogger().warn(value, t); }
 
-    public void error(Object value) { getCategory().error(value); }
+    public void error(Object value) { getLogger().error(value); }
 
     public void error(Object value, Throwable t)
-    { getCategory().error(value, t); }
+    { getLogger().error(value, t); }
 
-    public void debug(Object value) { getCategory().debug(value); }
+    public void debug(Object value) { getLogger().debug(value); }
 
     public void debug(Object value, Throwable t)
-    { getCategory().debug(value, t); }
+    { getLogger().debug(value, t); }
 
-    public void fatal(Object value) { getCategory().fatal(value); }
+    public void fatal(Object value) { getLogger().fatal(value); }
 
     public void fatal(Object value, Throwable t)
-    { getCategory().fatal(value, t); }
+    { getLogger().fatal(value, t); }
 
-    public void info(Object value) { getCategory().info(value); }
+    public void info(Object value) { getLogger().info(value); }
 
     public void info(Object value, Throwable t)
-    { getCategory().info(value, t); }
+    { getLogger().info(value, t); }
 
-    public void log(Throwable value) { getCategory().error(value); }
+    public void log(Throwable value) { getLogger().error(value); }
 
-    public void log(String value) { getCategory().debug(value); }
+    public void log(String value) { getLogger().debug(value); }
 
     public void log(Object value) {
         if (value instanceof Collection) {
             for (Iterator it = ((Collection)value).iterator(); it.hasNext(); ) {
-                getCategory().debug(it.next());
+                getLogger().debug(it.next());
             }
         }
         else {
-            getCategory().debug(value);
+            getLogger().debug(value);
         }
     }
 
@@ -99,7 +99,7 @@
         replicHome = areplicHome;
 
         //start the logger:
-        getCategory();
+        getLogger();
         initialized = true;
     }
 
@@ -155,12 +155,12 @@
         return appenderProperties;
     }
 
-    private static Category getCategory() {
-        if (!initialized && categoryR != null) {
-            System.out.println("LogRepl::getCategory: Logger is not initialized!");
+    private static org.apache.log4j.Logger getLogger() {
+        if (!initialized && loggerR != null) {
+            System.out.println("LogRepl::getLogger: Logger is not initialized!");
             System.exit(3);
         }
-        if (categoryR == null) {
+        if (loggerR == null) {
             synchronized(LogRepl.class) {
                 try {
                     Properties fileProperties = loadConfig();
@@ -179,10 +179,10 @@
                          relativeName = fileProperties.get("log4j.appender.A2.File") == null ? relativeName : (String) fileProperties.get("log4j.appender.A2.File");
                     }
                     String logPath = replicHome + "/" + relativeName;
-                    if (debug) System.out.println("LogRepl::getCategory: logPath="+logPath);
-                    if (debug) System.out.println("LogRepl::getCategory: BEFORE put get(log4j.appender.A2.File)="+appenderProperties.get("log4j.appender.A2.File"));
+                    if (debug) System.out.println("LogRepl::getLogger: logPath="+logPath);
+                    if (debug) System.out.println("LogRepl::getLogger: BEFORE put get(log4j.appender.A2.File)="+appenderProperties.get("log4j.appender.A2.File"));
                     appenderProperties.put("log4j.appender.A2.File", logPath);
-                    if (debug) System.out.println("LogRepl::getCategory: AFTER put get(log4j.appender.A2.File)="+appenderProperties.get("log4j.appender.A2.File")+"\n");
+                    if (debug) System.out.println("LogRepl::getLogger: AFTER put get(log4j.appender.A2.File)="+appenderProperties.get("log4j.appender.A2.File")+"\n");
 
                     makeDir(logPath) ;
 
@@ -203,34 +203,34 @@
                     PropertyConfigurator.configure(appenderProperties);
                 }
                 catch (Exception xcp) {
-                    Category root = Category.getRoot();
+                    org.apache.log4j.Logger root =
+                        org.apache.log4j.Logger.getRootLogger();
                     Layout layout = new TTCCLayout();
-                    root.addAppender(
-                        new FileAppender(layout, System.out));
+                    root.addAppender(new ConsoleAppender(layout));
                 }
 
-                categoryR = (MyCategory)MyCategory.getInstance("replic");
-                categoryR.debug("LOGGER STARTED");
+                loggerR = (MyLogger)MyLogger.getLogger("replic");
+                loggerR.debug("LOGGER STARTED");
             }
         }
 
-        return categoryR;
+        return loggerR;
     }
 
-    private static class MyCategory extends Category {
+    private static class MyLogger extends org.apache.log4j.Logger {
         private static MyFactory g_factory = new MyFactory();
 
-        public MyCategory(String name) { super(name); }
+        public MyLogger(String name) { super(name); }
 
-        public static Category getInstance(String name) {
-            return Category.getInstance(name, g_factory);
+        public static org.apache.log4j.Logger getLogger(String name) {
+            return org.apache.log4j.Logger.getLogger(name, g_factory);
         }
     }
 
 
-    private static class MyFactory implements CategoryFactory {
-        public Category makeNewCategoryInstance(String name) {
-            return new MyCategory(name);
+    private static class MyFactory implements LoggerFactory {
+        public org.apache.log4j.Logger makeNewLoggerInstance(String name) {
+            return new MyLogger(name);
         }
     }
 
--- etc/repliclog.cfg~	2003-08-26 22:00:39.000000000 +0300
+++ etc/repliclog.cfg	2003-08-29 21:35:04.000000000 +0300
@@ -2,12 +2,12 @@
 # Do not change the appender prefix: log4j.appender.A2
 ######################################################
 #### DEBUG,A2 is used to log in file only:
-# log4j.rootCategory=DEBUG,A2
+# log4j.rootLogger=DEBUG,A2
 
 #### DEBUG,A2,stdout is used to log in file & stdout:
-# log4j.rootCategory=DEBUG,A2,stdout
-# log4j.rootCategory=INFO,A2,stdout
-log4j.rootCategory=INFO,A2
+# log4j.rootLogger=DEBUG,A2,stdout
+# log4j.rootLogger=INFO,A2,stdout
+log4j.rootLogger=INFO,A2
 log4j.appender.A2=org.apache.log4j.RollingFileAppender
 log4j.appender.A2.File=log/replication.log
 log4j.appender.A2.Append=true