[GitHub] [flink-table-store] wxplovecc commented on a diff in pull request #357: [FLINK-29922] Support create external table for hive catalog

2022-11-13 Thread GitBox


wxplovecc commented on code in PR #357:
URL: https://github.com/apache/flink-table-store/pull/357#discussion_r1021144454


##
flink-table-store-core/src/main/java/org/apache/flink/table/store/table/TableType.java:
##
@@ -0,0 +1,48 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.flink.table.store.table;
+
+import org.apache.flink.configuration.DescribedEnum;
+import org.apache.flink.configuration.description.InlineElement;
+
+import static org.apache.flink.configuration.description.TextElement.text;
+
+/** Enum of catalog table type. */
+public enum TableType implements DescribedEnum {
+MANAGED("MANAGED_TABLE", "Hive manage the lifecycle of the table."),
+EXTERNAL("EXTERNAL_TABLE", "Files are already present or in remote 
locations.");

Review Comment:
   updated @SteNicholas 



-- 
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: issues-unsubscr...@flink.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [flink-table-store] wxplovecc commented on a diff in pull request #357: [FLINK-29922] Support create external table for hive catalog

2022-11-13 Thread GitBox


wxplovecc commented on code in PR #357:
URL: https://github.com/apache/flink-table-store/pull/357#discussion_r1021091587


##
flink-table-store-hive/flink-table-store-hive-catalog/src/main/java/org/apache/flink/table/store/hive/HiveCatalog.java:
##
@@ -226,6 +227,13 @@ public void createTable(ObjectPath tablePath, UpdateSchema 
updateSchema, boolean
 e);
 }
 Table table = newHmsTable(tablePath);
+
+if (hiveConf.getEnum(TABLE_TYPE.key(), TableType.MANAGED_TABLE)

Review Comment:
   done



##
flink-table-store-core/src/main/java/org/apache/flink/table/store/table/TableType.java:
##
@@ -0,0 +1,25 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.flink.table.store.table;
+
+/** Enum of catalog table type. */
+public enum TableType {
+MANAGED_TABLE,

Review Comment:
   updated



-- 
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: issues-unsubscr...@flink.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



[GitHub] [flink-table-store] wxplovecc commented on a diff in pull request #357: [FLINK-29922] Support create external table for hive catalog

2022-11-10 Thread GitBox


wxplovecc commented on code in PR #357:
URL: https://github.com/apache/flink-table-store/pull/357#discussion_r1018875597


##
flink-table-store-core/src/main/java/org/apache/flink/table/store/CatalogOptions.java:
##
@@ -49,6 +49,12 @@ private CatalogOptions() {}
 .noDefaultValue()
 .withDescription("Uri of metastore server.");
 
+public static final ConfigOption HMS_EXTERNAL =
+ConfigOptions.key("hms.external")

Review Comment:
   @SteNicholas Thanks for review, updated



-- 
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: issues-unsubscr...@flink.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org