HBASE-29800 WAL logs are unprotected during first full backup#7717
Open
DieterDP-ng wants to merge 1 commit intoapache:masterfrom
Open
HBASE-29800 WAL logs are unprotected during first full backup#7717DieterDP-ng wants to merge 1 commit intoapache:masterfrom
DieterDP-ng wants to merge 1 commit intoapache:masterfrom
Conversation
The BackupLogCleaner prevents WAL files that are needed for future backups from being deleted. In the case where a backup root has a single running backup, there was a small timeframe where relevant files were unprotected because only completed backups were taken into consideration. This commit fixes this. The old mechanism relied on the "backup start code", which is a timestamp that denotes (per backup root) the lowest (earliest) log-roll timestamp that occurred for the backup. Because this concept had no added value, but is complex to reason about, it is removed. Usages are replaced with equal behavior based on timestamps stored in the backup info. (The backup start codes were calculated in the same way, just stored separately.) Note that the backup start code calculation suffers from HBASE-29628 (log-roll timestamps of decommissioned region servers are not cleaned up, causing the start code to be lower than it should be). That problem is still present in this commit.
2dc0d50 to
5863d06
Compare
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The BackupLogCleaner prevents WAL files that are needed for future backups from being deleted. In the case where a backup root has a single running backup, there was a small timeframe where relevant files were unprotected because only completed backups were taken into consideration. This commit fixes this.
The old mechanism relied on the "backup start code", which is a timestamp that denotes (per backup root) the lowest (earliest) log-roll timestamp that occurred for the backup. Because this concept had no added value, but is complex to reason about, it is removed. Usages are replaced with equal behavior based on timestamps stored in the backup info. (The backup start codes were calculated in the same way, just stored separately.)
Note that the backup start code calculation suffers from HBASE-29628 (log-roll timestamps of decommissioned region servers are not cleaned up, causing the start code to be lower than it should be). That problem is still present in this commit.