mirror of https://github.com/apache/cassandra
Log JVM Arguments at in-JVM Test Class Initialization
patch by Natnael Adere; reviewed by Caleb Rackliffe, David Capwell for CASSANDRA-16664
This commit is contained in:
parent
8ec04361b9
commit
9a0dd603b1
|
|
@ -250,7 +250,7 @@ public class CassandraDaemon
|
|||
|
||||
ThreadAwareSecurityManager.install();
|
||||
|
||||
logSystemInfo();
|
||||
logSystemInfo(logger);
|
||||
|
||||
NativeLibrary.tryMlockall();
|
||||
|
||||
|
|
@ -626,7 +626,7 @@ public class CassandraDaemon
|
|||
return setupCompleted;
|
||||
}
|
||||
|
||||
private void logSystemInfo()
|
||||
public static void logSystemInfo(Logger logger)
|
||||
{
|
||||
if (logger.isInfoEnabled())
|
||||
{
|
||||
|
|
|
|||
|
|
@ -596,6 +596,7 @@ public class Instance extends IsolatedExecutor implements IInvokableInstance
|
|||
FileUtils.setFSErrorHandler(new DefaultFSErrorHandler());
|
||||
DatabaseDescriptor.createAllDirectories();
|
||||
CassandraDaemon.getInstanceForTesting().migrateSystemDataIfNeeded();
|
||||
CassandraDaemon.logSystemInfo(inInstancelogger);
|
||||
CommitLog.instance.start();
|
||||
|
||||
CassandraDaemon.getInstanceForTesting().runStartupChecks();
|
||||
|
|
|
|||
|
|
@ -94,6 +94,16 @@ public class JVMDTestTest extends TestBaseImpl
|
|||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void jvmArgumentLoggingTest() throws IOException
|
||||
{
|
||||
try (Cluster cluster = Cluster.build(1).start())
|
||||
{
|
||||
LogAction logs = cluster.get(1).logs();
|
||||
Assertions.assertThat(logs.grep("JVM Arguments").getResult()).isNotEmpty();
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void nonSharedConfigClassTest() throws IOException
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue