Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
benjackwhite committed Sep 19, 2023
1 parent 4be4f5c commit 7a3f278
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ export class RealtimeManager extends EventEmitter {

public async unsubscribe(): Promise<void> {
await this.pubsubRedis?.unsubscribe(Keys.realtimeSubscriptions())
await this.pubsubRedis?.quit()
}

private async run<T>(description: string, fn: (client: Redis) => Promise<T>): Promise<T | null> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -546,7 +546,10 @@ export class SessionRecordingIngesterV2 {
if (this.serverConfig.SESSION_RECORDING_PARTITION_REVOKE_OPTIMIZATION) {
status.info('🔁', `blob_ingester_consumer - flushing ${sessionsToDrop.length} sessions on revoke...`)
await Promise.allSettled(
sessionsToDrop.map(([_, sessionManager]) => sessionManager.flush('partition_shutdown'))
sessionsToDrop
.map(([_, x]) => x)
.sort((x) => x.buffer.oldestKafkaTimestamp ?? Infinity)
.map((x) => x.flush('partition_shutdown'))
)
}

Expand Down

0 comments on commit 7a3f278

Please sign in to comment.