Skip to content

Sync-in · Sovereign platform for file storage, sharing, synchronization, and collaboration.

chore(backend:files): reduce cache duration for indexesList

johavend7a323c2a78e
diff --git a/backend/src/applications/files/adapters/files-content-store-mysql.service.ts b/backend/src/applications/files/adapters/files-content-store-mysql.service.ts
index eb87dbb5..03d8e808 100644
--- a/backend/src/applications/files/adapters/files-content-store-mysql.service.ts
+++ b/backend/src/applications/files/adapters/files-content-store-mysql.service.ts
@@ -15,7 +15,7 @@ export class FilesContentStoreMySQL implements FilesContentStore {
constructor(@Inject(DB_TOKEN_PROVIDER) private readonly db: DBSchema) {}
- @CacheDecorator(300)
+ @CacheDecorator(60)
async indexesList(): Promise<string[]> {
return ((await this.db.execute(sql`SHOW TABLES LIKE '${sql.raw(FILES_CONTENT_TABLE_PREFIX)}%'`))[0] as any).flatMap((r: Record<string, string>) =>
Object.values(r)