Presto Hive StorageHandler - outputFormat should not be accessed from a null StorageFormat Error
See original GitHub issueHi,
I’m working with presto 0.170 version. Everything is working awesome, except Hive Custom Storage Handler external tables.
Getting outputFormat should not be accessed from a null StorageFormat
error. Please help to fix.
Table DDL:
hive > show create table flights_hbase
CREATE EXTERNAL TABLE flights_hbase (
flight_id string,
flightnum string
)
STORED BY 'org.apache.hadoop.hive.hbase.HBaseStorageHandler'
WITH SERDEPROPERTIES ("hbase.columns.mapping" = ":key,cols:flightnum")
TBLPROPERTIES ("hbase.table.name" = "flights");
hive >
Added required storage handler and related jars to plugin connector dir on all worker and master nodes and restarted presto
$ ls -ltr /usr/local/presto-server-0.170/plugin/hive-hadoop2/h*
-rwxr-xr-x. 1 root root 24164995 Mar 26 19:15 /usr/local/presto-server-0.170/plugin/hive-hadoop2/hadoop-apache2-0.10.jar
-rwxr-xr-x. 1 root root 736658 Mar 26 19:15 /usr/local/presto-server-0.170/plugin/hive-hadoop2/httpclient-4.5.2.jar
-rwxr-xr-x. 1 root root 26409112 Mar 26 19:15 /usr/local/presto-server-0.170/plugin/hive-hadoop2/hive-apache-1.2.0-1.jar
-rwxr-xr-x. 1 root root 326724 Mar 26 19:15 /usr/local/presto-server-0.170/plugin/hive-hadoop2/httpcore-4.4.4.jar
-rwxr-xr-x. 1 root root 901834 Mar 26 19:15 /usr/local/presto-server-0.170/plugin/hive-hadoop2/hive-dwrf-0.8.2.jar
-rwxr-xr-x. 1 prabhu prabhu 1366504 Mar 31 23:58 /usr/local/presto-server-0.170/plugin/hive-hadoop2/hbase-client.jar
-rwxr-xr-x. 1 prabhu prabhu 557343 Mar 31 23:58 /usr/local/presto-server-0.170/plugin/hive-hadoop2/hbase-common.jar
-rwxr-xr-x. 1 prabhu prabhu 4753129 Mar 31 23:58 /usr/local/presto-server-0.170/plugin/hive-hadoop2/hbase-protocol.jar
-rwxr-xr-x. 1 prabhu prabhu 4457393 Mar 31 23:59 /usr/local/presto-server-0.170/plugin/hive-hadoop2/hbase-server.jar
-rwxr-xr-x. 1 prabhu prabhu 118707 Mar 31 23:59 /usr/local/presto-server-0.170/plugin/hive-hadoop2/hive-hbase-handler-1.2.1000.2.5.3.0-37.jar
$
Querying on Presto:
presto:default> select * from flights_hbase limit 5;
Query 20170331_235243_00026_8wscc failed: outputFormat should not be accessed from a null StorageFormat
presto:default>
Thanks Prabhu
Issue Analytics
- State:
- Created 6 years ago
- Comments:6 (4 by maintainers)
Top Results From Across the Web
Athena : serDe should not be accessed from a null ...
While I'm running query against that table in Athena , getting below error. HIVE_UNKNOWN_ERROR: serDe should not be accessed from a null StorageFormat....
Read more >presto报错:outputFormat should not be accessed from a null ...
像hbase,es这种在hive见外部表对于presto都是不可行的,也就是hive表InputFormat、OutputFormat不能为空,如下图就不行:...
Read more >HiveMetastore outputFormat should not be accessed from a ...
HiveMetastore outputFormat should not be accessed from a null StorageFormat ... With this commit , starting Presto 0.152, we can't query System ...
Read more >11.2. Hive Connector — Presto 0.141t Documentation
Metadata about how the data files are mapped to schemas and tables. This metadata is stored in a database such as MySQL and...
Read more >Spark SQL and DataFrames - Spark 2.3.2 Documentation
To use these features, you do not need to have an existing Hive setup. Creating DataFrames. Scala; Java; Python; R. With a SparkSession...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Thanks @dain!
Does presto support other custom storage handlers? I’m trying to query Elastic Search External Hive table through presto and getting the same error.
Please advice.
Thanks Prabhu
Not yet today.
This issue looks like a duplicate https://github.com/prestodb/presto/issues/6972