|
|
@ -3,6 +3,7 @@ package com.xuxueli.executor.sample.jfinal.config; |
|
|
|
import com.jfinal.config.*; |
|
|
|
import com.jfinal.config.*; |
|
|
|
import com.jfinal.kit.Prop; |
|
|
|
import com.jfinal.kit.Prop; |
|
|
|
import com.jfinal.kit.PropKit; |
|
|
|
import com.jfinal.kit.PropKit; |
|
|
|
|
|
|
|
import com.jfinal.template.Engine; |
|
|
|
import com.xuxueli.executor.sample.jfinal.controller.IndexController; |
|
|
|
import com.xuxueli.executor.sample.jfinal.controller.IndexController; |
|
|
|
import com.xuxueli.executor.sample.jfinal.jobhandler.CommandJobHandler; |
|
|
|
import com.xuxueli.executor.sample.jfinal.jobhandler.CommandJobHandler; |
|
|
|
import com.xuxueli.executor.sample.jfinal.jobhandler.DemoJobHandler; |
|
|
|
import com.xuxueli.executor.sample.jfinal.jobhandler.DemoJobHandler; |
|
|
@ -58,35 +59,27 @@ public class JFinalCoreConfig extends JFinalConfig { |
|
|
|
|
|
|
|
|
|
|
|
// ---------------------- jfinal ----------------------
|
|
|
|
// ---------------------- jfinal ----------------------
|
|
|
|
|
|
|
|
|
|
|
|
public void configRoute(Routes route) { |
|
|
|
|
|
|
|
route.add("/", IndexController.class); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public void afterJFinalStart() { |
|
|
|
public void onStart() { |
|
|
|
initXxlJobExecutor(); |
|
|
|
initXxlJobExecutor(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
@Override |
|
|
|
public void beforeJFinalStop() { |
|
|
|
public void onStop() { |
|
|
|
destoryXxlJobExecutor(); |
|
|
|
destoryXxlJobExecutor(); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public void configConstant(Constants constants) { |
|
|
|
public void configConstant(Constants me) { |
|
|
|
|
|
|
|
me.setDevMode(true); |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void configPlugin(Plugins plugins) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public void configInterceptor(Interceptors interceptors) { |
|
|
|
public void configRoute(Routes routes) { |
|
|
|
|
|
|
|
routes.add("/", IndexController.class); |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void configHandler(Handlers handlers) { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void configEngine(Engine me) {} |
|
|
|
|
|
|
|
public void configPlugin(Plugins me) {} |
|
|
|
|
|
|
|
public void configInterceptor(Interceptors me) {} |
|
|
|
|
|
|
|
public void configHandler(Handlers me) {} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|