mirror of https://gitee.com/makejava/EasyCode.git
针对部分用户,修复生成代码卡死的问题。
This commit is contained in:
parent
d12ade8fcf
commit
5c24d78c3f
|
@ -13,6 +13,7 @@ import com.sjhy.plugin.entity.Template;
|
|||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.apache.velocity.VelocityContext;
|
||||
import org.apache.velocity.app.VelocityEngine;
|
||||
import org.apache.velocity.runtime.RuntimeConstants;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
|
@ -49,6 +50,9 @@ public class VelocityUtils {
|
|||
*/
|
||||
private VelocityUtils() {
|
||||
velocityEngine = new VelocityEngine();
|
||||
// 修复部分用户的velocity日志记录无权访问velocity.log文件问题
|
||||
velocityEngine.setProperty( RuntimeConstants.RUNTIME_LOG_LOGSYSTEM_CLASS, "org.apache.velocity.runtime.log.Log4JLogChute" );
|
||||
velocityEngine.setProperty("runtime.log.logsystem.log4j.logger", "velocity");
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in New Issue