XXL-JOB初体验-ORACLE版(转)

XXL-JOB初体验-ORACLE版

除了文章中提到的要修改的地方,增加以下修改:

1.添加Oracle.jdbc驱动

<!--需要自建,mvn install:install-file -DgroupId=com.oracle -DartifactId=ojdbc8 -Dversion=12.2.0.1 -Dpackaging=jar -Dfile=ojdbc8.jar -->
<dependency>
<groupId>com.oracle</groupId>
<artifactId>ojdbc8</artifactId>
<version>12.2.0.1</version>
</dependency>

2.主pom文件中的module要进行修改
<modules>
<module>xxl-job-core</module>
<module>xxl-job-admin-oracle</module>
<module>xxl-job-executor-samples</module>
</modules>

3.开始运行并测试
进入http://localhost:8080/xxl-job-admin/jobgroup
任务管理,参考官方文档,添加任务即可。


4.参考官方示例,在自己的SpringBoot项目中引入xxl-job.
<dependency>
<groupId>com.xuxueli</groupId>
<artifactId>xxl-job-core</artifactId>
<version>2.0.2</version>
</dependency>
备注:此处建议和admin的job-core版本保持一致,经测试发现由于admin使用2.0.2版本,而job端使用2.1.1版本,发生了xxl-job registry fail,存在部分兼容性问题。




猜你喜欢

转载自www.cnblogs.com/huanghongbo/p/12563430.html