标签:rdd rda ble slf4j service dao java dde second
定义任务ScheduledExecutorService scheduledExecutorService =
Executors.newScheduledThreadPool(50);
scheduledExecutorService.schedule(new DoorGuardDelUserThreadPool(vd,companyDao,preRegistrationDataDao,doorGuardService,c.getDomain()), 10*60, TimeUnit.SECONDS);
写执行内容:实现 Runnable接口br/>@Slf4j
public class DoorGuardDelUserThreadPool implements Runnable {
private VisitorData finalVd;
private ICompanyDao companyDao;
private IPreRegistrationDataDao preRegistrationDataDao;
private IDoorGuardService doorGuardService;
private String domain;
public DoorGuardDelUserThreadPool(VisitorData vd, ICompanyDao companyDao, IPreRegistrationDataDao preRegistrationDataDao, IDoorGuardService doorGuardService,String domain) {
this.finalVd = vd;
this.companyDao = companyDao;
this.preRegistrationDataDao = preRegistrationDataDao;
this.doorGuardService = doorGuardService;
this.domain = domain;
}
@Override
public void run() {
log.info("companyDao:"+companyDao);
log.info("finalVd.getCompany_id():"+finalVd.getCompany_id());
log.info("finalVd.getPre_registration_id() :"+finalVd.getPre_registration_id() );
log.info("domain :"+domain );
}
标签:rdd rda ble slf4j service dao java dde second
原文地址:https://blog.51cto.com/tianjian/2457188