Skip to content

Commit

Permalink
Merge pull request #533 from support-project/fix/issue508
Browse files Browse the repository at this point in the history
#508 Set time zone to GMT, when starting batch programs
  • Loading branch information
koda-masaru authored Dec 11, 2016
2 parents 72e3499 + d6614e5 commit c23c1e7
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
package org.support.project.knowledge.bat;

import java.util.TimeZone;

import org.apache.log4j.FileAppender;
import org.apache.log4j.Logger;
import org.support.project.common.log.Log;
Expand All @@ -21,6 +23,10 @@ public static void initLogName(String logname) {
}

protected static void configInit(String batName) {
// 内部的には、日付はGMTとして扱う
TimeZone zone = TimeZone.getTimeZone("GMT");
TimeZone.setDefault(zone);

AppConfig.initEnvKey(SystemConfig.KNOWLEDGE_ENV_KEY);
String envValue = System.getenv(SystemConfig.KNOWLEDGE_ENV_KEY);
LOG.info(batName + " is start.");
Expand Down

0 comments on commit c23c1e7

Please sign in to comment.