static Class < ? extends JournalManager > getJournalClass ( Configuration conf , String uriScheme ) { String key = "dfs.name.edits.journal-plugin" + "." + uriScheme ; Class < ? extends JournalManager > clazz = null ; try { clazz = conf . getClass ( key , null , JournalManager . class ) ; } catch ( RuntimeException re ) { throw new IllegalArgumentException ( "Invalid class specified for " + uriScheme , re ) ; } if ( clazz == null ) { LOG . warn ( "No class configured for " + uriScheme + ", " + key + " is empty" ) ; throw new IllegalArgumentException ( "No class configured for " + uriScheme ) ; } return clazz ; }
Retrieve the implementation class for a Journal scheme .