public class Utils
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
Utils.JdbcConnectionParams |
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
DEFAULT_DATABASE
Hive's default database name
|
static java.lang.String |
DEFAULT_PORT
If host is provided, without a port.
|
static java.lang.String |
URL_PREFIX
The required prefix for the connection URL.
|
Constructor and Description |
---|
Utils() |
Modifier and Type | Method and Description |
---|---|
static int |
hiveTypeToSqlType(java.lang.String type)
Convert hive types to sql types.
|
static Utils.JdbcConnectionParams |
parseURL(java.lang.String uri)
Parse JDBC connection URL
The new format of the URL is jdbc:hive2://
|
static void |
verifySuccess(TStatus status) |
static void |
verifySuccess(TStatus status,
boolean withInfo) |
static void |
verifySuccessWithInfo(TStatus status) |
public static final java.lang.String URL_PREFIX
public static final java.lang.String DEFAULT_PORT
public static final java.lang.String DEFAULT_DATABASE
public static int hiveTypeToSqlType(java.lang.String type) throws java.sql.SQLException
type
- java.sql.SQLException
public static void verifySuccessWithInfo(TStatus status) throws java.sql.SQLException
java.sql.SQLException
public static void verifySuccess(TStatus status) throws java.sql.SQLException
java.sql.SQLException
public static void verifySuccess(TStatus status, boolean withInfo) throws java.sql.SQLException
java.sql.SQLException
public static Utils.JdbcConnectionParams parseURL(java.lang.String uri) throws java.lang.IllegalArgumentException
uri
- java.lang.IllegalArgumentException
Copyright © 2012 The Apache Software Foundation