amaliujia commented on a change in pull request #1725:
URL: https://github.com/apache/ozone/pull/1725#discussion_r550404763
##########
File path:
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/ContainerStateManagerImpl.java
##########
@@ -275,12 +278,24 @@ public void addContainer(final ContainerInfoProto
containerInfo)
if (!containers.contains(containerID)) {
ExecutionUtil.create(() -> {
- containerStore.put(containerID, container);
+ if (transactionBuffer != null) {
+ containerStore.putWithBatch(
+ transactionBuffer.getCurrentBatchOperation(),
+ containerID, container);
+ } else {
+ containerStore.put(containerID, container);
Review comment:
https://issues.apache.org/jira/browse/HDDS-4634
Create JIRA to add buffer in MockHAManager thus we can remove this `null`
check.
##########
File path:
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/ContainerStateManagerImpl.java
##########
@@ -275,12 +278,24 @@ public void addContainer(final ContainerInfoProto
containerInfo)
if (!containers.contains(containerID)) {
ExecutionUtil.create(() -> {
- containerStore.put(containerID, container);
+ if (transactionBuffer != null) {
+ containerStore.putWithBatch(
+ transactionBuffer.getCurrentBatchOperation(),
+ containerID, container);
+ } else {
+ containerStore.put(containerID, container);
Review comment:
https://issues.apache.org/jira/browse/HDDS-4634
Create JIRA to add buffer in MockHAManager thus we can remove `else`
----------------------------------------------------------------
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]