Skip to content

Commit

Permalink
HDDS-11491. Avoid sharing clientId among deleting services (apache#7250)
Browse files Browse the repository at this point in the history
  • Loading branch information
sumitagrawl authored Oct 1, 2024
1 parent b0943d5 commit c91f1c7
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ public abstract class AbstractKeyDeletingService extends BackgroundService

private final OzoneManager ozoneManager;
private final ScmBlockLocationProtocol scmClient;
private static ClientId clientId = ClientId.randomId();
private final ClientId clientId = ClientId.randomId();
private final AtomicLong deletedDirsCount;
private final AtomicLong movedDirsCount;
private final AtomicLong movedFilesCount;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
import org.apache.hadoop.ozone.om.snapshot.SnapshotUtils;
import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.PurgePathRequest;
import org.apache.hadoop.util.Time;
import org.apache.ratis.protocol.ClientId;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

Expand Down Expand Up @@ -75,8 +74,6 @@ public class DirectoryDeletingService extends AbstractKeyDeletingService {
public static final Logger LOG =
LoggerFactory.getLogger(DirectoryDeletingService.class);

private static ClientId clientId = ClientId.randomId();

// Use only a single thread for DirDeletion. Multiple threads would read
// or write to same tables and can send deletion requests for same key
// multiple times.
Expand Down

0 comments on commit c91f1c7

Please sign in to comment.