HBASE-30248 Validate snapshot region timeout#8468
Conversation
|
Hi maintainers, the three GitHub Actions workflows for this fork PR are awaiting approval. This PR does not modify any workflow files. Could someone with write access approve them when convenient? Thanks. |
|
Hi @guluo2016, sorry for the direct ping. Could you please help approve the fork workflows for this PR, or suggest an appropriate reviewer, when convenient? The original reproducer has been verified successfully. Thank you! |
|
Hi @guluo2016, I pushed a small follow-up commit to fix the Spotless formatting failure. The three workflows are awaiting approval again. Could you please approve them when convenient? Thanks! |
|
Hi @Apache9, sorry for the direct ping. All CI checks are now green, and the reporter has verified the original reproducer with both negative and zero timeout values. |
JIRA: https://issues.apache.org/jira/browse/HBASE-30248
What changes were proposed in this pull request?
This change validates
hbase.snapshot.region.timeoutinRegionServerSnapshotManager.When the configured value is less than or equal to zero, HBase logs a warning and falls back to the documented default value of 300000 milliseconds.
All RegionServer snapshot call sites now use the same validated timeout value. The configuration documentation is also updated to state that the value must be greater than zero.
Why are the changes needed?
HBASE-30248 reports that a negative
hbase.snapshot.region.timeoutis passed toThreadPoolExecutoras the keep-alive time during snapshot procedure initialization.This causes an
IllegalArgumentExceptionand aborts the RegionServer during startup. A zero value is also invalid when core thread timeout is enabled.Falling back to the documented default prevents an invalid timeout configuration from aborting the RegionServer.
How was this patch tested?
Added
TestRegionServerSnapshotManager, covering:The focused unit test can be run with:
mvn -pl hbase-server -am -DskipITs -Dtest=TestRegionServerSnapshotManager test