wchevreuil commented on a change in pull request #1217: HBASE-23891: Add an
option to Actions to filter out meta RS
URL: https://github.com/apache/hbase/pull/1217#discussion_r385654263
##########
File path:
hbase-it/src/test/java/org/apache/hadoop/hbase/chaos/actions/GracefulRollingRestartRsAction.java
##########
@@ -35,15 +35,23 @@
public class GracefulRollingRestartRsAction extends RestartActionBaseAction {
private static final Logger LOG =
LoggerFactory.getLogger(GracefulRollingRestartRsAction.class);
- public GracefulRollingRestartRsAction(long sleepTime) {
+ private boolean killMetaRs;
+
+ public GracefulRollingRestartRsAction(long sleepTime, boolean killMetaRs) {
super(sleepTime);
+ this.killMetaRs = killMetaRs;
}
@Override
public void perform() throws Exception {
LOG.info("Performing action: Rolling restarting non-master region
servers");
List<ServerName> selectedServers = selectServers();
+ if(!killMetaRs){
+ ServerName metaServer = cluster.getServerHoldingMeta();
+ selectedServers.remove(metaServer);
+ }
+
Review comment:
Could we move this to Action class, in order to avoid repeating it on
different Action implementations? Just noticed we duplicate this in
RollingBatchSuspendResumeRsAction.java.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services