Fixing .gitignore

This commit is contained in:
wangjinlei
2023-09-19 18:24:19 +08:00
parent 06e2f68ad9
commit ae15750e6a
581 changed files with 67226 additions and 67275 deletions

View File

@@ -1,33 +1,33 @@
package com.peanut.modules.book.task;
import com.peanut.modules.book.service.ShopSeckillService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Service;
import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.ReentrantLock;
@Slf4j
@Service
public class SeckillProdScheduled {
@Autowired
ShopSeckillService shopSeckillService;
@Scheduled(cron = "0 0/1 * * * ?")
public void uploadSeckilProd3Days() {
Lock l = new ReentrantLock();
l.lock();
try {
shopSeckillService.uploadSeckilProd3Days();
}catch (Exception e){
e.printStackTrace();
}finally {
l.unlock();
}
}
}
package com.peanut.modules.book.task;
import com.peanut.modules.book.service.ShopSeckillService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Service;
import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.ReentrantLock;
@Slf4j
@Service
public class SeckillProdScheduled {
@Autowired
ShopSeckillService shopSeckillService;
@Scheduled(cron = "0 0/1 * * * ?")
public void uploadSeckilProd3Days() {
Lock l = new ReentrantLock();
l.lock();
try {
shopSeckillService.uploadSeckilProd3Days();
}catch (Exception e){
e.printStackTrace();
}finally {
l.unlock();
}
}
}