Skip to content

Commit

Permalink
add the other two handlers that receive PIDs in their message
Browse files Browse the repository at this point in the history
  • Loading branch information
ndimiduk committed Mar 29, 2023
1 parent d622942 commit e065f93
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
import org.slf4j.LoggerFactory;

import org.apache.hadoop.hbase.shaded.protobuf.generated.RegionServerStatusProtos.RegionStateTransition.TransitionCode;
import org.slf4j.MDC;

/**
* Handles opening of a region on a region server.
Expand Down Expand Up @@ -90,6 +91,7 @@ private void cleanUpAndReportFailure(IOException error) throws IOException {

@Override
public void process() throws IOException {
MDC.put("pid", Long.toString(openProcId));
HRegionServer rs = getServer();
String encodedName = regionInfo.getEncodedName();
byte[] encodedNameBytes = regionInfo.getEncodedNameAsBytes();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
import org.slf4j.LoggerFactory;

import org.apache.hadoop.hbase.shaded.protobuf.generated.RegionServerStatusProtos.RegionStateTransition.TransitionCode;
import org.slf4j.MDC;

/**
* Handles closing of a region on a region server.
Expand Down Expand Up @@ -84,6 +85,7 @@ private HRegionServer getServer() {

@Override
public void process() throws IOException {
MDC.put("pid", Long.toString(closeProcId));
HRegionServer rs = getServer();
byte[] encodedNameBytes = Bytes.toBytes(encodedName);
Boolean previous = rs.getRegionsInTransitionInRS().putIfAbsent(encodedNameBytes, Boolean.FALSE);
Expand Down

0 comments on commit e065f93

Please sign in to comment.