Quartz有关配置

2020-06-11  本文已影响0人  奶盐味小圆饼

在调用接口新增数据的时候,表的实体类entiey的id应该加上@TableId,指定类型为自增

 @TableId(
            value = "id",
            type = IdType.AUTO
    )
    private Long id;
application.yml文件配置
  quartz:
    job-store-type: jdbc
    jdbc:
      initialize-schema: embedded
    properties:
      org:
        quartz:
          scheduler:
            instanceName: clusteredScheduler
            instanceId: AUTO
          jobStore:
            class: org.quartz.impl.jdbcjobstore.JobStoreTX
            driverDelegateClass: org.quartz.impl.jdbcjobstore.StdJDBCDelegate
            tablePrefix: qrtz_
            isClustered: true
            clusterCheckinInterval: 10000
            useProperties: false
          threadPool:
            class: org.quartz.simpl.SimpleThreadPool
            threadCount: 10
            threadPriority: 5
            threadsInheritContextClassLoaderOfInitializingThread: true
上一篇下一篇

猜你喜欢

热点阅读