Просмотр исходного кода

取消父子任务不可重复的限制,支持循环任务触发等特殊场景;

xuxueli 6 лет назад
Родитель
Сommit
358f3a72e7

+ 1 - 1
doc/XXL-JOB官方文档.md Просмотреть файл

1241
 - 23、新增任务运行模式 "GLUE模式(PHP) ",支持php脚本任务;
1241
 - 23、新增任务运行模式 "GLUE模式(PHP) ",支持php脚本任务;
1242
 - 24、执行器手动设置IP时取消绑定Host的操作,该IP仅供执行器注册使用;修复指定外网IP时无法绑定执行器Host的问题;
1242
 - 24、执行器手动设置IP时取消绑定Host的操作,该IP仅供执行器注册使用;修复指定外网IP时无法绑定执行器Host的问题;
1243
 - 25、任务失败重试优化:收敛并废弃现有失败重试策略,如调度失败、执行失败、状态码失败等,新增任务属性 "失败重试次数",支持自定义失败重试次数,任务失败时将会根据该值进行失败重试;
1243
 - 25、任务失败重试优化:收敛并废弃现有失败重试策略,如调度失败、执行失败、状态码失败等,新增任务属性 "失败重试次数",支持自定义失败重试次数,任务失败时将会根据该值进行失败重试;
1244
-- 26、【迭代中】父子任务循环限制放开,支持特殊场景;
1244
+- 26、取消父子任务不可重复的限制,支持循环任务触发等特殊场景;
1245
 - 27、【迭代中】API服务支持动态参数;
1245
 - 27、【迭代中】API服务支持动态参数;
1246
 
1246
 
1247
 
1247
 

+ 0 - 4
xxl-job-admin/src/main/java/com/xxl/job/admin/service/impl/XxlJobServiceImpl.java Просмотреть файл

173
 						return new ReturnT<String>(ReturnT.FAIL_CODE,
173
 						return new ReturnT<String>(ReturnT.FAIL_CODE,
174
 								MessageFormat.format((I18nUtil.getString("jobinfo_field_childJobId")+"({0})"+I18nUtil.getString("system_not_found")), childJobIdItem));
174
 								MessageFormat.format((I18nUtil.getString("jobinfo_field_childJobId")+"({0})"+I18nUtil.getString("system_not_found")), childJobIdItem));
175
 					}
175
 					}
176
-					// avoid cycle relate
177
-					if (childJobInfo.getId() == jobInfo.getId()) {
178
-						return new ReturnT<String>(ReturnT.FAIL_CODE, MessageFormat.format(I18nUtil.getString("jobinfo_field_childJobId_limit"), childJobIdItem));
179
-					}
180
 				} else {
176
 				} else {
181
 					return new ReturnT<String>(ReturnT.FAIL_CODE,
177
 					return new ReturnT<String>(ReturnT.FAIL_CODE,
182
 							MessageFormat.format((I18nUtil.getString("jobinfo_field_childJobId")+"({0})"+I18nUtil.getString("system_unvalid")), childJobIdItem));
178
 							MessageFormat.format((I18nUtil.getString("jobinfo_field_childJobId")+"({0})"+I18nUtil.getString("system_unvalid")), childJobIdItem));

+ 0 - 1
xxl-job-admin/src/main/resources/i18n/message.properties Просмотреть файл

113
 jobinfo_field_alarmemail_placeholder=请输入报警邮件,多个邮件地址则逗号分隔
113
 jobinfo_field_alarmemail_placeholder=请输入报警邮件,多个邮件地址则逗号分隔
114
 jobinfo_field_executorRouteStrategy=路由策略
114
 jobinfo_field_executorRouteStrategy=路由策略
115
 jobinfo_field_childJobId=子任务ID
115
 jobinfo_field_childJobId=子任务ID
116
-jobinfo_field_childJobId_limit=子任务ID({0})不可与父任务重复
117
 jobinfo_field_childJobId_placeholder=请输入子任务的任务ID,如存在多个则逗号分隔
116
 jobinfo_field_childJobId_placeholder=请输入子任务的任务ID,如存在多个则逗号分隔
118
 jobinfo_field_executorBlockStrategy=阻塞处理策略
117
 jobinfo_field_executorBlockStrategy=阻塞处理策略
119
 jobinfo_field_executorFailRetryCount=失败重试次数
118
 jobinfo_field_executorFailRetryCount=失败重试次数

+ 0 - 1
xxl-job-admin/src/main/resources/i18n/message_en.properties Просмотреть файл

113
 jobinfo_field_alarmemail_placeholder=Please enter alarm mail, if there are more than one comma separated
113
 jobinfo_field_alarmemail_placeholder=Please enter alarm mail, if there are more than one comma separated
114
 jobinfo_field_executorRouteStrategy=Route Strategy
114
 jobinfo_field_executorRouteStrategy=Route Strategy
115
 jobinfo_field_childJobId=Child Job ID
115
 jobinfo_field_childJobId=Child Job ID
116
-jobinfo_field_childJobId_limit=Child job ID({0}) cannot be duplicated with the parent job.
117
 jobinfo_field_childJobId_placeholder=Please enter the Child job ID, if there are more than one comma separated
116
 jobinfo_field_childJobId_placeholder=Please enter the Child job ID, if there are more than one comma separated
118
 jobinfo_field_executorBlockStrategy=Block Strategy
117
 jobinfo_field_executorBlockStrategy=Block Strategy
119
 jobinfo_field_executorFailRetryCount=Fail Retry Count
118
 jobinfo_field_executorFailRetryCount=Fail Retry Count