public interface HiveClientCallback<T>
HiveTemplate execute method, assumably often as anonymous
classes within a method implementation.| Modifier and Type | Method and Description |
|---|---|
T |
doInHive(org.apache.hadoop.hive.service.HiveClient hiveClient)
Gets called by
HiveTemplate.execute(HiveClientCallback) with an active HiveClient. |
T doInHive(org.apache.hadoop.hive.service.HiveClient hiveClient) throws java.lang.Exception
HiveTemplate.execute(HiveClientCallback) with an active HiveClient. Does not need to
care about activating or closing the HiveClient, or handling exceptions.
Due to the big number of exceptions thrown by HiveClient (in particular
ThriftHiveMetastore.Client) which do not share any common base class,
the callback signature uses a generic declaration.
For user specific error, consider runtime exceptions which are not translated.hiveClient - active hive clientjava.lang.Exception - if thrown by HiveClient