Snowflake Hive Metastore Connector


License

License

Categories

Categories

Net
GroupId

GroupId

net.snowflake
ArtifactId

ArtifactId

snowflake-hive-metastore-connector
Last Version

Last Version

0.5.1
Release Date

Release Date

Type

Type

jar
Description

Description

Snowflake Hive Metastore Connector
Snowflake Hive Metastore Connector
Project URL

Project URL

https://www.snowflake.net/
Source Code Management

Source Code Management

http://github.com/snowflakedb/snowflake-hive-metastore-connector/tree/master

Download snowflake-hive-metastore-connector

How to add to project

<!-- https://jarcasting.com/artifacts/net.snowflake/snowflake-hive-metastore-connector/ -->
<dependency>
    <groupId>net.snowflake</groupId>
    <artifactId>snowflake-hive-metastore-connector</artifactId>
    <version>0.5.1</version>
</dependency>
// https://jarcasting.com/artifacts/net.snowflake/snowflake-hive-metastore-connector/
implementation 'net.snowflake:snowflake-hive-metastore-connector:0.5.1'
// https://jarcasting.com/artifacts/net.snowflake/snowflake-hive-metastore-connector/
implementation ("net.snowflake:snowflake-hive-metastore-connector:0.5.1")
'net.snowflake:snowflake-hive-metastore-connector:jar:0.5.1'
<dependency org="net.snowflake" name="snowflake-hive-metastore-connector" rev="0.5.1">
  <artifact name="snowflake-hive-metastore-connector" type="jar" />
</dependency>
@Grapes(
@Grab(group='net.snowflake', module='snowflake-hive-metastore-connector', version='0.5.1')
)
libraryDependencies += "net.snowflake" % "snowflake-hive-metastore-connector" % "0.5.1"
[net.snowflake/snowflake-hive-metastore-connector "0.5.1"]

Dependencies

There are no dependencies for this project. It is a standalone project that does not depend on any other jars.

Project Modules

There are no modules declared in this project.

Snowflake Hive Metastore Connector

https://travis-ci.com/snowflakedb/snowflake-hive-metastore-connector.svg?branch=master https://maven-badges.herokuapp.com/maven-central/net.snowflake/snowflake-hive-metastore-connector/badge.svg?style=plastic

The Snowflake Hive metastore connector provides an easy way to query Hive-managed data via Snowflake. Once installed, the connector listens to Hive metastore events and creates the equivalent Snowflake objects. See also: https://docs.snowflake.net/manuals/user-guide/tables-external-hive.html

Installation:

  1. Create a new file named 'snowflake-config.xml' to the same directory that contains hive-site.xml. This will be the configuration file for the connector. This configuration file should look like:

    <configuration>
      <property>
        <name>snowflake.jdbc.username</name>
        <value>...</value>
      </property>
      <property>
        <name>snowflake.jdbc.password</name>
        <value>...</value>
      </property>
      <property>
        <name>snowflake.jdbc.role</name>
        <value>...</value>
      </property>
      <property>
        <name>snowflake.jdbc.account</name>
        <value>...</value>
      </property>
      <property>
        <name>snowflake.jdbc.db</name>
        <value>...</value>
      </property>
      <property>
        <name>snowflake.jdbc.schema</name>
        <value>...</value>
      </property>
      <property>
        <name>snowflake.jdbc.connection</name>
        <value>jdbc:snowflake://account.snowflakecomputing.com</value>
      </property>
      <property>
        <name>snowflake.hive-metastore-listener.integration</name>
        <value>...</value>
      </property>
    </configuration>
  2. Package the jar by running:

    mvn package

    Or download the jar from Maven: https://repo1.maven.org/maven2/net/snowflake/

  3. Copy the jar into the Hive classpath

  4. Update the Hive metastore configuration to point to the listener. To do this, simply add the following section to hive-site.xml:

    <configuration>
      ...
      <property>
        <name>hive.metastore.event.listeners</name>
        <value>net.snowflake.hivemetastoreconnector.SnowflakeHiveListener</value>
      </property>
    </configuration>
  5. Restart the Hive metastore.

Usage:

  1. In Hive, touch partitions to be used in Snowflake:

    alter table <table_name> touch partition <partition_spec>;
    

    Or for non-partitioned Hive tables:

    alter table <table_name> touch;
    
  2. Query the table in Snowflake:

    select * from <table_name>;
    
net.snowflake

Snowflake Computing

Versions

Version
0.5.1
0.5.0
0.3.0