[
https://issues.apache.org/jira/browse/HIVE-10324?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14504085#comment-14504085
]
Ferdinand Xu commented on HIVE-10324:
-------------------------------------
Hi [~leftylev], here comes the output for help option. And I have updated the
fixed version. If you need any other information about metatool, feel free to
let me know. Thank you!
{noformat}
Initializing HiveMetaTool..
usage: metatool
-dryRun Perform a dry run of updateLocation
changes.When run with the dryRun
option updateLocation changes are
displayed but not persisted. dryRun
is valid only with the
updateLocation option.
-executeJDOQL <query-string> execute the given JDOQL query
-help print this message
-listFSRoot print the current FS root locations
-serdePropKey <serde-prop-key> Specify the key for serde property
to be updated. serdePropKey option
is valid only with updateLocation
option.
-tablePropKey <table-prop-key> Specify the key for table property
to be updated. tablePropKey option
is valid only with updateLocation
option.
-updateLocation <new-loc> <old-loc> Update FS root location in the
metastore to new location.Both
new-loc and old-loc should be valid
URIs with valid host names and
schemes.When run with the dryRun
option changes are displayed but
are not persisted. When run with
the serdepropKey/tablePropKey
option updateLocation looks for the
serde-prop-key/table-prop-key that
is specified and updates its value
if found.
{noformat}
> Hive metatool should take table_param_key to allow for changes to avro
> serde's schema url key
> ---------------------------------------------------------------------------------------------
>
> Key: HIVE-10324
> URL: https://issues.apache.org/jira/browse/HIVE-10324
> Project: Hive
> Issue Type: Bug
> Components: Metastore
> Affects Versions: 1.1.0
> Reporter: Szehon Ho
> Assignee: Ferdinand Xu
> Fix For: 1.2.0
>
> Attachments: HIVE-10324.1.patch, HIVE-10324.patch,
> HIVE-10324.patch.WIP
>
>
> HIVE-3443 added support to change the serdeParams from 'metatool
> updateLocation' command.
> However, in avro it is possible to specify the schema via the tableParams:
> {noformat}
> CREATE TABLE `testavro`(
> `test` string COMMENT 'from deserializer')
> ROW FORMAT SERDE
> 'org.apache.hadoop.hive.serde2.avro.AvroSerDe'
> STORED AS INPUTFORMAT
> 'org.apache.hadoop.hive.ql.io.avro.AvroContainerInputFormat'
> OUTPUTFORMAT
> 'org.apache.hadoop.hive.ql.io.avro.AvroContainerOutputFormat'
> TBLPROPERTIES (
> 'avro.schema.url'='hdfs://namenode:8020/tmp/test.avsc',
> 'kite.compression.type'='snappy',
> 'transient_lastDdlTime'='1427996456')
> {noformat}
> Hence for those tables the 'metatool updateLocation' will not help.
> This is necessary in case like upgrade the namenode to HA where the absolute
> paths have changed.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)