paul-rogers commented on a change in pull request #2042: DRILL-7672: Make 
metadata type required when reading from / writing into Drill Metastore
URL: https://github.com/apache/drill/pull/2042#discussion_r399614183
 
 

 ##########
 File path: 
metastore/iceberg-metastore/src/main/java/org/apache/drill/metastore/iceberg/components/tables/IcebergTables.java
 ##########
 @@ -42,16 +45,15 @@
  */
 public class IcebergTables implements Tables, 
MetastoreContext<TableMetadataUnit> {
 
-  public static final String STORAGE_PLUGIN = "storagePlugin";
-  public static final String WORKSPACE = "workspace";
-  public static final String TABLE_NAME = "tableName";
-  public static final String METADATA_KEY = "metadataKey";
-
   /**
    * Metastore Tables component partition keys, order of partitioning will be 
determined based
    * on order in {@link List} holder.
    */
-  private static final List<String> PARTITION_KEYS = 
Arrays.asList(STORAGE_PLUGIN, WORKSPACE, TABLE_NAME, METADATA_KEY);
+  private static final List<String> PARTITION_KEYS = Arrays.asList(
+    TableInfo.STORAGE_PLUGIN,
+    TableInfo.WORKSPACE,
+    TableInfo.TABLE_NAME,
+    MetadataInfo.METADATA_KEY);
 
 Review comment:
   Thanks for cleaning up this code. If these are the four types, does it make 
sense to define them in an enum, with the string keys as a property of the 
enum? Maybe as part of `MetadataType`?

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


With regards,
Apache Git Services

Reply via email to