-
Notifications
You must be signed in to change notification settings - Fork 109
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
update aliyun-schedulerx-spring-boot-sample #72
base: master
Are you sure you want to change the base?
Conversation
package com.alibaba.cloud.examples.schedulerx.job.annotation; | ||
|
||
import com.alibaba.schedulerx.common.domain.ExecuteMode; | ||
import com.alibaba.schedulerx.worker.processor.SchedulerX; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这个注解的包名建议改下
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
已调整
* Can use @SchedulerX annotation set job config when open sync(true) | ||
*/ | ||
@Scheduled(cron = "0/5 * * * * ?") | ||
@SchedulerX(name = "simpleJobWithAnnotation", model = ExecuteMode.STANDALONE) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
可否用一个注解,cron配置放在@SchedulerX里
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
已调整
@@ -0,0 +1,23 @@ | |||
## 控制台定义任务配置信息,或通过注解定义任务 (推荐模式) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
建议这份文件类型也修改为yml,因为另外一份文件格式是yml,保持一致会显得正式一些,否则会让用户感觉有点随意。
|
||
2. pom增加依赖aliyun-schedulerx-spring-boot-starter | ||
|
||
2. 进入任务调度控制台->应用管理,点击"创建应用",配置应用分组信息保存(PS:本地开发测试环境仅支持公网region创建分组对接) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
region字符前有异常字符,需要删除一下。
* Can use @SchedulerX annotation set job config when open sync(true) | ||
*/ | ||
@Scheduled(cron = "0/5 * * * * ?") | ||
@SchedulerX(name = "simpleJobWithAnnotation", model = ExecuteMode.STANDALONE) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
该处需要跟实际代码保持一致。
update aliyun-schedulerx-spring-boot-sample, schedulerx support job running with spring @scheduled annotation