|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.hadoop.hbase.client.HConnectionManager.HConnectionImplementation
org.apache.hadoop.hbase.client.CoprocessorHConnection
@InterfaceAudience.Private @InterfaceStability.Evolving public class CoprocessorHConnection
Connection to an HTable from within a Coprocessor. We can do some nice tricks since we know we are on a regionserver, for instance skipping the full serialization/deserialization of objects when talking to the server.
You should not use this class from any client - its an internal class meant for use by the coprocessor framework.
Field Summary |
---|
Fields inherited from class org.apache.hadoop.hbase.client.HConnectionManager.HConnectionImplementation |
---|
clusterId, user |
Fields inherited from interface org.apache.hadoop.hbase.client.HConnection |
---|
HBASE_CLIENT_CONNECTION_IMPL |
Constructor Summary | |
---|---|
CoprocessorHConnection(org.apache.hadoop.conf.Configuration conf,
HRegionServer server)
Constructor that accepts custom configuration |
|
CoprocessorHConnection(HConnection delegate,
HRegionServer server)
Deprecated. delegate is not used |
|
CoprocessorHConnection(HRegionServer server)
Constructor that uses server configuration |
Method Summary | |
---|---|
ClientProtos.ClientService.BlockingInterface |
getClient(ServerName serverName)
Establishes a connection to the region server at the specified address, and returns a region client protocol. |
static HConnection |
getConnectionForEnvironment(CoprocessorEnvironment env)
Create an unmanaged HConnection based on the environment in which we are running the
coprocessor. |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
@Deprecated public CoprocessorHConnection(HConnection delegate, HRegionServer server) throws IOException
delegate
- server
-
IOException
- if we cannot create the connectionpublic CoprocessorHConnection(HRegionServer server) throws IOException
server
-
IOException
- if we cannot create the connectionpublic CoprocessorHConnection(org.apache.hadoop.conf.Configuration conf, HRegionServer server) throws IOException
conf
- server
-
IOException
- if we cannot create the connectionMethod Detail |
---|
public static HConnection getConnectionForEnvironment(CoprocessorEnvironment env) throws IOException
HConnection
based on the environment in which we are running the
coprocessor. The HConnection
must be externally cleaned up (we bypass the usual HTable
cleanup mechanisms since we own everything).
env
- environment hosting the HConnection
HConnection
.
IOException
- if we cannot create the connectionpublic ClientProtos.ClientService.BlockingInterface getClient(ServerName serverName) throws IOException
HConnection
getClient
in interface HConnection
getClient
in class HConnectionManager.HConnectionImplementation
IOException
- if a remote or network exception occurs
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |