diff --git a/apps/backend/src/lib/pendingSubmission.ts b/apps/backend/src/lib/pendingSubmission.ts index 969d450..fd4fc0a 100644 --- a/apps/backend/src/lib/pendingSubmission.ts +++ b/apps/backend/src/lib/pendingSubmission.ts @@ -27,7 +27,10 @@ export const storePendingSubmission = async ( RedisKeys.PENDING_SUBMISSION(meta.userId, meta.problemId, submission.id), convertToPlainRedis(submission) ).then(() => { - Redis.expire(RedisKeys.PENDING_SUBMISSION(meta.userId, meta.problemId, submission.id), 60); + Redis.expire( + RedisKeys.PENDING_SUBMISSION(meta.userId, meta.problemId, submission.id), + 5 * 60 + ); }); }; diff --git a/apps/backend/src/lib/testcase.ts b/apps/backend/src/lib/testcase.ts index 9b3c8b1..b190e23 100644 --- a/apps/backend/src/lib/testcase.ts +++ b/apps/backend/src/lib/testcase.ts @@ -181,17 +181,17 @@ export const generateTestcaseBatch = async (cluster: Cluster, count: number) => await Promise.all( testcases.map(async (tc) => { await Redis.set(RedisKeys.CACHED_TESTCASE_INPUT(cluster.id, tc.id), tc.input, { - EX: 15 * 60, + EX: 3 * 60 * 60, }); await Redis.set( RedisKeys.CACHED_TESTCASE_OUTPUT(cluster.id, tc.id), tc.correct_output ?? "", - { EX: 15 * 60 } + { EX: 3 * 60 * 60 } ); }) ); - await Redis.set(RedisKeys.CLUSTER_STATUS(cluster.id), "cached", { EX: 15 * 60 }); + await Redis.set(RedisKeys.CLUSTER_STATUS(cluster.id), "cached", { EX: 3 * 60 * 60 }); return testcases; };