smengcl commented on code in PR #11846:
URL: https://github.com/apache/ozone/pull/11846#discussion_r4419812134
##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/response/volume/OMQuotaRepairResponse.java:
##########
@@ -60,7 +60,8 @@ public void addToDBBatch(OMMetadataManager metadataManager,
omBucketInfo.getBucketName()), omBucketInfo);
}
for (OmVolumeArgs volArgs : volumeArgsMap.values()) {
- metadataManager.getVolumeTable().putWithBatch(batchOp,
volArgs.getVolume(), volArgs);
+ metadataManager.getVolumeTable().putWithBatch(batchOp,
+ metadataManager.getVolumeKey(volArgs.getVolume()), volArgs);
Review Comment:
(non-blocking) Follow-up: the bare-name rows written by earlier repairs stay
in RocksDB and are loaded into the volume table cache on restart.
`listAllVolumes` iterates that cache, so an admin `ozone sh volume list` shows
each repaired volume twice, and `VolumeUtilizationMetrics` emits two records
for it. `volume delete` removes only the `/vol` key, so the bare row remains
after the volume is deleted.
Could we file a follow-up JIRA to remove these rows (for example, a row
whose key has no `/` prefix and equals its `getVolume()`)?
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]