logging-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rgo...@apache.org
Subject svn commit: r1436212 - /logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumeEmbeddedManager.java
Date Mon, 21 Jan 2013 07:23:23 GMT
Author: rgoers
Date: Mon Jan 21 07:23:23 2013
New Revision: 1436212

URL: http://svn.apache.org/viewvc?rev=1436212&view=rev
Log:
Change newline to file separator character

Modified:
    logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumeEmbeddedManager.java

Modified: logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumeEmbeddedManager.java
URL: http://svn.apache.org/viewvc/logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumeEmbeddedManager.java?rev=1436212&r1=1436211&r2=1436212&view=diff
==============================================================================
--- logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumeEmbeddedManager.java
(original)
+++ logging/log4j/log4j2/trunk/flume-ng/src/main/java/org/apache/logging/log4j/flume/appender/FlumeEmbeddedManager.java
Mon Jan 21 07:23:23 2013
@@ -26,6 +26,7 @@ import org.apache.logging.log4j.core.con
 import org.apache.logging.log4j.core.config.Property;
 import org.apache.logging.log4j.core.helpers.Constants;
 import org.apache.logging.log4j.core.helpers.NameUtil;
+import org.apache.logging.log4j.util.PropertiesUtil;
 
 import java.util.Locale;
 import java.util.Properties;
@@ -40,6 +41,8 @@ public class FlumeEmbeddedManager extend
 
     private static ManagerFactory factory = new FlumeManagerFactory();
 
+    private static final String FiLE_SEP = PropertiesUtil.getProperties().getStringProperty("file.separator");
+
     private final FlumeNode node;
 
     private NodeConfiguration conf;
@@ -205,8 +208,8 @@ public class FlumeEmbeddedManager extend
                 props.put(name + ".channels", "file");
                 props.put(name + ".channels.file.type", "file");
                 if (dataDir != null && dataDir.length() > 0) {
-                    if (!dataDir.endsWith(Constants.LINE_SEP)) {
-                        dataDir = dataDir + Constants.LINE_SEP;
+                    if (!dataDir.endsWith(FiLE_SEP)) {
+                        dataDir = dataDir + FiLE_SEP;
                     }
 
                     props.put(name + ".channels.file.checkpointDir", dataDir + "checkpoint");



Mime
View raw message