killDeadClients

This commit is contained in:
Ben
2025-11-21 20:01:55 -05:00
parent 0481dfda6e
commit dd45c60eff
2 changed files with 28 additions and 25 deletions
+4
View File
@@ -6,6 +6,10 @@ import { TrackedEntity } from '../utils/TrackedEntity.entity';
@Entity()
@Index("IDX_unique_nonce", { synchronize: false })
@Index('idx_client_cleanup', ['updatedAt', 'id'], {
where: '"deletedAt" IS NULL',
// This is a partial (filtered) index — only indexes active clients
})
export class ClientEntity extends TrackedEntity {
@PrimaryGeneratedColumn('uuid')