|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface HiveOperations
Interface specifying a basic set of Hive operations. Implemented by HiveTemplate.
Not often used directly, but a useful option to enhance testability, as it can easily be mocked or stubbed.
| Method Summary | ||
|---|---|---|
|
execute(HiveClientCallback<T> action)
Executes the action specified by the given callback object within an active HiveClient. |
|
List<String> |
executeScript(HiveScript script)
Executes a Hive script. |
|
List<String> |
executeScript(Iterable<HiveScript> scripts)
Executes multiple Hive scripts. |
|
List<String> |
query(String query)
Executes the given HiveQL that results in a list of objects. |
|
List<String> |
query(String query,
Map<?,?> arguments)
Executes the given HiveQL using the list of arguments, expecting a list of objects. |
|
Integer |
queryForInt(String query)
Executes the given HiveQL that results in a single int value. |
|
Integer |
queryForInt(String query,
Map<?,?> arguments)
Executes the given HiveQL using the list of arguments, that results in a single int value. |
|
Long |
queryForLong(String query)
Executes the given HiveQL that results in a single long value. |
|
Long |
queryForLong(String query,
Map<?,?> arguments)
Executes the given HiveQL using the list of arguments, that results in a single long value. |
|
String |
queryForString(String query)
Executes the given HiveQL that results in a single object. |
|
String |
queryForString(String query,
Map<?,?> arguments)
Executes the given HiveQL using the list of arguments, that results in a single object. |
|
| Method Detail |
|---|
<T> T execute(HiveClientCallback<T> action)
throws DataAccessException
HiveClient.
action - callback object taht specifies the Hive action
DataAccessException
List<String> query(String query)
throws DataAccessException
query - HiveQL
DataAccessException
List<String> query(String query,
Map<?,?> arguments)
throws DataAccessException
query - HiveQLarguments - query arguments
DataAccessException
String queryForString(String query)
throws DataAccessException
query - HiveQL
DataAccessException
String queryForString(String query,
Map<?,?> arguments)
throws DataAccessException
query - HiveQLarguments - query arguments
DataAccessException
Integer queryForInt(String query)
throws DataAccessException
query - HiveQL
DataAccessException
Integer queryForInt(String query,
Map<?,?> arguments)
throws DataAccessException
query - HiveQLarguments - query arguments
DataAccessException
Long queryForLong(String query)
throws DataAccessException
query - HiveQL
DataAccessException
Long queryForLong(String query,
Map<?,?> arguments)
throws DataAccessException
query - HiveQLarguments - query arguments
DataAccessException
List<String> executeScript(HiveScript script)
throws DataAccessException
script - script resource and arguments
DataAccessException
List<String> executeScript(Iterable<HiveScript> scripts)
throws DataAccessException
scripts - script resources and arguments
DataAccessException
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||