pvargacl commented on a change in pull request #1087:
URL: https://github.com/apache/hive/pull/1087#discussion_r450334396
##########
File path:
standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/HiveMetaStoreChecker.java
##########
@@ -111,24 +120,24 @@ public IMetaStoreClient getMsc() {
* @param partitions
* List of partition name value pairs, if null or empty check all
* partitions
- * @param table
- * @param result
- * Fill this with the results of the check
+ * @param table Table we want to run the check for.
+ * @return Results of the check
* @throws MetastoreException
* Failed to get required information from the metastore.
* @throws IOException
* Most likely filesystem related
*/
- public void checkMetastore(String catName, String dbName, String tableName,
- List<? extends Map<String, String>> partitions, Table table, CheckResult
result)
+ public CheckResult checkMetastore(String catName, String dbName, String
tableName,
+ List<? extends Map<String, String>> partitions, Table table)
throws MetastoreException, IOException {
-
+ CheckResult result = new CheckResult();
if (dbName == null || "".equalsIgnoreCase(dbName)) {
dbName = Warehouse.DEFAULT_DATABASE_NAME;
}
try {
if (tableName == null || "".equals(tableName)) {
+ // TODO: I do not think this is used by anything other than tests
Review comment:
I do not know. If I understand correctly there is no way currently to
call MSCK repair without a table specified, but it seems like someone made some
effort to create that feature and tests for it. But i don't know if we ever
want that in production (calling msck repair for every table seems like a quick
way to overwhelm the system) I left this comment here, for anybody who tries
to makes sense of this code.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]