[
https://issues.apache.org/jira/browse/HIVE-26952?focusedWorklogId=840413&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-840413
]
ASF GitHub Bot logged work on HIVE-26952:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 19/Jan/23 18:33
Start Date: 19/Jan/23 18:33
Worklog Time Spent: 10m
Work Description: saihemanth-cloudera commented on code in PR #3959:
URL: https://github.com/apache/hive/pull/3959#discussion_r1081666470
##########
standalone-metastore/metastore-server/pom.xml:
##########
@@ -30,6 +30,12 @@
<artifactId>hive-standalone-metastore-common</artifactId>
<version>4.0.0-SNAPSHOT</version>
</dependency>
+ <dependency>
+ <groupId>org.apache.hive</groupId>
+ <artifactId>hive-metastore</artifactId>
Review Comment:
Why do you need to add this dependency? I don't think this is required.
##########
standalone-metastore/metastore-common/src/main/java/org/apache/hadoop/hive/metastore/conf/MetastoreConf.java:
##########
@@ -1363,7 +1366,7 @@ public enum ConfVars {
"hive.metastore.stats.auto.analyze.worker.count", 1,
"Number of parallel analyze commands to run for background stats
update."),
STORAGE_SCHEMA_READER_IMPL("metastore.storage.schema.reader.impl",
"metastore.storage.schema.reader.impl",
- DEFAULT_STORAGE_SCHEMA_READER_CLASS,
+ SERDE_STORAGE_SCHEMA_READER_CLASS,
Review Comment:
Does this work with other storage formats like ORC, parquet, and textfile? I
see that SERDE_STORAGE_SCHEMA_READER is compatible with Iceberg which is
awesome.
##########
standalone-metastore/metastore-server/src/test/java/org/apache/hadoop/hive/metastore/conf/TestMetastoreConf.java:
##########
@@ -482,6 +483,8 @@ public void dumpConfig() throws IOException {
public void testClassNames() {
Assert.assertEquals(MetastoreConf.DEFAULT_STORAGE_SCHEMA_READER_CLASS,
DefaultStorageSchemaReader.class.getName());
+ Assert.assertEquals(MetastoreConf.SERDE_STORAGE_SCHEMA_READER_CLASS,
Review Comment:
Can you add a unit test/q test with the failed test case? Also, it would be
nice to add other storage format options along with Avro.
Issue Time Tracking
-------------------
Worklog Id: (was: 840413)
Time Spent: 1h (was: 50m)
> set the value of metastore.storage.schema.reader.impl
to
> org.apache.hadoop.hive.metastore.SerDeStorageSchemaReader as default
> ------------------------------------------------------------------------------------------------------------------------------
>
> Key: HIVE-26952
> URL: https://issues.apache.org/jira/browse/HIVE-26952
> Project: Hive
> Issue Type: Improvement
> Components: Standalone Metastore
> Reporter: Taraka Rama Rao Lethavadla
> Assignee: Taraka Rama Rao Lethavadla
> Priority: Minor
> Labels: pull-request-available
> Time Spent: 1h
> Remaining Estimate: 0h
>
> With the default value of
>
> {code:java}
> DefaultStorageSchemaReader.class.getName(){code}
>
> in the Metastore Config, *metastore.storage.schema.reader.impl*
> below exception is thrown when trying to read Avro schema
> {noformat}
> Caused by: org.apache.hive.service.cli.HiveSQLException: MetaException
> (message:java.lang.UnsupportedOperationException: Storage schema reading not
> supported)
> at
> org.apache.hive.service.cli.operation.GetColumnsOperation.runInternal(GetColumnsOperation.java:213)
> at org.apache.hive.service.cli.operation.Operation.run(Operation.java:247)
> at
> org.apache.hive.service.cli.session.HiveSessionImpl.getColumns(HiveSessionImpl.java:729)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> at java.lang.reflect.Method.invoke(Method.java:498)
> at
> org.apache.hive.service.cli.session.HiveSessionProxy.invoke(HiveSessionProxy.java:78)
> at
> org.apache.hive.service.cli.session.HiveSessionProxy.access-zsh(HiveSessionProxy.java:36)
> at
> org.apache.hive.service.cli.session.HiveSessionProxy.run(HiveSessionProxy.java:63)
> at java.security.AccessController.doPrivileged(Native Method)
> at javax.security.auth.Subject.doAs(Subject.java:422)
> at
> org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1730)
> at
> org.apache.hive.service.cli.session.HiveSessionProxy.invoke(HiveSessionProxy.java:59)
> at com.sun.proxy..getColumns(Unknown Source)
> at
> org.apache.hive.service.cli.CLIService.getColumns(CLIService.java:390){noformat}
> setting the above config with
> *org.apache.hadoop.hive.metastore.SerDeStorageSchemaReader* resolves issue
> Proposing to make this value as default in code base, so that in upcoming
> versions we don't have to set this value manually
--
This message was sent by Atlassian Jira
(v8.20.10#820010)