org.apache.hadoop.hive.metastore
Class DummyJdoConnectionUrlHook

java.lang.Object
  extended by org.apache.hadoop.hive.metastore.DummyJdoConnectionUrlHook
All Implemented Interfaces:
JDOConnectionURLHook

public class DummyJdoConnectionUrlHook
extends Object
implements JDOConnectionURLHook

DummyJdoConnectionUrlHook. An implementation of JDOConnectionURLHook which simply returns CORRECT_URL when getJdoConnectionUrl is called.


Field Summary
static String initialUrl
           
static String newUrl
           
 
Constructor Summary
DummyJdoConnectionUrlHook()
           
 
Method Summary
 String getJdoConnectionUrl(org.apache.hadoop.conf.Configuration conf)
          Gets the connection URL to supply to JDO.
 void notifyBadConnectionUrl(String url)
          Alerts this that the connection URL was bad.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

initialUrl

public static final String initialUrl
See Also:
Constant Field Values

newUrl

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

DummyJdoConnectionUrlHook

public DummyJdoConnectionUrlHook()
Method Detail

getJdoConnectionUrl

public String getJdoConnectionUrl(org.apache.hadoop.conf.Configuration conf)
                           throws Exception
Description copied from interface: JDOConnectionURLHook
Gets the connection URL to supply to JDO. In addition to initialization, this method will be called after a connection failure for each reconnect attempt.

Specified by:
getJdoConnectionUrl in interface JDOConnectionURLHook
Parameters:
conf - The configuration used to initialize this instance of the HMS
Returns:
the connection URL
Throws:
Exception

notifyBadConnectionUrl

public void notifyBadConnectionUrl(String url)
Description copied from interface: JDOConnectionURLHook
Alerts this that the connection URL was bad. Can be used to collect stats, etc.

Specified by:
notifyBadConnectionUrl in interface JDOConnectionURLHook


Copyright © 2013 The Apache Software Foundation