|
|
@ -3,6 +3,7 @@ package au.com.royalpay.payment.manage.task;
|
|
|
|
import au.com.royalpay.payment.manage.system.core.TradeSecureService;
|
|
|
|
import au.com.royalpay.payment.manage.system.core.TradeSecureService;
|
|
|
|
import au.com.royalpay.payment.tools.scheduler.SynchronizedScheduler;
|
|
|
|
import au.com.royalpay.payment.tools.scheduler.SynchronizedScheduler;
|
|
|
|
import org.apache.commons.lang3.time.DateFormatUtils;
|
|
|
|
import org.apache.commons.lang3.time.DateFormatUtils;
|
|
|
|
|
|
|
|
import org.apache.commons.lang3.time.DateUtils;
|
|
|
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
|
|
|
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
|
|
|
import org.springframework.scheduling.annotation.Scheduled;
|
|
|
|
import org.springframework.scheduling.annotation.Scheduled;
|
|
|
|
import org.springframework.stereotype.Component;
|
|
|
|
import org.springframework.stereotype.Component;
|
|
|
@ -22,7 +23,7 @@ public class SecurePaySettleFileTask {
|
|
|
|
@Scheduled(cron = "0 0 3 * * *")
|
|
|
|
@Scheduled(cron = "0 0 3 * * *")
|
|
|
|
public void sendSecurePaySettleFile() {
|
|
|
|
public void sendSecurePaySettleFile() {
|
|
|
|
synchronizedScheduler.executeProcess("task:securepay_settle_file_sending", 60_000, () ->
|
|
|
|
synchronizedScheduler.executeProcess("task:securepay_settle_file_sending", 60_000, () ->
|
|
|
|
tradeSecureService.sendSecurePaySettleFile(DateFormatUtils.format(new Date(), "yyyyMMdd"))
|
|
|
|
tradeSecureService.sendSecurePaySettleFile(DateFormatUtils.format(DateUtils.addDays(new Date(), -1), "yyyyMMdd"))
|
|
|
|
);
|
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|