|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Object org.apache.spark.sql.SQLContext org.apache.spark.sql.hive.HiveContext
public class HiveContext
An instance of the Spark SQL execution engine that integrates with data stored in Hive. Configuration for Hive is read from hive-site.xml on the classpath.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.apache.spark.sql.SQLContext |
---|
SQLContext.implicits$ |
Constructor Summary | |
---|---|
HiveContext(SparkContext sc)
|
Method Summary | |
---|---|
void |
analyze(String tableName)
Analyzes the given table in the current database to generate statistics, which will be used in query optimizations. |
static String |
HIVE_METASTORE_JARS()
|
static String |
HIVE_METASTORE_VERSION()
|
static String |
hiveExecutionVersion()
The version of hive used internally by Spark SQL. |
static scala.collection.immutable.Map<String,String> |
newTemporaryConfiguration()
Constructs a configuration for hive, where the metastore is located in a temp directory. |
void |
refreshTable(String tableName)
Invalidate and refresh all the cached the metadata of the given table. |
void |
setConf(String key,
String value)
Set the given Spark SQL configuration property. |
Methods inherited from class org.apache.spark.sql.SQLContext |
---|
applySchema, applySchema, applySchema, applySchema, baseRelationToDataFrame, cacheTable, clearCache, createDataFrame, createDataFrame, createDataFrame, createDataFrame, createDataFrame, createDataFrame, createExternalTable, createExternalTable, createExternalTable, createExternalTable, createExternalTable, createExternalTable, dropTempTable, emptyDataFrame, experimental, getAllConfs, getConf, getConf, getOrCreate, implicits, isCached, jdbc, jdbc, jdbc, jsonFile, jsonFile, jsonFile, jsonRDD, jsonRDD, jsonRDD, jsonRDD, jsonRDD, jsonRDD, load, load, load, load, load, load, parquetFile, parquetFile, range, range, range, read, setConf, sparkContext, sql, table, tableNames, tableNames, tables, tables, udf, uncacheTable |
Methods inherited from class Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.spark.Logging |
---|
initializeIfNecessary, initializeLogging, isTraceEnabled, log_, log, logDebug, logDebug, logError, logError, logInfo, logInfo, logName, logTrace, logTrace, logWarning, logWarning |
Constructor Detail |
---|
public HiveContext(SparkContext sc)
Method Detail |
---|
public static String hiveExecutionVersion()
public static String HIVE_METASTORE_VERSION()
public static String HIVE_METASTORE_JARS()
public static scala.collection.immutable.Map<String,String> newTemporaryConfiguration()
public void refreshTable(String tableName)
tableName
- (undocumented)public void analyze(String tableName)
Right now, it only supports Hive tables and it only updates the size of a Hive table in the Hive metastore.
tableName
- (undocumented)public void setConf(String key, String value)
SQLContext
setConf
in class SQLContext
key
- (undocumented)value
- (undocumented)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |