mirror of https://github.com/apache/cassandra
r/m unused RecoveryManager instance (class is entirely static). patch by jbellis
git-svn-id: https://svn.apache.org/repos/asf/incubator/cassandra/trunk@889705 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
b4cf34e1f8
commit
5bcdbcfa27
|
|
@ -28,18 +28,8 @@ import org.apache.commons.lang.StringUtils;
|
|||
|
||||
public class RecoveryManager
|
||||
{
|
||||
private static RecoveryManager instance_;
|
||||
private static Logger logger_ = Logger.getLogger(RecoveryManager.class);
|
||||
|
||||
public synchronized static RecoveryManager instance() throws IOException
|
||||
{
|
||||
if (instance_ == null)
|
||||
{
|
||||
instance_ = new RecoveryManager();
|
||||
}
|
||||
return instance_;
|
||||
}
|
||||
|
||||
public static File[] getListofCommitLogs()
|
||||
{
|
||||
String directory = DatabaseDescriptor.getLogFileLocation();
|
||||
|
|
|
|||
|
|
@ -91,7 +91,6 @@ public class CassandraDaemon
|
|||
}
|
||||
|
||||
// replay the log if necessary
|
||||
RecoveryManager recoveryMgr = RecoveryManager.instance();
|
||||
RecoveryManager.doRecovery();
|
||||
|
||||
// now we start listening for clients
|
||||
|
|
|
|||
|
|
@ -35,8 +35,7 @@ public class RecoveryManagerTest extends CleanupHelper
|
|||
@Test
|
||||
public void testNothing() throws IOException {
|
||||
// TODO nothing to recover
|
||||
RecoveryManager rm = RecoveryManager.instance();
|
||||
rm.doRecovery();
|
||||
RecoveryManager.doRecovery();
|
||||
}
|
||||
|
||||
@Test
|
||||
|
|
|
|||
Loading…
Reference in New Issue