org.apache.accumulo.start.classloader.vfs
Class AccumuloVFSClassLoader

java.lang.Object
  extended by org.apache.accumulo.start.classloader.vfs.AccumuloVFSClassLoader

public class AccumuloVFSClassLoader
extends Object

This class builds a hierarchy of Classloaders in the form of:

 SystemClassLoader that loads JVM classes
       ^
       |
 AccumuloClassLoader loads jars from locations in general.classpaths. Usually the URLs for HADOOP_HOME, ZOOKEEPER_HOME, ACCUMULO_HOME and their associated directories
       ^
       |
 VFSClassLoader that loads jars from locations in general.vfs.classpaths.  Can be used to load accumulo jar from HDFS
       ^
       |
 AccumuloReloadingVFSClassLoader That loads jars from locations in general.dynamic.classpaths.  Used to load jar dynamically.
 
 


Nested Class Summary
static class AccumuloVFSClassLoader.AccumuloVFSClassLoaderShutdownThread
           
static interface AccumuloVFSClassLoader.Printer
           
 
Field Summary
static String DEFAULT_DYNAMIC_CLASSPATH_VALUE
           
static String DYNAMIC_CLASSPATH_PROPERTY_NAME
           
static String VFS_CACHE_DIR
           
static String VFS_CLASSLOADER_SYSTEM_CLASSPATH_PROPERTY
           
static String VFS_CONTEXT_CLASSPATH_PROPERTY
           
 
Constructor Summary
AccumuloVFSClassLoader()
           
 
Method Summary
static void close()
           
static org.apache.commons.vfs2.FileSystemManager generateVfs()
           
static ClassLoader getClassLoader()
           
static ContextManager getContextManager()
           
static Class<?> loadClass(String classname)
           
static
<U> Class<? extends U>
loadClass(String classname, Class<U> extension)
           
static void printClassPath()
           
static void printClassPath(AccumuloVFSClassLoader.Printer out)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DYNAMIC_CLASSPATH_PROPERTY_NAME

public static final String DYNAMIC_CLASSPATH_PROPERTY_NAME
See Also:
Constant Field Values

DEFAULT_DYNAMIC_CLASSPATH_VALUE

public static final String DEFAULT_DYNAMIC_CLASSPATH_VALUE
See Also:
Constant Field Values

VFS_CLASSLOADER_SYSTEM_CLASSPATH_PROPERTY

public static final String VFS_CLASSLOADER_SYSTEM_CLASSPATH_PROPERTY
See Also:
Constant Field Values

VFS_CONTEXT_CLASSPATH_PROPERTY

public static final String VFS_CONTEXT_CLASSPATH_PROPERTY
See Also:
Constant Field Values

VFS_CACHE_DIR

public static final String VFS_CACHE_DIR
See Also:
Constant Field Values
Constructor Detail

AccumuloVFSClassLoader

public AccumuloVFSClassLoader()
Method Detail

loadClass

public static <U> Class<? extends U> loadClass(String classname,
                                               Class<U> extension)
                                    throws ClassNotFoundException
Throws:
ClassNotFoundException

loadClass

public static Class<?> loadClass(String classname)
                          throws ClassNotFoundException
Throws:
ClassNotFoundException

getClassLoader

public static ClassLoader getClassLoader()
                                  throws IOException
Throws:
IOException

generateVfs

public static org.apache.commons.vfs2.FileSystemManager generateVfs()
                                                             throws org.apache.commons.vfs2.FileSystemException
Throws:
org.apache.commons.vfs2.FileSystemException

printClassPath

public static void printClassPath()

printClassPath

public static void printClassPath(AccumuloVFSClassLoader.Printer out)

getContextManager

public static ContextManager getContextManager()
                                        throws IOException
Throws:
IOException

close

public static void close()


Copyright © 2013 Apache Accumulo Project. All Rights Reserved.