Skip to content

Remove temporary aof and rdb files in a background thread#7905

Merged
oranagra merged 1 commit intoredis:unstablefrom
ShooterIT:bg-unlink
Oct 13, 2020
Merged

Remove temporary aof and rdb files in a background thread#7905
oranagra merged 1 commit intoredis:unstablefrom
ShooterIT:bg-unlink

Conversation

@ShooterIT
Copy link
Member

If we fail or stop to rewrite aof, we need to remove temporary aof. We also remove temporary rdb when replicas abort to receive rdb. But currently we delete them in main thread, to avoid unnecessary latency, we should use bg_unlink to remove them in a background thread.

Btw, we have already used this way to removed child process temporary rdb.

If we fail or stop to rewrite aof, we need to remove temporary aof.
We also remove temporary rdb when replicas abort to receive rdb.
But currently we delete them in main thread, to avoid blocking,
we should use bg_unlink to remove them in a background thread.

Btw, we have already used this way to removed child process temporary rdb.
@oranagra oranagra merged commit aaacb8c into redis:unstable Oct 13, 2020
oranagra pushed a commit that referenced this pull request Oct 27, 2020
If we fail or stop to rewrite aof, we need to remove temporary aof.
We also remove temporary rdb when replicas abort to receive rdb.
But currently we delete them in main thread, to avoid blocking,
we should use bg_unlink to remove them in a background thread.

Btw, we have already used this way to removed child process temporary rdb.

(cherry picked from commit aaacb8c)
JackieXie168 pushed a commit to JackieXie168/redis that referenced this pull request Nov 4, 2020
If we fail or stop to rewrite aof, we need to remove temporary aof.
We also remove temporary rdb when replicas abort to receive rdb.
But currently we delete them in main thread, to avoid blocking,
we should use bg_unlink to remove them in a background thread.

Btw, we have already used this way to removed child process temporary rdb.
jschmieg pushed a commit to memKeyDB/memKeyDB that referenced this pull request Nov 6, 2020
If we fail or stop to rewrite aof, we need to remove temporary aof.
We also remove temporary rdb when replicas abort to receive rdb.
But currently we delete them in main thread, to avoid blocking,
we should use bg_unlink to remove them in a background thread.

Btw, we have already used this way to removed child process temporary rdb.

(cherry picked from commit aaacb8c)
@ShooterIT ShooterIT deleted the bg-unlink branch January 6, 2025 02:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants