-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Erase index on crash recovery for any backing queue
It is up to the individual implementation to decide what to erase, i.e. priority queues have one index per priority
- Loading branch information
Diana Corbacho
committed
Jun 21, 2016
1 parent
5f1ffc6
commit b2fd873
Showing
3 changed files
with
7 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -273,7 +273,11 @@ reset_state(#qistate{ dir = Dir, | |
undefined -> ok; | ||
_ -> file_handle_cache:close(JournalHdl) | ||
end, | ||
ok = erase_index_dir(Dir), | ||
%% Don't verify return value as it might return an `enoent` error if | ||
%% reset and delete_crashed happen simultaneous. This is easily triggered | ||
%% in priority queues where the master do not wait long enough for all | ||
%% slaves | ||
_ = erase_index_dir(Dir), | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
dcorbacho
Contributor
|
||
blank_state_dir_funs(Dir, OnSyncFun, OnSyncMsgFun). | ||
|
||
init(Name, OnSyncFun, OnSyncMsgFun) -> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This change doesn't seem to be in
rabbitmq-server-802
. Should I cherry-pick this commit?