提交 38f8e6c7 authored 作者: xuxueli's avatar xuxueli

Window机器下File.separator不兼容问题修复;

上级 7f2179a7
...@@ -1168,6 +1168,7 @@ Tips: 历史版本(V1.3.x)目前已经Release至稳定版本, 进入维护阶段 ...@@ -1168,6 +1168,7 @@ Tips: 历史版本(V1.3.x)目前已经Release至稳定版本, 进入维护阶段
- 5、任务日志表状态字段类型优化; - 5、任务日志表状态字段类型优化;
- 6、[迭代中]脚本任务支持失败重试; - 6、[迭代中]脚本任务支持失败重试;
- 7、告警邮箱支持SSL配置; - 7、告警邮箱支持SSL配置;
- 8、Window机器下File.separator不兼容问题修复;
### TODO LIST ### TODO LIST
......
...@@ -8,6 +8,8 @@ import com.xxl.job.core.log.XxlJobLogger; ...@@ -8,6 +8,8 @@ import com.xxl.job.core.log.XxlJobLogger;
import com.xxl.job.core.util.ScriptUtil; import com.xxl.job.core.util.ScriptUtil;
import com.xxl.job.core.util.ShardingUtil; import com.xxl.job.core.util.ShardingUtil;
import java.io.File;
/** /**
* Created by xuxueli on 17/4/27. * Created by xuxueli on 17/4/27.
*/ */
...@@ -41,7 +43,7 @@ public class ScriptJobHandler extends IJobHandler { ...@@ -41,7 +43,7 @@ public class ScriptJobHandler extends IJobHandler {
// make script file // make script file
String scriptFileName = XxlJobFileAppender.getGlueSrcPath() String scriptFileName = XxlJobFileAppender.getGlueSrcPath()
.concat("/") .concat(File.separator)
.concat(String.valueOf(jobId)) .concat(String.valueOf(jobId))
.concat("_") .concat("_")
.concat(String.valueOf(glueUpdatetime)) .concat(String.valueOf(glueUpdatetime))
......
...@@ -79,7 +79,7 @@ public class XxlJobFileAppender { ...@@ -79,7 +79,7 @@ public class XxlJobFileAppender {
// filePath/yyyy-MM-dd/9999.log // filePath/yyyy-MM-dd/9999.log
String logFileName = logFilePath.getPath() String logFileName = logFilePath.getPath()
.concat("/") .concat(File.separator)
.concat(String.valueOf(logId)) .concat(String.valueOf(logId))
.concat(".log"); .concat(".log");
return logFileName; return logFileName;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论