From 651fb9f8da3c79c4e886a00ae6caad22a0f09a2d Mon Sep 17 00:00:00 2001 From: Hari Date: Wed, 18 Mar 2026 12:52:26 +0530 Subject: [PATCH] 2 months ago --- .../com/thughari/jobtrackerpro/service/JobService.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/backend/src/main/java/com/thughari/jobtrackerpro/service/JobService.java b/backend/src/main/java/com/thughari/jobtrackerpro/service/JobService.java index e642ebe..0f0e561 100644 --- a/backend/src/main/java/com/thughari/jobtrackerpro/service/JobService.java +++ b/backend/src/main/java/com/thughari/jobtrackerpro/service/JobService.java @@ -248,17 +248,17 @@ public void finalizeManualSync(String email, String historyId) { public void cleanupStaleApplications() { LocalDateTime now = LocalDateTime.now(ZoneOffset.UTC); - LocalDateTime threeMonthsAgo = now.minusMonths(2); + LocalDateTime twoMonthsAgo = now.minusMonths(2); - List affectedEmails = jobRepository.findUserEmailsWithStaleJobs(threeMonthsAgo); + List affectedEmails = jobRepository.findUserEmailsWithStaleJobs(twoMonthsAgo); if (affectedEmails.isEmpty()) { log.info("System Cleanup: No stale applications found."); return; } - String autoNote = "\n[" + now.format(fmt) + "] Status auto-set to Rejected (3 months inactivity)."; - jobRepository.markStaleJobsAsRejected(threeMonthsAgo, now, autoNote); + String autoNote = "\n[" + now.format(fmt) + "] Status auto-set to Rejected (2 months inactivity)."; + jobRepository.markStaleJobsAsRejected(twoMonthsAgo, now, autoNote); affectedEmails.forEach(cacheEvictService::evictAllForUser);