diff --git "a/doc/XXL-JOB\345\256\230\346\226\271\346\226\207\346\241\243.md" "b/doc/XXL-JOB\345\256\230\346\226\271\346\226\207\346\241\243.md"
index 66029efb8ed928275c3d0be8854bd906fe3563df..4418c9ae031892c596df326bfb2cc9bfa9512b70 100644
--- "a/doc/XXL-JOB\345\256\230\346\226\271\346\226\207\346\241\243.md"
+++ "b/doc/XXL-JOB\345\256\230\346\226\271\346\226\207\346\241\243.md"
@@ -925,7 +925,7 @@ echo "分片总数 total = $3"
--- | --- | ---
成功 | IJobHandler.SUCCESS | 0
失败 | IJobHandler.FAIL | -1(其他)
-失败重试 | IJobHandler.FAIL_RETRY | 501
+失败重试 | IJobHandler.FAIL_RETRY | 101
## 六、版本更新日志
diff --git a/xxl-job-admin/src/main/resources/mybatis-mapper/XxlJobLogMapper.xml b/xxl-job-admin/src/main/resources/mybatis-mapper/XxlJobLogMapper.xml
index a16abaf55f6ff7d50c4be7809a145a599cb217bc..1721b1ba0e8faeecb697ca275355acfea4575e67 100644
--- a/xxl-job-admin/src/main/resources/mybatis-mapper/XxlJobLogMapper.xml
+++ b/xxl-job-admin/src/main/resources/mybatis-mapper/XxlJobLogMapper.xml
@@ -45,7 +45,7 @@
SELECT
FROM XXL_JOB_QRTZ_TRIGGER_LOG AS t
-
+
AND t.job_group = #{jobGroup}
@@ -62,12 +62,13 @@
AND (
- (t.trigger_code ]]> 0 AND t.trigger_code!=200) ||
- (t.handle_code ]]> 0 AND t.handle_code!=200)
+ t.trigger_code NOT IN (0, 200) ||
+ t.handle_code NOT IN (0, 200)
)
- AND (t.trigger_code = 200 AND t.handle_code=0)
+ AND t.trigger_code = 200
+ AND t.handle_code = 0
ORDER BY id DESC
@@ -78,7 +79,7 @@
SELECT count(1)
FROM XXL_JOB_QRTZ_TRIGGER_LOG AS t
-
+
AND t.job_group = #{jobGroup}
@@ -95,12 +96,13 @@
AND (
- (t.trigger_code ]]> 0 AND t.trigger_code!=200) ||
- (t.handle_code ]]> 0 AND t.handle_code!=200)
+ t.trigger_code NOT IN (0, 200) ||
+ t.handle_code NOT IN (0, 200)
)
- AND (t.trigger_code = 200 AND t.handle_code=0)
+ AND t.trigger_code = 200
+ AND t.handle_code = 0
diff --git a/xxl-job-core/src/main/java/com/xxl/job/core/handler/impl/ScriptJobHandler.java b/xxl-job-core/src/main/java/com/xxl/job/core/handler/impl/ScriptJobHandler.java
index b6e017eca41adc124c7bd85075acb00c0b9530d7..7cad6461ce9abfc9bb26470a12fe579c42c94818 100644
--- a/xxl-job-core/src/main/java/com/xxl/job/core/handler/impl/ScriptJobHandler.java
+++ b/xxl-job-core/src/main/java/com/xxl/job/core/handler/impl/ScriptJobHandler.java
@@ -66,7 +66,7 @@ public class ScriptJobHandler extends IJobHandler {
if (exitValue == 0) {
return IJobHandler.SUCCESS;
- } else if (exitValue == 501) {
+ } else if (exitValue == 101) {
return IJobHandler.FAIL_RETRY;
} else {
return new ReturnT(IJobHandler.FAIL.getCode(), "script exit value("+exitValue+") is failed");