blob: 9312c4bcb4f706ce7e7b3c9410e3787500ca36af [file] [log] [blame]
<!DOCTYPE HTML>
<html lang="en">
<head>
<!-- Generated by javadoc (17) -->
<title>Connection (Apache HBase 4.0.0-alpha-1-SNAPSHOT API)</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="description" content="declaration: package: org.apache.hadoop.hbase.client, interface: Connection">
<meta name="generator" content="javadoc/ClassWriterImpl">
<link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../../../script-dir/jquery-ui.min.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../../../jquery-ui.overrides.css" title="Style">
<script type="text/javascript" src="../../../../../script.js"></script>
<script type="text/javascript" src="../../../../../script-dir/jquery-3.6.1.min.js"></script>
<script type="text/javascript" src="../../../../../script-dir/jquery-ui.min.js"></script>
</head>
<body class="class-declaration-page">
<script type="text/javascript">var evenRowColor = "even-row-color";
var oddRowColor = "odd-row-color";
var tableTab = "table-tab";
var activeTableTab = "active-table-tab";
var pathtoroot = "../../../../../";
loadScripts(document, 'script');</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<div class="flex-box">
<header role="banner" class="flex-header">
<nav role="navigation">
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="top-nav" id="navbar-top">
<div class="skip-nav"><a href="#skip-navbar-top" title="Skip navigation links">Skip navigation links</a></div>
<ul id="navbar-top-firstrow" class="nav-list" title="Navigation">
<li><a href="../../../../../index.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="nav-bar-cell1-rev">Class</li>
<li><a href="class-use/Connection.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html#class">Help</a></li>
</ul>
</div>
<div class="sub-nav">
<div>
<ul class="sub-nav-list">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method-summary">Method</a></li>
</ul>
<ul class="sub-nav-list">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li>Constr&nbsp;|&nbsp;</li>
<li><a href="#method-detail">Method</a></li>
</ul>
</div>
<div class="nav-list-search"><label for="search-input">SEARCH:</label>
<input type="text" id="search-input" value="search" disabled="disabled">
<input type="reset" id="reset-button" value="reset" disabled="disabled">
</div>
</div>
<!-- ========= END OF TOP NAVBAR ========= -->
<span class="skip-nav" id="skip-navbar-top"></span></nav>
</header>
<div class="flex-content">
<main role="main">
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="sub-title"><span class="package-label-in-type">Package</span>&nbsp;<a href="package-summary.html">org.apache.hadoop.hbase.client</a></div>
<h1 title="Interface Connection" class="title">Interface Connection</h1>
</div>
<section class="class-description" id="class-description">
<dl class="notes">
<dt>All Superinterfaces:</dt>
<dd><code><a href="../Abortable.html" title="interface in org.apache.hadoop.hbase">Abortable</a></code>, <code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/AutoCloseable.html" title="class or interface in java.lang" class="external-link">AutoCloseable</a></code>, <code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/Closeable.html" title="class or interface in java.io" class="external-link">Closeable</a></code></dd>
</dl>
<dl class="notes">
<dt>All Known Implementing Classes:</dt>
<dd><code><a href="ConnectionOverAsyncConnection.html" title="class in org.apache.hadoop.hbase.client">ConnectionOverAsyncConnection</a></code>, <code><a href="SharedConnection.html" title="class in org.apache.hadoop.hbase.client">SharedConnection</a></code>, <code><a href="../thrift2/client/ThriftConnection.html" title="class in org.apache.hadoop.hbase.thrift2.client">ThriftConnection</a></code></dd>
</dl>
<hr>
<div class="type-signature"><span class="annotations">@Public
</span><span class="modifiers">public interface </span><span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-51">Connection</a></span><span class="extends-implements">
extends <a href="../Abortable.html" title="interface in org.apache.hadoop.hbase">Abortable</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/Closeable.html" title="class or interface in java.io" class="external-link">Closeable</a></span></div>
<div class="block">A cluster connection encapsulating lower level individual connections to actual servers and a
connection to zookeeper. Connections are instantiated through the <a href="ConnectionFactory.html" title="class in org.apache.hadoop.hbase.client"><code>ConnectionFactory</code></a>
class. The lifecycle of the connection is managed by the caller, who has to <a href="#close()"><code>close()</code></a> the
connection to release the resources.
<p>
The connection object contains logic to find the master, locate regions out on the cluster, keeps
a cache of locations and then knows how to re-calibrate after they move. The individual
connections to servers, meta cache, zookeeper connection, etc are all shared by the <a href="Table.html" title="interface in org.apache.hadoop.hbase.client"><code>Table</code></a>
and <a href="Admin.html" title="interface in org.apache.hadoop.hbase.client"><code>Admin</code></a> instances obtained from this connection.
<p>
Connection creation is a heavy-weight operation. Connection implementations are thread-safe, so
that the client can create a connection once, and share it with different threads. <a href="Table.html" title="interface in org.apache.hadoop.hbase.client"><code>Table</code></a>
and <a href="Admin.html" title="interface in org.apache.hadoop.hbase.client"><code>Admin</code></a> instances, on the other hand, are light-weight and are not thread-safe.
Typically, a single connection per client application is instantiated and every thread will
obtain its own Table instance. Caching or pooling of <a href="Table.html" title="interface in org.apache.hadoop.hbase.client"><code>Table</code></a> and <a href="Admin.html" title="interface in org.apache.hadoop.hbase.client"><code>Admin</code></a> is not
recommended.</div>
<dl class="notes">
<dt>Since:</dt>
<dd>0.99.0</dd>
<dt>See Also:</dt>
<dd>
<ul class="see-list">
<li><a href="ConnectionFactory.html" title="class in org.apache.hadoop.hbase.client"><code>ConnectionFactory</code></a></li>
</ul>
</dd>
</dl>
</section>
<section class="summary">
<ul class="summary-list">
<!-- ========== METHOD SUMMARY =========== -->
<li>
<section class="method-summary" id="method-summary">
<h2>Method Summary</h2>
<div id="method-summary-table">
<div class="table-tabs" role="tablist" aria-orientation="horizontal"><button id="method-summary-table-tab0" role="tab" aria-selected="true" aria-controls="method-summary-table.tabpanel" tabindex="0" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table', 3)" class="active-table-tab">All Methods</button><button id="method-summary-table-tab2" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab2', 3)" class="table-tab">Instance Methods</button><button id="method-summary-table-tab3" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab3', 3)" class="table-tab">Abstract Methods</button><button id="method-summary-table-tab5" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab5', 3)" class="table-tab">Default Methods</button></div>
<div id="method-summary-table.tabpanel" role="tabpanel">
<div class="summary-table three-column-summary" aria-labelledby="method-summary-table-tab0">
<div class="table-header col-first">Modifier and Type</div>
<div class="table-header col-second">Method</div>
<div class="table-header col-last">Description</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#clearRegionLocationCache()" class="member-name-link">clearRegionLocationCache</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Clear all the entries in the region location cache, for all the tables.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>void</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#close()" class="member-name-link">close</a>()</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">&nbsp;</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="Admin.html" title="interface in org.apache.hadoop.hbase.client">Admin</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getAdmin()" class="member-name-link">getAdmin</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Retrieve an Admin implementation to administer an HBase cluster.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client">BufferedMutator</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getBufferedMutator(org.apache.hadoop.hbase.client.BufferedMutatorParams)" class="member-name-link">getBufferedMutator</a><wbr>(<a href="BufferedMutatorParams.html" title="class in org.apache.hadoop.hbase.client">BufferedMutatorParams</a>&nbsp;params)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Retrieve a <a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client"><code>BufferedMutator</code></a> for performing client-side buffering of writes.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code>default <a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client">BufferedMutator</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code><a href="#getBufferedMutator(org.apache.hadoop.hbase.TableName)" class="member-name-link">getBufferedMutator</a><wbr>(<a href="../TableName.html" title="class in org.apache.hadoop.hbase">TableName</a>&nbsp;tableName)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5">
<div class="block">
Retrieve a <a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client"><code>BufferedMutator</code></a> for performing client-side buffering of writes.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code>default <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code><a href="#getClusterId()" class="member-name-link">getClusterId</a>()</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5">
<div class="block">Returns the cluster ID unique to this HBase cluster.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>org.apache.hadoop.conf.Configuration</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getConfiguration()" class="member-name-link">getConfiguration</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Returns Configuration instance being used by this Connection instance.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code>default <a href="Hbck.html" title="interface in org.apache.hadoop.hbase.client">Hbck</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code><a href="#getHbck()" class="member-name-link">getHbck</a>()</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5">
<div class="block">Retrieve an Hbck implementation to fix an HBase cluster.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code>default <a href="Hbck.html" title="interface in org.apache.hadoop.hbase.client">Hbck</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code><a href="#getHbck(org.apache.hadoop.hbase.ServerName)" class="member-name-link">getHbck</a><wbr>(<a href="../ServerName.html" title="class in org.apache.hadoop.hbase">ServerName</a>&nbsp;masterServer)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5">
<div class="block">Retrieve an Hbck implementation to fix an HBase cluster.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="RegionLocator.html" title="interface in org.apache.hadoop.hbase.client">RegionLocator</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getRegionLocator(org.apache.hadoop.hbase.TableName)" class="member-name-link">getRegionLocator</a><wbr>(<a href="../TableName.html" title="class in org.apache.hadoop.hbase">TableName</a>&nbsp;tableName)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Retrieve a RegionLocator implementation to inspect region information on a table.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code>default <a href="Table.html" title="interface in org.apache.hadoop.hbase.client">Table</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code><a href="#getTable(org.apache.hadoop.hbase.TableName)" class="member-name-link">getTable</a><wbr>(<a href="../TableName.html" title="class in org.apache.hadoop.hbase">TableName</a>&nbsp;tableName)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5">
<div class="block">Retrieve a Table implementation for accessing a table.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code>default <a href="Table.html" title="interface in org.apache.hadoop.hbase.client">Table</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5"><code><a href="#getTable(org.apache.hadoop.hbase.TableName,java.util.concurrent.ExecutorService)" class="member-name-link">getTable</a><wbr>(<a href="../TableName.html" title="class in org.apache.hadoop.hbase">TableName</a>&nbsp;tableName,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/concurrent/ExecutorService.html" title="class or interface in java.util.concurrent" class="external-link">ExecutorService</a>&nbsp;pool)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab5">
<div class="block">Retrieve a Table implementation for accessing a table.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="TableBuilder.html" title="interface in org.apache.hadoop.hbase.client">TableBuilder</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#getTableBuilder(org.apache.hadoop.hbase.TableName,java.util.concurrent.ExecutorService)" class="member-name-link">getTableBuilder</a><wbr>(<a href="../TableName.html" title="class in org.apache.hadoop.hbase">TableName</a>&nbsp;tableName,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/concurrent/ExecutorService.html" title="class or interface in java.util.concurrent" class="external-link">ExecutorService</a>&nbsp;pool)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Returns an <a href="TableBuilder.html" title="interface in org.apache.hadoop.hbase.client"><code>TableBuilder</code></a> for creating <a href="Table.html" title="interface in org.apache.hadoop.hbase.client"><code>Table</code></a>.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code>boolean</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#isClosed()" class="member-name-link">isClosed</a>()</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Returns whether the connection is closed or not.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="AsyncConnection.html" title="interface in org.apache.hadoop.hbase.client">AsyncConnection</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3"><code><a href="#toAsyncConnection()" class="member-name-link">toAsyncConnection</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab3">
<div class="block">Convert this connection to an <a href="AsyncConnection.html" title="interface in org.apache.hadoop.hbase.client"><code>AsyncConnection</code></a>.</div>
</div>
</div>
</div>
</div>
<div class="inherited-list">
<h3 id="methods-inherited-from-class-org.apache.hadoop.hbase.Abortable">Methods inherited from interface&nbsp;org.apache.hadoop.hbase.<a href="../Abortable.html" title="interface in org.apache.hadoop.hbase">Abortable</a></h3>
<code><a href="../Abortable.html#abort(java.lang.String)">abort</a>, <a href="../Abortable.html#abort(java.lang.String,java.lang.Throwable)">abort</a>, <a href="../Abortable.html#isAborted()">isAborted</a></code></div>
</section>
</li>
</ul>
</section>
<section class="details">
<ul class="details-list">
<!-- ============ METHOD DETAIL ========== -->
<li>
<section class="method-details" id="method-detail">
<h2>Method Details</h2>
<ul class="member-list">
<li>
<section class="detail" id="getConfiguration()">
<h3>getConfiguration</h3>
<div class="member-signature"><span class="return-type">org.apache.hadoop.conf.Configuration</span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-63">getConfiguration</a></span>()</div>
<div class="block">Returns Configuration instance being used by this Connection instance.</div>
</section>
</li>
<li>
<section class="detail" id="getTable(org.apache.hadoop.hbase.TableName)">
<h3>getTable</h3>
<div class="member-signature"><span class="modifiers">default</span>&nbsp;<span class="return-type"><a href="Table.html" title="interface in org.apache.hadoop.hbase.client">Table</a></span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-77">getTable</a></span><wbr><span class="parameters">(<a href="../TableName.html" title="class in org.apache.hadoop.hbase">TableName</a>&nbsp;tableName)</span>
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div>
<div class="block">Retrieve a Table implementation for accessing a table. The returned Table is not thread safe, a
new instance should be created for each using thread. This is a lightweight operation, pooling
or caching of the returned Table is neither required nor desired.
<p>
The caller is responsible for calling <a href="Table.html#close()"><code>Table.close()</code></a> on the returned table instance.
<p>
Since 0.98.1 this method no longer checks table existence. An exception will be thrown if the
table does not exist only when the first operation is attempted.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>tableName</code> - the name of the table</dd>
<dt>Returns:</dt>
<dd>a Table to use for interactions with this table</dd>
<dt>Throws:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code></dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="getTable(org.apache.hadoop.hbase.TableName,java.util.concurrent.ExecutorService)">
<h3>getTable</h3>
<div class="member-signature"><span class="modifiers">default</span>&nbsp;<span class="return-type"><a href="Table.html" title="interface in org.apache.hadoop.hbase.client">Table</a></span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-94">getTable</a></span><wbr><span class="parameters">(<a href="../TableName.html" title="class in org.apache.hadoop.hbase">TableName</a>&nbsp;tableName,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/concurrent/ExecutorService.html" title="class or interface in java.util.concurrent" class="external-link">ExecutorService</a>&nbsp;pool)</span>
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div>
<div class="block">Retrieve a Table implementation for accessing a table. The returned Table is not thread safe, a
new instance should be created for each using thread. This is a lightweight operation, pooling
or caching of the returned Table is neither required nor desired.
<p>
The caller is responsible for calling <a href="Table.html#close()"><code>Table.close()</code></a> on the returned table instance.
<p>
Since 0.98.1 this method no longer checks table existence. An exception will be thrown if the
table does not exist only when the first operation is attempted.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>tableName</code> - the name of the table</dd>
<dd><code>pool</code> - The thread pool to use for batch operations, null to use a default pool.</dd>
<dt>Returns:</dt>
<dd>a Table to use for interactions with this table</dd>
<dt>Throws:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code></dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="getBufferedMutator(org.apache.hadoop.hbase.TableName)">
<h3>getBufferedMutator</h3>
<div class="member-signature"><span class="modifiers">default</span>&nbsp;<span class="return-type"><a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client">BufferedMutator</a></span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-114">getBufferedMutator</a></span><wbr><span class="parameters">(<a href="../TableName.html" title="class in org.apache.hadoop.hbase">TableName</a>&nbsp;tableName)</span>
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div>
<div class="block"><p>
Retrieve a <a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client"><code>BufferedMutator</code></a> for performing client-side buffering of writes. The
<a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client"><code>BufferedMutator</code></a> returned by this method is thread-safe. This BufferedMutator will use
the Connection's ExecutorService. This object can be used for long lived operations.
</p>
<p>
The caller is responsible for calling <a href="BufferedMutator.html#close()"><code>BufferedMutator.close()</code></a> on the returned
<a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client"><code>BufferedMutator</code></a> instance.
</p>
<p>
This accessor will use the connection's ExecutorService and will throw an exception in the main
thread when an asynchronous exception occurs.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>tableName</code> - the name of the table</dd>
<dt>Returns:</dt>
<dd>a <a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client"><code>BufferedMutator</code></a> for the supplied tableName.</dd>
<dt>Throws:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code></dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="getBufferedMutator(org.apache.hadoop.hbase.client.BufferedMutatorParams)">
<h3>getBufferedMutator</h3>
<div class="member-signature"><span class="return-type"><a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client">BufferedMutator</a></span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-126">getBufferedMutator</a></span><wbr><span class="parameters">(<a href="BufferedMutatorParams.html" title="class in org.apache.hadoop.hbase.client">BufferedMutatorParams</a>&nbsp;params)</span>
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div>
<div class="block">Retrieve a <a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client"><code>BufferedMutator</code></a> for performing client-side buffering of writes. The
<a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client"><code>BufferedMutator</code></a> returned by this method is thread-safe. This object can be used for
long lived table operations. The caller is responsible for calling
<a href="BufferedMutator.html#close()"><code>BufferedMutator.close()</code></a> on the returned <a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client"><code>BufferedMutator</code></a> instance.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>params</code> - details on how to instantiate the <code>BufferedMutator</code>.</dd>
<dt>Returns:</dt>
<dd>a <a href="BufferedMutator.html" title="interface in org.apache.hadoop.hbase.client"><code>BufferedMutator</code></a> for the supplied tableName.</dd>
<dt>Throws:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code></dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="getRegionLocator(org.apache.hadoop.hbase.TableName)">
<h3>getRegionLocator</h3>
<div class="member-signature"><span class="return-type"><a href="RegionLocator.html" title="interface in org.apache.hadoop.hbase.client">RegionLocator</a></span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-138">getRegionLocator</a></span><wbr><span class="parameters">(<a href="../TableName.html" title="class in org.apache.hadoop.hbase">TableName</a>&nbsp;tableName)</span>
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div>
<div class="block">Retrieve a RegionLocator implementation to inspect region information on a table. The returned
RegionLocator is not thread-safe, so a new instance should be created for each using thread.
This is a lightweight operation. Pooling or caching of the returned RegionLocator is neither
required nor desired. <br>
The caller is responsible for calling <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/Closeable.html#close()" title="class or interface in java.io" class="external-link"><code>Closeable.close()</code></a> on the returned
RegionLocator instance. RegionLocator needs to be unmanaged</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>tableName</code> - Name of the table who's region is to be examined</dd>
<dt>Returns:</dt>
<dd>A RegionLocator instance</dd>
<dt>Throws:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code></dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="clearRegionLocationCache()">
<h3>clearRegionLocationCache</h3>
<div class="member-signature"><span class="return-type">void</span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-148">clearRegionLocationCache</a></span>()</div>
<div class="block">Clear all the entries in the region location cache, for all the tables.
<p/>
If you only want to clear the cache for a specific table, use
<a href="RegionLocator.html#clearRegionLocationCache()"><code>RegionLocator.clearRegionLocationCache()</code></a>.
<p/>
This may cause performance issue so use it with caution.</div>
</section>
</li>
<li>
<section class="detail" id="getAdmin()">
<h3>getAdmin</h3>
<div class="member-signature"><span class="return-type"><a href="Admin.html" title="interface in org.apache.hadoop.hbase.client">Admin</a></span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-157">getAdmin</a></span>()
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div>
<div class="block">Retrieve an Admin implementation to administer an HBase cluster. The returned Admin is not
guaranteed to be thread-safe. A new instance should be created for each using thread. This is a
lightweight operation. Pooling or caching of the returned Admin is not recommended. <br>
The caller is responsible for calling <a href="Admin.html#close()"><code>Admin.close()</code></a> on the returned Admin instance.</div>
<dl class="notes">
<dt>Returns:</dt>
<dd>an Admin instance for cluster administration</dd>
<dt>Throws:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code></dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="close()">
<h3>close</h3>
<div class="member-signature"><span class="return-type">void</span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-159">close</a></span>()
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div>
<dl class="notes">
<dt>Specified by:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/AutoCloseable.html#close()" title="class or interface in java.lang" class="external-link">close</a></code>&nbsp;in interface&nbsp;<code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/AutoCloseable.html" title="class or interface in java.lang" class="external-link">AutoCloseable</a></code></dd>
<dt>Specified by:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/Closeable.html#close()" title="class or interface in java.io" class="external-link">close</a></code>&nbsp;in interface&nbsp;<code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/Closeable.html" title="class or interface in java.io" class="external-link">Closeable</a></code></dd>
<dt>Throws:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code></dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="isClosed()">
<h3>isClosed</h3>
<div class="member-signature"><span class="return-type">boolean</span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-166">isClosed</a></span>()</div>
<div class="block">Returns whether the connection is closed or not.</div>
<dl class="notes">
<dt>Returns:</dt>
<dd>true if this connection is closed</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="getTableBuilder(org.apache.hadoop.hbase.TableName,java.util.concurrent.ExecutorService)">
<h3>getTableBuilder</h3>
<div class="member-signature"><span class="return-type"><a href="TableBuilder.html" title="interface in org.apache.hadoop.hbase.client">TableBuilder</a></span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-173">getTableBuilder</a></span><wbr><span class="parameters">(<a href="../TableName.html" title="class in org.apache.hadoop.hbase">TableName</a>&nbsp;tableName,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/concurrent/ExecutorService.html" title="class or interface in java.util.concurrent" class="external-link">ExecutorService</a>&nbsp;pool)</span></div>
<div class="block">Returns an <a href="TableBuilder.html" title="interface in org.apache.hadoop.hbase.client"><code>TableBuilder</code></a> for creating <a href="Table.html" title="interface in org.apache.hadoop.hbase.client"><code>Table</code></a>.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>tableName</code> - the name of the table</dd>
<dd><code>pool</code> - the thread pool to use for requests like batch and scan</dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="toAsyncConnection()">
<h3>toAsyncConnection</h3>
<div class="member-signature"><span class="return-type"><a href="AsyncConnection.html" title="interface in org.apache.hadoop.hbase.client">AsyncConnection</a></span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-181">toAsyncConnection</a></span>()</div>
<div class="block">Convert this connection to an <a href="AsyncConnection.html" title="interface in org.apache.hadoop.hbase.client"><code>AsyncConnection</code></a>.
<p/>
Usually we will return the same instance if you call this method multiple times so you can
consider this as a light-weighted operation.</div>
</section>
</li>
<li>
<section class="detail" id="getClusterId()">
<h3>getClusterId</h3>
<div class="member-signature"><span class="modifiers">default</span>&nbsp;<span class="return-type"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class or interface in java.lang" class="external-link">String</a></span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-187">getClusterId</a></span>()</div>
<div class="block">Returns the cluster ID unique to this HBase cluster. <br>
The default implementation is added to keep client compatibility.</div>
</section>
</li>
<li>
<section class="detail" id="getHbck()">
<h3>getHbck</h3>
<div class="member-signature"><span class="annotations">@LimitedPrivate("HBCK")
</span><span class="modifiers">default</span>&nbsp;<span class="return-type"><a href="Hbck.html" title="interface in org.apache.hadoop.hbase.client">Hbck</a></span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-199">getHbck</a></span>()
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div>
<div class="block">Retrieve an Hbck implementation to fix an HBase cluster. The returned Hbck is not guaranteed to
be thread-safe. A new instance should be created by each thread. This is a lightweight
operation. Pooling or caching of the returned Hbck instance is not recommended. <br>
The caller is responsible for calling <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/Closeable.html#close()" title="class or interface in java.io" class="external-link"><code>Closeable.close()</code></a> on the returned Hbck instance. <br>
This will be used mostly by hbck tool.</div>
<dl class="notes">
<dt>Returns:</dt>
<dd>an Hbck instance for active master. Active master is fetched from the zookeeper.</dd>
<dt>Throws:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code></dd>
</dl>
</section>
</li>
<li>
<section class="detail" id="getHbck(org.apache.hadoop.hbase.ServerName)">
<h3>getHbck</h3>
<div class="member-signature"><span class="annotations">@LimitedPrivate("HBCK")
</span><span class="modifiers">default</span>&nbsp;<span class="return-type"><a href="Hbck.html" title="interface in org.apache.hadoop.hbase.client">Hbck</a></span>&nbsp;<span class="element-name"><a href="../../../../../src-html/org/apache/hadoop/hbase/client/Connection.html#line-215">getHbck</a></span><wbr><span class="parameters">(<a href="../ServerName.html" title="class in org.apache.hadoop.hbase">ServerName</a>&nbsp;masterServer)</span>
throws <span class="exceptions"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></span></div>
<div class="block">Retrieve an Hbck implementation to fix an HBase cluster. The returned Hbck is not guaranteed to
be thread-safe. A new instance should be created by each thread. This is a lightweight
operation. Pooling or caching of the returned Hbck instance is not recommended. <br>
The caller is responsible for calling <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/Closeable.html#close()" title="class or interface in java.io" class="external-link"><code>Closeable.close()</code></a> on the returned Hbck instance. <br>
This will be used mostly by hbck tool. This may only be used to by pass getting registered
master from ZK. In situations where ZK is not available or active master is not registered with
ZK and user can get master address by other means, master can be explicitly specified.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>masterServer</code> - explicit <a href="../ServerName.html" title="class in org.apache.hadoop.hbase"><code>ServerName</code></a> for master server</dd>
<dt>Returns:</dt>
<dd>an Hbck instance for a specified master server</dd>
<dt>Throws:</dt>
<dd><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/io/IOException.html" title="class or interface in java.io" class="external-link">IOException</a></code></dd>
</dl>
</section>
</li>
</ul>
</section>
</li>
</ul>
</section>
<!-- ========= END OF CLASS DATA ========= -->
</main>
<footer role="contentinfo">
<hr>
<p class="legal-copy"><small>Copyright &#169; 2007&#x2013;2020 <a href="https://www.apache.org/">The Apache Software Foundation</a>. All rights reserved.</small></p>
</footer>
</div>
</div>
</body>
</html>