gavinchou commented on code in PR #33377:
URL: https://github.com/apache/doris/pull/33377#discussion_r1563620832


##########
fe/fe-core/src/main/java/org/apache/doris/catalog/StorageVault.java:
##########
@@ -166,28 +174,23 @@ protected void replaceIfEffectiveValue(Map<String, 
String> properties, String ke
                 .addColumn(new Column("Propeties", 
ScalarType.createVarchar(65535)))
                 .build();
 
-    public static List<String> 
convertToShowStorageVaultProperties(Cloud.ObjectStoreInfoPB info) {
-        Cloud.ObjectStoreInfoPB.Builder builder = 
Cloud.ObjectStoreInfoPB.newBuilder();
-        builder.mergeFrom(info);
-        List<String> row = new ArrayList<>();
-        row.add(info.getName());
-        row.add(info.getId());
-        TextFormat.Printer printer = TextFormat.printer();
-        builder.clearId();
-        builder.clearName();
-        builder.setSk("xxxxxxx");
-        row.add(printer.shortDebugString(builder));
-        return row;
-    }
-
     public static List<String> 
convertToShowStorageVaultProperties(Cloud.StorageVaultPB vault) {
         List<String> row = new ArrayList<>();
         row.add(vault.getName());
         row.add(vault.getId());
-        Cloud.HdfsVaultInfo.Builder builder = Cloud.HdfsVaultInfo.newBuilder();
-        builder.mergeFrom(vault.getHdfsInfo());
         TextFormat.Printer printer = TextFormat.printer();
-        row.add(printer.shortDebugString(builder));
+        if (vault.hasHdfsInfo()) {
+            Cloud.HdfsVaultInfo.Builder builder = 
Cloud.HdfsVaultInfo.newBuilder();
+            builder.mergeFrom(vault.getHdfsInfo());
+            row.add(printer.shortDebugString(builder));
+        }
+        if (vault.hasS3Obj()) {

Review Comment:
   ```suggestion
           if (vault.hasObjInfo()) {
   ```



-- 
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]

Reply via email to