feat(storage): add team auto-archive assets policy and background job (#516)

* feat(storage): add team auto-archive assets policy and background job

* fix(storage): address code review feedback on lock safety, starvation, and permissions

* docs: update readme and expand archive storage documentation with auto-archive details

* feat(storage): log info message on auto-archive job start and finish with archived count

* style(storage): stack age threshold and grace period vertically with updated grace period description

* fix(storage): only log auto-archive info messages when candidate assets are found to process
This commit is contained in:
Yiling-J
2026-11-04 14:40:44 +08:00
committed by GitHub
parent ba3c6dbfee
commit 2ecbd49d18
23 changed files with 1805 additions and 39 deletions
+2
View File
@@ -20,6 +20,7 @@ import { authService } from '@shumai/core/src/auth/auth'
import { embeddingService } from '@shumai/core/src/search/embedding-service'
import { sandboxService } from '@shumai/core'
import { notificationJobService } from '@shumai/core/src/notification/notification-job'
import { autoArchiveJobService } from '@shumai/core/src/asset/auto-archive-job'
if (process.argv.includes('--check')) {
console.log('✅ Web app evaluated successfully!')
@@ -91,6 +92,7 @@ async function run() {
await agentService.ensureSystemEmbeddingAgents().catch(console.error)
assetService.startCleanupJob()
notificationJobService.start()
autoArchiveJobService.start()
const args = process.argv.slice(2)
let workersOption = process.env.SHUMAI_WORKERS || 'all'
for (let i = 0; i < args.length; i++) {