Repository: asterixdb Updated Branches: refs/heads/master 1a879cdf0 -> 6eff367d9
[NO ISSUE][LOG] Ensure NC logDir ends with separator - user model changes: no - storage format changes: no - interface changes: no Change-Id: I492428fdbf84ed6f1c4afd136dce33ac84aea3c0 Reviewed-on: https://asterix-gerrit.ics.uci.edu/2982 Sonar-Qube: Jenkins <[email protected]> Tested-by: Jenkins <[email protected]> Contrib: Jenkins <[email protected]> Reviewed-by: Till Westmann <[email protected]> Integration-Tests: Jenkins <[email protected]> Reviewed-by: Ian Maxon <[email protected]> Project: http://git-wip-us.apache.org/repos/asf/asterixdb/repo Commit: http://git-wip-us.apache.org/repos/asf/asterixdb/commit/6eff367d Tree: http://git-wip-us.apache.org/repos/asf/asterixdb/tree/6eff367d Diff: http://git-wip-us.apache.org/repos/asf/asterixdb/diff/6eff367d Branch: refs/heads/master Commit: 6eff367d9a661fbd9e39e0440ae968df70a940ad Parents: 1a879cd Author: Wail Alkowaileet <[email protected]> Authored: Sun Sep 30 19:52:58 2018 -0700 Committer: Wail Alkowaileet <[email protected]> Committed: Fri Nov 9 10:51:19 2018 -0800 ---------------------------------------------------------------------- asterixdb/asterix-server/src/main/opt/ansible/conf/cc.conf | 1 + .../apache/hyracks/control/nc/NCLogConfigurationFactory.java | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/asterixdb/blob/6eff367d/asterixdb/asterix-server/src/main/opt/ansible/conf/cc.conf ---------------------------------------------------------------------- diff --git a/asterixdb/asterix-server/src/main/opt/ansible/conf/cc.conf b/asterixdb/asterix-server/src/main/opt/ansible/conf/cc.conf index e779dc2..2824219 100644 --- a/asterixdb/asterix-server/src/main/opt/ansible/conf/cc.conf +++ b/asterixdb/asterix-server/src/main/opt/ansible/conf/cc.conf @@ -17,6 +17,7 @@ [common] log.level=INFO +log.dir=logs [nc] txn.log.dir=txnlog http://git-wip-us.apache.org/repos/asf/asterixdb/blob/6eff367d/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-nc/src/main/java/org/apache/hyracks/control/nc/NCLogConfigurationFactory.java ---------------------------------------------------------------------- diff --git a/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-nc/src/main/java/org/apache/hyracks/control/nc/NCLogConfigurationFactory.java b/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-nc/src/main/java/org/apache/hyracks/control/nc/NCLogConfigurationFactory.java index 990d6c9..f4d10cb 100644 --- a/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-nc/src/main/java/org/apache/hyracks/control/nc/NCLogConfigurationFactory.java +++ b/hyracks-fullstack/hyracks/hyracks-control/hyracks-control-nc/src/main/java/org/apache/hyracks/control/nc/NCLogConfigurationFactory.java @@ -18,6 +18,9 @@ */ package org.apache.hyracks.control.nc; +import java.io.File; +import java.net.URI; + import org.apache.hyracks.control.common.controllers.NCConfig; import org.apache.logging.log4j.Level; import org.apache.logging.log4j.core.LoggerContext; @@ -30,8 +33,6 @@ import org.apache.logging.log4j.core.config.builder.api.ConfigurationBuilder; import org.apache.logging.log4j.core.config.builder.api.LayoutComponentBuilder; import org.apache.logging.log4j.core.config.builder.impl.BuiltConfiguration; -import java.net.URI; - public class NCLogConfigurationFactory extends ConfigurationFactory { private NCConfig config; @@ -42,6 +43,7 @@ public class NCLogConfigurationFactory extends ConfigurationFactory { public Configuration createConfiguration(ConfigurationBuilder<BuiltConfiguration> builder) { String nodeId = config.getNodeId(); String logDir = config.getLogDir(); + logDir = logDir.endsWith(File.separator) ? logDir : logDir + File.separator; builder.setStatusLevel(Level.WARN); builder.setConfigurationName("RollingBuilder"); // create a rolling file appender
