[
https://issues.apache.org/jira/browse/HIVE-25200?focusedWorklogId=608401&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-608401
]
ASF GitHub Bot logged work on HIVE-25200:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 08/Jun/21 11:22
Start Date: 08/Jun/21 11:22
Worklog Time Spent: 10m
Work Description: szlta commented on a change in pull request #2351:
URL: https://github.com/apache/hive/pull/2351#discussion_r647344754
##########
File path:
iceberg/iceberg-handler/src/main/java/org/apache/iceberg/mr/hive/HiveIcebergMetaHook.java
##########
@@ -310,6 +335,24 @@ public void
rollbackAlterTable(org.apache.hadoop.hive.metastore.api.Table hmsTab
}
}
+ private void setupAlterOperationType(EnvironmentContext context) throws
MetaException {
+ if (context != null) {
+ Map<String, String> contextProperties = context.getProperties();
+ if (contextProperties != null) {
+ String stringOpType =
contextProperties.get(ALTER_TABLE_OPERATION_TYPE);
+ if (stringOpType != null) {
+ currentAlterTableOp = AlterTableType.valueOf(stringOpType);
+ if (SUPPORTED_ALTER_OPS.stream().noneMatch(op ->
op.equals(currentAlterTableOp))) {
+ throw new MetaException(
+ "Unsupported ALTER TABLE operation type for Iceberg tables,
must be: " + allowedAlterTypes.toString());
+ }
+ }
+ return;
Review comment:
Yeah I found that it is valid as tests started to fail after the recent
refactor :D E.g. for analyze+compute_stats query there's an alter table
invocation, where there's no operation type among the context properties. Our
hook should not fail for such cases, but rather act as no-op.
--
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]
Issue Time Tracking
-------------------
Worklog Id: (was: 608401)
Time Spent: 4.5h (was: 4h 20m)
> Alter table add columns support for Iceberg tables
> --------------------------------------------------
>
> Key: HIVE-25200
> URL: https://issues.apache.org/jira/browse/HIVE-25200
> Project: Hive
> Issue Type: Improvement
> Reporter: Ádám Szita
> Assignee: Ádám Szita
> Priority: Major
> Labels: pull-request-available
> Time Spent: 4.5h
> Remaining Estimate: 0h
>
> Since Iceberg counts as being a non-native Hive table, addColumn operation
> needs to be implemented by the help of Hive meta hooks.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)