操作步骤,启动xxljob jar包,配置好文件和复制配置类,启动
-
- @Component
- public class XxljobDemo {
- @XxlJob("aaaa")
- public void demo(){
- XxlJobHelper.log("我要输出的日志");
- System.out.println(XxlJobHelper.getJobParam());
- System.out.println(XxlJobHelper.getShardTotal());
- System.out.println(XxlJobHelper.getShardIndex());
- }
- }
"参数"
1
0