Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -818,6 +818,7 @@ public boolean isKeyInfoSame(OmKeyInfo omKeyInfo, boolean checkPath,
replicationConfig.equals(omKeyInfo.replicationConfig) &&
Objects.equals(getMetadata(), omKeyInfo.getMetadata()) &&
Objects.equals(acls, omKeyInfo.acls) &&
Objects.equals(getTags(), omKeyInfo.getTags()) &&
getObjectID() == omKeyInfo.getObjectID();

if (isEqual && checkUpdateID) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,8 @@ private OmKeyInfo createOmKeyInfo(ReplicationConfig replicationConfig) {
.setReplicationConfig(replicationConfig)
.addMetadata("key1", "value1")
.addMetadata("key2", "value2")
.addTag("tagKey1", "tagValue1")
.addTag("tagKey2", "tagValue2")
.setExpectedDataGeneration(5678L)
.build();
}
Expand All @@ -149,6 +151,8 @@ private void createdAndTest(boolean isMPU) {
RatisReplicationConfig.getInstance(ReplicationFactor.THREE))
.addMetadata("key1", "value1")
.addMetadata("key2", "value2")
.addTag("tagKey1", "tagValue1")
.addTag("tagKey2", "tagValue2")
.setOmKeyLocationInfos(
Collections.singletonList(createOmKeyLocationInfoGroup(isMPU)))
.build();
Expand Down Expand Up @@ -194,6 +198,11 @@ private void createdAndTest(boolean isMPU) {
cloneKey = key.copyObject();

assertEquals(key.getAcls(), cloneKey.getAcls());

// Change object tags and check
key.setTags(Collections.singletonMap("tagKey3", "tagValue3"));

assertNotEquals(key, cloneKey);
}


Expand Down