Class CoprocessorValidator
java.lang.Object
org.apache.hadoop.hbase.util.AbstractHBaseTool
org.apache.hadoop.hbase.tool.coprocessor.CoprocessorValidator
- All Implemented Interfaces:
org.apache.hadoop.conf.Configurable
,org.apache.hadoop.util.Tool
-
Nested Class Summary
Modifier and TypeClassDescriptionprivate static final class
This classloader implementation callsClassLoader.resolveClass(Class)
method for every loaded class.Nested classes/interfaces inherited from class org.apache.hadoop.hbase.util.AbstractHBaseTool
AbstractHBaseTool.OptionsOrderComparator
-
Field Summary
Modifier and TypeFieldDescriptionprivate CoprocessorMethods
private boolean
private CoprocessorMethods
private boolean
private static final org.slf4j.Logger
Fields inherited from class org.apache.hadoop.hbase.util.AbstractHBaseTool
cmdLineArgs, conf, EXIT_FAILURE, EXIT_SUCCESS, LONG_HELP_OPTION, options, SHORT_HELP_OPTION
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
Override this to add command-line options usingAbstractHBaseTool.addOptWithArg(java.lang.String, java.lang.String)
and similar methods.buildClasspath
(List<String> jars) createClassLoader
(ClassLoader parent, org.apache.hadoop.fs.Path path) createClassLoader
(URL[] urls) createClassLoader
(URL[] urls, ClassLoader parent) protected int
doWork()
The "main function" of the toolprotected void
protected void
processOptions
(org.apache.hbase.thirdparty.org.apache.commons.cli.CommandLine cmd) This method is called to process the options after they have been parsed.private void
validate
(ClassLoader classLoader, String className, List<CoprocessorViolation> violations) void
validateClasses
(ClassLoader classLoader, String[] classNames, List<CoprocessorViolation> violations) void
validateClasses
(ClassLoader classLoader, List<String> classNames, List<CoprocessorViolation> violations) private void
validateTables
(ClassLoader classLoader, Pattern pattern, List<CoprocessorViolation> violations) protected void
validateTables
(ClassLoader classLoader, Admin admin, Pattern pattern, List<CoprocessorViolation> violations) Methods inherited from class org.apache.hadoop.hbase.util.AbstractHBaseTool
addOption, addOptNoArg, addOptNoArg, addOptWithArg, addOptWithArg, addRequiredOption, addRequiredOptWithArg, addRequiredOptWithArg, doStaticMain, getConf, getOptionAsDouble, getOptionAsInt, getOptionAsInt, getOptionAsLong, getOptionAsLong, newParser, parseArgs, parseInt, parseLong, printUsage, processOldArgs, run, setConf
-
Field Details
-
LOG
-
branch1
-
current
-
jars
-
tablePatterns
-
classes
-
config
-
dieOnWarnings
-
-
Constructor Details
-
CoprocessorValidator
public CoprocessorValidator()
-
-
Method Details
-
createClassLoader
-
createClassLoader
private CoprocessorValidator.ResolverUrlClassLoader createClassLoader(URL[] urls, ClassLoader parent) -
createClassLoader
private CoprocessorValidator.ResolverUrlClassLoader createClassLoader(ClassLoader parent, org.apache.hadoop.fs.Path path) throws IOException - Throws:
IOException
-
validate
private void validate(ClassLoader classLoader, String className, List<CoprocessorViolation> violations) -
validateClasses
public void validateClasses(ClassLoader classLoader, List<String> classNames, List<CoprocessorViolation> violations) -
validateClasses
public void validateClasses(ClassLoader classLoader, String[] classNames, List<CoprocessorViolation> violations) -
validateTables
@Private protected void validateTables(ClassLoader classLoader, Admin admin, Pattern pattern, List<CoprocessorViolation> violations) throws IOException - Throws:
IOException
-
validateTables
private void validateTables(ClassLoader classLoader, Pattern pattern, List<CoprocessorViolation> violations) throws IOException - Throws:
IOException
-
printUsage
- Overrides:
printUsage
in classAbstractHBaseTool
-
addOptions
Description copied from class:AbstractHBaseTool
Override this to add command-line options usingAbstractHBaseTool.addOptWithArg(java.lang.String, java.lang.String)
and similar methods.- Specified by:
addOptions
in classAbstractHBaseTool
-
processOptions
Description copied from class:AbstractHBaseTool
This method is called to process the options after they have been parsed.- Specified by:
processOptions
in classAbstractHBaseTool
-
buildClasspath
- Throws:
IOException
-
doWork
Description copied from class:AbstractHBaseTool
The "main function" of the tool- Specified by:
doWork
in classAbstractHBaseTool
- Throws:
Exception
-