Return-Path: X-Original-To: apmail-hbase-commits-archive@www.apache.org Delivered-To: apmail-hbase-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 875DF198A7 for ; Fri, 1 Apr 2016 15:16:46 +0000 (UTC) Received: (qmail 44288 invoked by uid 500); 1 Apr 2016 15:16:45 -0000 Delivered-To: apmail-hbase-commits-archive@hbase.apache.org Received: (qmail 44179 invoked by uid 500); 1 Apr 2016 15:16:45 -0000 Mailing-List: contact commits-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@hbase.apache.org Delivered-To: mailing list commits@hbase.apache.org Received: (qmail 43924 invoked by uid 99); 1 Apr 2016 15:16:45 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 01 Apr 2016 15:16:45 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 2299FE0563; Fri, 1 Apr 2016 15:16:45 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: misty@apache.org To: commits@hbase.apache.org Date: Fri, 01 Apr 2016 15:16:47 -0000 Message-Id: In-Reply-To: <98bc15aea5de4805abe6023b9a6c76af@git.apache.org> References: <98bc15aea5de4805abe6023b9a6c76af@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [03/51] [partial] hbase-site git commit: Published site at 25419d8b18dd8f35a102614cd31b274659f747ef. http://git-wip-us.apache.org/repos/asf/hbase-site/blob/ce2de59a/devapidocs/src-html/org/apache/hadoop/hbase/client/Admin.CompactType.html ---------------------------------------------------------------------- diff --git a/devapidocs/src-html/org/apache/hadoop/hbase/client/Admin.CompactType.html b/devapidocs/src-html/org/apache/hadoop/hbase/client/Admin.CompactType.html index 1b9f607..31eac7c 100644 --- a/devapidocs/src-html/org/apache/hadoop/hbase/client/Admin.CompactType.html +++ b/devapidocs/src-html/org/apache/hadoop/hbase/client/Admin.CompactType.html @@ -1338,394 +1338,428 @@ 1330 void restoreSnapshot(final String snapshotName) throws IOException, RestoreSnapshotException; 1331 1332 /** -1333 * Restore the specified snapshot on the original table. (The table must be disabled) If -1334 * 'takeFailSafeSnapshot' is set to true, a snapshot of the current table is taken before -1335 * executing the restore operation. In case of restore failure, the failsafe snapshot will be -1336 * restored. If the restore completes without problem the failsafe snapshot is deleted. The -1337 * failsafe snapshot name is configurable by using the property -1338 * "hbase.snapshot.restore.failsafe.name". -1339 * -1340 * @param snapshotName name of the snapshot to restore -1341 * @param takeFailSafeSnapshot true if the failsafe snapshot should be taken -1342 * @throws IOException if a remote or network exception occurs -1343 * @throws RestoreSnapshotException if snapshot failed to be restored -1344 * @throws IllegalArgumentException if the restore request is formatted incorrectly -1345 */ -1346 void restoreSnapshot(final byte[] snapshotName, final boolean takeFailSafeSnapshot) -1347 throws IOException, RestoreSnapshotException; -1348 -1349 /** -1350 * Restore the specified snapshot on the original table. (The table must be disabled) If -1351 * 'takeFailSafeSnapshot' is set to true, a snapshot of the current table is taken before -1352 * executing the restore operation. In case of restore failure, the failsafe snapshot will be -1353 * restored. If the restore completes without problem the failsafe snapshot is deleted. The -1354 * failsafe snapshot name is configurable by using the property -1355 * "hbase.snapshot.restore.failsafe.name". -1356 * -1357 * @param snapshotName name of the snapshot to restore -1358 * @param takeFailSafeSnapshot true if the failsafe snapshot should be taken -1359 * @throws IOException if a remote or network exception occurs -1360 * @throws RestoreSnapshotException if snapshot failed to be restored -1361 * @throws IllegalArgumentException if the restore request is formatted incorrectly -1362 */ -1363 void restoreSnapshot(final String snapshotName, boolean takeFailSafeSnapshot) -1364 throws IOException, RestoreSnapshotException; -1365 -1366 /** -1367 * Create a new table by cloning the snapshot content. -1368 * -1369 * @param snapshotName name of the snapshot to be cloned -1370 * @param tableName name of the table where the snapshot will be restored -1371 * @throws IOException if a remote or network exception occurs -1372 * @throws TableExistsException if table to be created already exists -1373 * @throws RestoreSnapshotException if snapshot failed to be cloned -1374 * @throws IllegalArgumentException if the specified table has not a valid name -1375 */ -1376 void cloneSnapshot(final byte[] snapshotName, final TableName tableName) -1377 throws IOException, TableExistsException, RestoreSnapshotException; -1378 -1379 /** -1380 * Create a new table by cloning the snapshot content. -1381 * -1382 * @param snapshotName name of the snapshot to be cloned -1383 * @param tableName name of the table where the snapshot will be restored -1384 * @throws IOException if a remote or network exception occurs -1385 * @throws TableExistsException if table to be created already exists -1386 * @throws RestoreSnapshotException if snapshot failed to be cloned -1387 * @throws IllegalArgumentException if the specified table has not a valid name -1388 */ -1389 void cloneSnapshot(final String snapshotName, final TableName tableName) -1390 throws IOException, TableExistsException, RestoreSnapshotException; -1391 -1392 /** -1393 * Execute a distributed procedure on a cluster. -1394 * -1395 * @param signature A distributed procedure is uniquely identified by its signature (default the -1396 * root ZK node name of the procedure). -1397 * @param instance The instance name of the procedure. For some procedures, this parameter is -1398 * optional. -1399 * @param props Property/Value pairs of properties passing to the procedure -1400 * @throws IOException -1401 */ -1402 void execProcedure(String signature, String instance, Map<String, String> props) -1403 throws IOException; -1404 -1405 /** -1406 * Execute a distributed procedure on a cluster. -1407 * -1408 * @param signature A distributed procedure is uniquely identified by its signature (default the -1409 * root ZK node name of the procedure). -1410 * @param instance The instance name of the procedure. For some procedures, this parameter is -1411 * optional. -1412 * @param props Property/Value pairs of properties passing to the procedure -1413 * @return data returned after procedure execution. null if no return data. -1414 * @throws IOException -1415 */ -1416 byte[] execProcedureWithRet(String signature, String instance, Map<String, String> props) -1417 throws IOException; -1418 -1419 /** -1420 * Check the current state of the specified procedure. There are three possible states: <ol> -1421 * <li>running - returns <tt>false</tt></li> <li>finished - returns <tt>true</tt></li> -1422 * <li>finished with error - throws the exception that caused the procedure to fail</li> </ol> -1423 * -1424 * @param signature The signature that uniquely identifies a procedure -1425 * @param instance The instance name of the procedure -1426 * @param props Property/Value pairs of properties passing to the procedure -1427 * @return true if the specified procedure is finished successfully, false if it is still running -1428 * @throws IOException if the specified procedure finished with error -1429 */ -1430 boolean isProcedureFinished(String signature, String instance, Map<String, String> props) -1431 throws IOException; -1432 -1433 /** -1434 * List completed snapshots. -1435 * -1436 * @return a list of snapshot descriptors for completed snapshots -1437 * @throws IOException if a network error occurs -1438 */ -1439 List<HBaseProtos.SnapshotDescription> listSnapshots() throws IOException; -1440 -1441 /** -1442 * List all the completed snapshots matching the given regular expression. -1443 * -1444 * @param regex The regular expression to match against -1445 * @return - returns a List of SnapshotDescription -1446 * @throws IOException if a remote or network exception occurs -1447 */ -1448 List<HBaseProtos.SnapshotDescription> listSnapshots(String regex) throws IOException; -1449 -1450 /** -1451 * List all the completed snapshots matching the given pattern. -1452 * -1453 * @param pattern The compiled regular expression to match against -1454 * @return - returns a List of SnapshotDescription -1455 * @throws IOException if a remote or network exception occurs -1456 */ -1457 List<HBaseProtos.SnapshotDescription> listSnapshots(Pattern pattern) throws IOException; -1458 -1459 /** -1460 * List all the completed snapshots matching the given table name regular expression and snapshot -1461 * name regular expression. -1462 * @param tableNameRegex The table name regular expression to match against -1463 * @param snapshotNameRegex The snapshot name regular expression to match against -1464 * @return - returns a List of completed SnapshotDescription -1465 * @throws IOException if a remote or network exception occurs -1466 */ -1467 List<HBaseProtos.SnapshotDescription> listTableSnapshots(String tableNameRegex, -1468 String snapshotNameRegex) throws IOException; -1469 -1470 /** -1471 * List all the completed snapshots matching the given table name regular expression and snapshot -1472 * name regular expression. -1473 * @param tableNamePattern The compiled table name regular expression to match against -1474 * @param snapshotNamePattern The compiled snapshot name regular expression to match against -1475 * @return - returns a List of completed SnapshotDescription -1476 * @throws IOException if a remote or network exception occurs -1477 */ -1478 List<HBaseProtos.SnapshotDescription> listTableSnapshots(Pattern tableNamePattern, -1479 Pattern snapshotNamePattern) throws IOException; -1480 -1481 /** -1482 * Delete an existing snapshot. -1483 * -1484 * @param snapshotName name of the snapshot -1485 * @throws IOException if a remote or network exception occurs -1486 */ -1487 void deleteSnapshot(final byte[] snapshotName) throws IOException; -1488 -1489 /** -1490 * Delete an existing snapshot. -1491 * -1492 * @param snapshotName name of the snapshot -1493 * @throws IOException if a remote or network exception occurs -1494 */ -1495 void deleteSnapshot(final String snapshotName) throws IOException; -1496 -1497 /** -1498 * Delete existing snapshots whose names match the pattern passed. -1499 * -1500 * @param regex The regular expression to match against -1501 * @throws IOException if a remote or network exception occurs -1502 */ -1503 void deleteSnapshots(final String regex) throws IOException; -1504 -1505 /** -1506 * Delete existing snapshots whose names match the pattern passed. -1507 * -1508 * @param pattern pattern for names of the snapshot to match -1509 * @throws IOException if a remote or network exception occurs -1510 */ -1511 void deleteSnapshots(final Pattern pattern) throws IOException; -1512 -1513 /** -1514 * Delete all existing snapshots matching the given table name regular expression and snapshot -1515 * name regular expression. -1516 * @param tableNameRegex The table name regular expression to match against -1517 * @param snapshotNameRegex The snapshot name regular expression to match against -1518 * @throws IOException if a remote or network exception occurs -1519 */ -1520 void deleteTableSnapshots(String tableNameRegex, String snapshotNameRegex) throws IOException; -1521 -1522 /** -1523 * Delete all existing snapshots matching the given table name regular expression and snapshot -1524 * name regular expression. -1525 * @param tableNamePattern The compiled table name regular expression to match against -1526 * @param snapshotNamePattern The compiled snapshot name regular expression to match against +1333 * Restore the specified snapshot on the original table. (The table must be disabled) If the +1334 * "hbase.snapshot.restore.take.failsafe.snapshot" configuration property is set to true, a +1335 * snapshot of the current table is taken before executing the restore operation. In case of +1336 * restore failure, the failsafe snapshot will be restored. If the restore completes without +1337 * problem the failsafe snapshot is deleted. +1338 * +1339 * @param snapshotName name of the snapshot to restore +1340 * @throws IOException if a remote or network exception occurs +1341 * @throws RestoreSnapshotException if snapshot failed to be restored +1342 * @return the result of the async restore snapshot. You can use Future.get(long, TimeUnit) +1343 * to wait on the operation to complete. +1344 */ +1345 Future<Void> restoreSnapshotAsync(final String snapshotName) +1346 throws IOException, RestoreSnapshotException; +1347 +1348 /** +1349 * Restore the specified snapshot on the original table. (The table must be disabled) If +1350 * 'takeFailSafeSnapshot' is set to true, a snapshot of the current table is taken before +1351 * executing the restore operation. In case of restore failure, the failsafe snapshot will be +1352 * restored. If the restore completes without problem the failsafe snapshot is deleted. The +1353 * failsafe snapshot name is configurable by using the property +1354 * "hbase.snapshot.restore.failsafe.name". +1355 * +1356 * @param snapshotName name of the snapshot to restore +1357 * @param takeFailSafeSnapshot true if the failsafe snapshot should be taken +1358 * @throws IOException if a remote or network exception occurs +1359 * @throws RestoreSnapshotException if snapshot failed to be restored +1360 * @throws IllegalArgumentException if the restore request is formatted incorrectly +1361 */ +1362 void restoreSnapshot(final byte[] snapshotName, final boolean takeFailSafeSnapshot) +1363 throws IOException, RestoreSnapshotException; +1364 +1365 /** +1366 * Restore the specified snapshot on the original table. (The table must be disabled) If +1367 * 'takeFailSafeSnapshot' is set to true, a snapshot of the current table is taken before +1368 * executing the restore operation. In case of restore failure, the failsafe snapshot will be +1369 * restored. If the restore completes without problem the failsafe snapshot is deleted. The +1370 * failsafe snapshot name is configurable by using the property +1371 * "hbase.snapshot.restore.failsafe.name". +1372 * +1373 * @param snapshotName name of the snapshot to restore +1374 * @param takeFailSafeSnapshot true if the failsafe snapshot should be taken +1375 * @throws IOException if a remote or network exception occurs +1376 * @throws RestoreSnapshotException if snapshot failed to be restored +1377 * @throws IllegalArgumentException if the restore request is formatted incorrectly +1378 */ +1379 void restoreSnapshot(final String snapshotName, final boolean takeFailSafeSnapshot) +1380 throws IOException, RestoreSnapshotException; +1381 +1382 /** +1383 * Create a new table by cloning the snapshot content. +1384 * +1385 * @param snapshotName name of the snapshot to be cloned +1386 * @param tableName name of the table where the snapshot will be restored +1387 * @throws IOException if a remote or network exception occurs +1388 * @throws TableExistsException if table to be created already exists +1389 * @throws RestoreSnapshotException if snapshot failed to be cloned +1390 * @throws IllegalArgumentException if the specified table has not a valid name +1391 */ +1392 void cloneSnapshot(final byte[] snapshotName, final TableName tableName) +1393 throws IOException, TableExistsException, RestoreSnapshotException; +1394 +1395 /** +1396 * Create a new table by cloning the snapshot content. +1397 * +1398 * @param snapshotName name of the snapshot to be cloned +1399 * @param tableName name of the table where the snapshot will be restored +1400 * @throws IOException if a remote or network exception occurs +1401 * @throws TableExistsException if table to be created already exists +1402 * @throws RestoreSnapshotException if snapshot failed to be cloned +1403 * @throws IllegalArgumentException if the specified table has not a valid name +1404 */ +1405 void cloneSnapshot(final String snapshotName, final TableName tableName) +1406 throws IOException, TableExistsException, RestoreSnapshotException; +1407 +1408 /** +1409 * Create a new table by cloning the snapshot content, but does not block +1410 * and wait for it be completely cloned. +1411 * You can use Future.get(long, TimeUnit) to wait on the operation to complete. +1412 * It may throw ExecutionException if there was an error while executing the operation +1413 * or TimeoutException in case the wait timeout was not long enough to allow the +1414 * operation to complete. +1415 * +1416 * @param snapshotName name of the snapshot to be cloned +1417 * @param tableName name of the table where the snapshot will be restored +1418 * @throws IOException if a remote or network exception occurs +1419 * @throws TableExistsException if table to be cloned already exists +1420 * @return the result of the async clone snapshot. You can use Future.get(long, TimeUnit) +1421 * to wait on the operation to complete. +1422 */ +1423 Future<Void> cloneSnapshotAsync(final String snapshotName, final TableName tableName) +1424 throws IOException, TableExistsException; +1425 +1426 /** +1427 * Execute a distributed procedure on a cluster. +1428 * +1429 * @param signature A distributed procedure is uniquely identified by its signature (default the +1430 * root ZK node name of the procedure). +1431 * @param instance The instance name of the procedure. For some procedures, this parameter is +1432 * optional. +1433 * @param props Property/Value pairs of properties passing to the procedure +1434 * @throws IOException +1435 */ +1436 void execProcedure(String signature, String instance, Map<String, String> props) +1437 throws IOException; +1438 +1439 /** +1440 * Execute a distributed procedure on a cluster. +1441 * +1442 * @param signature A distributed procedure is uniquely identified by its signature (default the +1443 * root ZK node name of the procedure). +1444 * @param instance The instance name of the procedure. For some procedures, this parameter is +1445 * optional. +1446 * @param props Property/Value pairs of properties passing to the procedure +1447 * @return data returned after procedure execution. null if no return data. +1448 * @throws IOException +1449 */ +1450 byte[] execProcedureWithRet(String signature, String instance, Map<String, String> props) +1451 throws IOException; +1452 +1453 /** +1454 * Check the current state of the specified procedure. There are three possible states: <ol> +1455 * <li>running - returns <tt>false</tt></li> <li>finished - returns <tt>true</tt></li> +1456 * <li>finished with error - throws the exception that caused the procedure to fail</li> </ol> +1457 * +1458 * @param signature The signature that uniquely identifies a procedure +1459 * @param instance The instance name of the procedure +1460 * @param props Property/Value pairs of properties passing to the procedure +1461 * @return true if the specified procedure is finished successfully, false if it is still running +1462 * @throws IOException if the specified procedure finished with error +1463 */ +1464 boolean isProcedureFinished(String signature, String instance, Map<String, String> props) +1465 throws IOException; +1466 +1467 /** +1468 * List completed snapshots. +1469 * +1470 * @return a list of snapshot descriptors for completed snapshots +1471 * @throws IOException if a network error occurs +1472 */ +1473 List<HBaseProtos.SnapshotDescription> listSnapshots() throws IOException; +1474 +1475 /** +1476 * List all the completed snapshots matching the given regular expression. +1477 * +1478 * @param regex The regular expression to match against +1479 * @return - returns a List of SnapshotDescription +1480 * @throws IOException if a remote or network exception occurs +1481 */ +1482 List<HBaseProtos.SnapshotDescription> listSnapshots(String regex) throws IOException; +1483 +1484 /** +1485 * List all the completed snapshots matching the given pattern. +1486 * +1487 * @param pattern The compiled regular expression to match against +1488 * @return - returns a List of SnapshotDescription +1489 * @throws IOException if a remote or network exception occurs +1490 */ +1491 List<HBaseProtos.SnapshotDescription> listSnapshots(Pattern pattern) throws IOException; +1492 +1493 /** +1494 * List all the completed snapshots matching the given table name regular expression and snapshot +1495 * name regular expression. +1496 * @param tableNameRegex The table name regular expression to match against +1497 * @param snapshotNameRegex The snapshot name regular expression to match against +1498 * @return - returns a List of completed SnapshotDescription +1499 * @throws IOException if a remote or network exception occurs +1500 */ +1501 List<HBaseProtos.SnapshotDescription> listTableSnapshots(String tableNameRegex, +1502 String snapshotNameRegex) throws IOException; +1503 +1504 /** +1505 * List all the completed snapshots matching the given table name regular expression and snapshot +1506 * name regular expression. +1507 * @param tableNamePattern The compiled table name regular expression to match against +1508 * @param snapshotNamePattern The compiled snapshot name regular expression to match against +1509 * @return - returns a List of completed SnapshotDescription +1510 * @throws IOException if a remote or network exception occurs +1511 */ +1512 List<HBaseProtos.SnapshotDescription> listTableSnapshots(Pattern tableNamePattern, +1513 Pattern snapshotNamePattern) throws IOException; +1514 +1515 /** +1516 * Delete an existing snapshot. +1517 * +1518 * @param snapshotName name of the snapshot +1519 * @throws IOException if a remote or network exception occurs +1520 */ +1521 void deleteSnapshot(final byte[] snapshotName) throws IOException; +1522 +1523 /** +1524 * Delete an existing snapshot. +1525 * +1526 * @param snapshotName name of the snapshot 1527 * @throws IOException if a remote or network exception occurs 1528 */ -1529 void deleteTableSnapshots(Pattern tableNamePattern, Pattern snapshotNamePattern) -1530 throws IOException; -1531 -1532 /** -1533 * Apply the new quota settings. -1534 * -1535 * @param quota the quota settings -1536 * @throws IOException if a remote or network exception occurs -1537 */ -1538 void setQuota(final QuotaSettings quota) throws IOException; -1539 -1540 /** -1541 * Return a QuotaRetriever to list the quotas based on the filter. -1542 * -1543 * @param filter the quota settings filter -1544 * @return the quota retriever -1545 * @throws IOException if a remote or network exception occurs -1546 */ -1547 QuotaRetriever getQuotaRetriever(final QuotaFilter filter) throws IOException; -1548 -1549 /** -1550 * Creates and returns a {@link com.google.protobuf.RpcChannel} instance connected to the active -1551 * master. <p> The obtained {@link com.google.protobuf.RpcChannel} instance can be used to access -1552 * a published coprocessor {@link com.google.protobuf.Service} using standard protobuf service -1553 * invocations: </p> <div style="background-color: #cccccc; padding: 2px"> -1554 * <blockquote><pre> -1555 * CoprocessorRpcChannel channel = myAdmin.coprocessorService(); -1556 * MyService.BlockingInterface service = MyService.newBlockingStub(channel); -1557 * MyCallRequest request = MyCallRequest.newBuilder() -1558 * ... -1559 * .build(); -1560 * MyCallResponse response = service.myCall(null, request); -1561 * </pre></blockquote></div> -1562 * -1563 * @return A MasterCoprocessorRpcChannel instance -1564 */ -1565 CoprocessorRpcChannel coprocessorService(); -1566 -1567 -1568 /** -1569 * Creates and returns a {@link com.google.protobuf.RpcChannel} instance -1570 * connected to the passed region server. -1571 * -1572 * <p> -1573 * The obtained {@link com.google.protobuf.RpcChannel} instance can be used to access a published -1574 * coprocessor {@link com.google.protobuf.Service} using standard protobuf service invocations: -1575 * </p> +1529 void deleteSnapshot(final String snapshotName) throws IOException; +1530 +1531 /** +1532 * Delete existing snapshots whose names match the pattern passed. +1533 * +1534 * @param regex The regular expression to match against +1535 * @throws IOException if a remote or network exception occurs +1536 */ +1537 void deleteSnapshots(final String regex) throws IOException; +1538 +1539 /** +1540 * Delete existing snapshots whose names match the pattern passed. +1541 * +1542 * @param pattern pattern for names of the snapshot to match +1543 * @throws IOException if a remote or network exception occurs +1544 */ +1545 void deleteSnapshots(final Pattern pattern) throws IOException; +1546 +1547 /** +1548 * Delete all existing snapshots matching the given table name regular expression and snapshot +1549 * name regular expression. +1550 * @param tableNameRegex The table name regular expression to match against +1551 * @param snapshotNameRegex The snapshot name regular expression to match against +1552 * @throws IOException if a remote or network exception occurs +1553 */ +1554 void deleteTableSnapshots(String tableNameRegex, String snapshotNameRegex) throws IOException; +1555 +1556 /** +1557 * Delete all existing snapshots matching the given table name regular expression and snapshot +1558 * name regular expression. +1559 * @param tableNamePattern The compiled table name regular expression to match against +1560 * @param snapshotNamePattern The compiled snapshot name regular expression to match against +1561 * @throws IOException if a remote or network exception occurs +1562 */ +1563 void deleteTableSnapshots(Pattern tableNamePattern, Pattern snapshotNamePattern) +1564 throws IOException; +1565 +1566 /** +1567 * Apply the new quota settings. +1568 * +1569 * @param quota the quota settings +1570 * @throws IOException if a remote or network exception occurs +1571 */ +1572 void setQuota(final QuotaSettings quota) throws IOException; +1573 +1574 /** +1575 * Return a QuotaRetriever to list the quotas based on the filter. 1576 * -1577 * <div style="background-color: #cccccc; padding: 2px"> -1578 * <blockquote><pre> -1579 * CoprocessorRpcChannel channel = myAdmin.coprocessorService(serverName); -1580 * MyService.BlockingInterface service = MyService.newBlockingStub(channel); -1581 * MyCallRequest request = MyCallRequest.newBuilder() -1582 * ... -1583 * .build(); -1584 * MyCallResponse response = service.myCall(null, request); -1585 * </pre></blockquote></div> -1586 * -1587 * @param sn the server name to which the endpoint call is made -1588 * @return A RegionServerCoprocessorRpcChannel instance -1589 */ -1590 CoprocessorRpcChannel coprocessorService(ServerName sn); -1591 -1592 -1593 /** -1594 * Update the configuration and trigger an online config change -1595 * on the regionserver -1596 * @param server : The server whose config needs to be updated. -1597 * @throws IOException +1577 * @param filter the quota settings filter +1578 * @return the quota retriever +1579 * @throws IOException if a remote or network exception occurs +1580 */ +1581 QuotaRetriever getQuotaRetriever(final QuotaFilter filter) throws IOException; +1582 +1583 /** +1584 * Creates and returns a {@link com.google.protobuf.RpcChannel} instance connected to the active +1585 * master. <p> The obtained {@link com.google.protobuf.RpcChannel} instance can be used to access +1586 * a published coprocessor {@link com.google.protobuf.Service} using standard protobuf service +1587 * invocations: </p> <div style="background-color: #cccccc; padding: 2px"> +1588 * <blockquote><pre> +1589 * CoprocessorRpcChannel channel = myAdmin.coprocessorService(); +1590 * MyService.BlockingInterface service = MyService.newBlockingStub(channel); +1591 * MyCallRequest request = MyCallRequest.newBuilder() +1592 * ... +1593 * .build(); +1594 * MyCallResponse response = service.myCall(null, request); +1595 * </pre></blockquote></div> +1596 * +1597 * @return A MasterCoprocessorRpcChannel instance 1598 */ -1599 void updateConfiguration(ServerName server) throws IOException; +1599 CoprocessorRpcChannel coprocessorService(); 1600 1601 1602 /** -1603 * Update the configuration and trigger an online config change -1604 * on all the regionservers -1605 * @throws IOException -1606 */ -1607 void updateConfiguration() throws IOException; -1608 -1609 /** -1610 * Get the info port of the current master if one is available. -1611 * @return master info port -1612 * @throws IOException -1613 */ -1614 public int getMasterInfoPort() throws IOException; -1615 -1616 /** -1617 * Compact a table. Asynchronous operation. -1618 * -1619 * @param tableName table to compact -1620 * @param compactType {@link org.apache.hadoop.hbase.client.Admin.CompactType} -1621 * @throws IOException -1622 * @throws InterruptedException +1603 * Creates and returns a {@link com.google.protobuf.RpcChannel} instance +1604 * connected to the passed region server. +1605 * +1606 * <p> +1607 * The obtained {@link com.google.protobuf.RpcChannel} instance can be used to access a published +1608 * coprocessor {@link com.google.protobuf.Service} using standard protobuf service invocations: +1609 * </p> +1610 * +1611 * <div style="background-color: #cccccc; padding: 2px"> +1612 * <blockquote><pre> +1613 * CoprocessorRpcChannel channel = myAdmin.coprocessorService(serverName); +1614 * MyService.BlockingInterface service = MyService.newBlockingStub(channel); +1615 * MyCallRequest request = MyCallRequest.newBuilder() +1616 * ... +1617 * .build(); +1618 * MyCallResponse response = service.myCall(null, request); +1619 * </pre></blockquote></div> +1620 * +1621 * @param sn the server name to which the endpoint call is made +1622 * @return A RegionServerCoprocessorRpcChannel instance 1623 */ -1624 void compact(final TableName tableName, CompactType compactType) -1625 throws IOException, InterruptedException; +1624 CoprocessorRpcChannel coprocessorService(ServerName sn); +1625 1626 1627 /** -1628 * Compact a column family within a table. Asynchronous operation. -1629 * -1630 * @param tableName table to compact -1631 * @param columnFamily column family within a table -1632 * @param compactType {@link org.apache.hadoop.hbase.client.Admin.CompactType} -1633 * @throws IOException if not a mob column family or if a remote or network exception occurs -1634 * @throws InterruptedException -1635 */ -1636 void compact(final TableName tableName, final byte[] columnFamily, CompactType compactType) -1637 throws IOException, InterruptedException; -1638 -1639 /** -1640 * Major compact a table. Asynchronous operation. -1641 * -1642 * @param tableName table to compact -1643 * @param compactType {@link org.apache.hadoop.hbase.client.Admin.CompactType} -1644 * @throws IOException -1645 * @throws InterruptedException -1646 */ -1647 void majorCompact(final TableName tableName, CompactType compactType) -1648 throws IOException, InterruptedException; +1628 * Update the configuration and trigger an online config change +1629 * on the regionserver +1630 * @param server : The server whose config needs to be updated. +1631 * @throws IOException +1632 */ +1633 void updateConfiguration(ServerName server) throws IOException; +1634 +1635 +1636 /** +1637 * Update the configuration and trigger an online config change +1638 * on all the regionservers +1639 * @throws IOException +1640 */ +1641 void updateConfiguration() throws IOException; +1642 +1643 /** +1644 * Get the info port of the current master if one is available. +1645 * @return master info port +1646 * @throws IOException +1647 */ +1648 public int getMasterInfoPort() throws IOException; 1649 1650 /** -1651 * Major compact a column family within a table. Asynchronous operation. +1651 * Compact a table. Asynchronous operation. 1652 * 1653 * @param tableName table to compact -1654 * @param columnFamily column family within a table -1655 * @param compactType {@link org.apache.hadoop.hbase.client.Admin.CompactType} -1656 * @throws IOException if not a mob column family or if a remote or network exception occurs -1657 * @throws InterruptedException -1658 */ -1659 void majorCompact(final TableName tableName, final byte[] columnFamily, CompactType compactType) -1660 throws IOException, InterruptedException; -1661 -1662 /** -1663 * Get the current compaction state of a table. It could be in a compaction, or none. -1664 * -1665 * @param tableName table to examine +1654 * @param compactType {@link org.apache.hadoop.hbase.client.Admin.CompactType} +1655 * @throws IOException +1656 * @throws InterruptedException +1657 */ +1658 void compact(final TableName tableName, CompactType compactType) +1659 throws IOException, InterruptedException; +1660 +1661 /** +1662 * Compact a column family within a table. Asynchronous operation. +1663 * +1664 * @param tableName table to compact +1665 * @param columnFamily column family within a table 1666 * @param compactType {@link org.apache.hadoop.hbase.client.Admin.CompactType} -1667 * @return the current compaction state -1668 * @throws IOException if a remote or network exception occurs +1667 * @throws IOException if not a mob column family or if a remote or network exception occurs +1668 * @throws InterruptedException 1669 */ -1670 AdminProtos.GetRegionInfoResponse.CompactionState getCompactionState(final TableName tableName, -1671 CompactType compactType) throws IOException; +1670 void compact(final TableName tableName, final byte[] columnFamily, CompactType compactType) +1671 throws IOException, InterruptedException; 1672 1673 /** -1674 * Return the set of supported security capabilities. -1675 * @throws IOException -1676 * @throws UnsupportedOperationException -1677 */ -1678 List<SecurityCapability> getSecurityCapabilities() throws IOException; -1679 -1680 /** -1681 * Turn the Split or Merge switches on or off. -1682 * -1683 * @param enabled enabled or not -1684 * @param synchronous If true, it waits until current split() call, if outstanding, to return. -1685 * @param switchTypes switchType list {@link MasterSwitchType} -1686 * @return Previous switch value array -1687 */ -1688 boolean[] setSplitOrMergeEnabled(final boolean enabled, final boolean synchronous, -1689 final MasterSwitchType... switchTypes) throws IOException; -1690 -1691 /** -1692 * Query the current state of the switch -1693 * -1694 * @return true if the switch is enabled, false otherwise. -1695 */ -1696 boolean isSplitOrMergeEnabled(final MasterSwitchType switchType) throws IOException; -1697 -1698 /** -1699 * Currently, there are only two compact types: -1700 * {@code NORMAL} means do store files compaction; -1701 * {@code MOB} means do mob files compaction. -1702 * */ -1703 @InterfaceAudience.Public -1704 @InterfaceStability.Unstable -1705 public enum CompactType { +1674 * Major compact a table. Asynchronous operation. +1675 * +1676 * @param tableName table to compact +1677 * @param compactType {@link org.apache.hadoop.hbase.client.Admin.CompactType} +1678 * @throws IOException +1679 * @throws InterruptedException +1680 */ +1681 void majorCompact(final TableName tableName, CompactType compactType) +1682 throws IOException, InterruptedException; +1683 +1684 /** +1685 * Major compact a column family within a table. Asynchronous operation. +1686 * +1687 * @param tableName table to compact +1688 * @param columnFamily column family within a table +1689 * @param compactType {@link org.apache.hadoop.hbase.client.Admin.CompactType} +1690 * @throws IOException if not a mob column family or if a remote or network exception occurs +1691 * @throws InterruptedException +1692 */ +1693 void majorCompact(final TableName tableName, final byte[] columnFamily, CompactType compactType) +1694 throws IOException, InterruptedException; +1695 +1696 /** +1697 * Get the current compaction state of a table. It could be in a compaction, or none. +1698 * +1699 * @param tableName table to examine +1700 * @param compactType {@link org.apache.hadoop.hbase.client.Admin.CompactType} +1701 * @return the current compaction state +1702 * @throws IOException if a remote or network exception occurs +1703 */ +1704 AdminProtos.GetRegionInfoResponse.CompactionState getCompactionState(final TableName tableName, +1705 CompactType compactType) throws IOException; 1706 -1707 NORMAL (0), -1708 MOB (1); -1709 -1710 CompactType(int value) {} -1711 } -1712 -1713 @InterfaceAudience.Public -1714 @InterfaceStability.Evolving -1715 public enum MasterSwitchType { -1716 SPLIT, -1717 MERGE -1718 } -1719 -1720} +1707 /** +1708 * Return the set of supported security capabilities. +1709 * @throws IOException +1710 * @throws UnsupportedOperationException +1711 */ +1712 List<SecurityCapability> getSecurityCapabilities() throws IOException; +1713 +1714 /** +1715 * Turn the Split or Merge switches on or off. +1716 * +1717 * @param enabled enabled or not +1718 * @param synchronous If true, it waits until current split() call, if outstanding, to return. +1719 * @param switchTypes switchType list {@link MasterSwitchType} +1720 * @return Previous switch value array +1721 */ +1722 boolean[] setSplitOrMergeEnabled(final boolean enabled, final boolean synchronous, +1723 final MasterSwitchType... switchTypes) throws IOException; +1724 +1725 /** +1726 * Query the current state of the switch +1727 * +1728 * @return true if the switch is enabled, false otherwise. +1729 */ +1730 boolean isSplitOrMergeEnabled(final MasterSwitchType switchType) throws IOException; +1731 +1732 /** +1733 * Currently, there are only two compact types: +1734 * {@code NORMAL} means do store files compaction; +1735 * {@code MOB} means do mob files compaction. +1736 * */ +1737 @InterfaceAudience.Public +1738 @InterfaceStability.Unstable +1739 public enum CompactType { +1740 +1741 NORMAL (0), +1742 MOB (1); +1743 +1744 CompactType(int value) {} +1745 } +1746 +1747 @InterfaceAudience.Public +1748 @InterfaceStability.Evolving +1749 public enum MasterSwitchType { +1750 SPLIT, +1751 MERGE +1752 } +1753 +1754}