use of org.junit.After in project flink by apache.
the class TaskTestBase method shutdownMemoryManager.
@After
public void shutdownMemoryManager() throws Exception {
if (this.memorySize > 0) {
MemoryManager memMan = getMemoryManager();
if (memMan != null) {
Assert.assertTrue("Memory Manager managed memory was not completely freed.", memMan.verifyEmpty());
memMan.shutdown();
}
}
}
use of org.junit.After in project hadoop by apache.
the class TestDistributedShell method tearDown.
@After
public void tearDown() throws IOException {
if (yarnCluster != null) {
try {
yarnCluster.stop();
} finally {
yarnCluster = null;
}
}
if (hdfsCluster != null) {
try {
hdfsCluster.shutdown();
} finally {
hdfsCluster = null;
}
}
FileContext fsContext = FileContext.getLocalFSFileContext();
fsContext.delete(new Path(conf.get(YarnConfiguration.TIMELINE_SERVICE_LEVELDB_PATH)), true);
}
use of org.junit.After in project hadoop by apache.
the class TestNodeStatusUpdater method deleteBaseDir.
@After
public void deleteBaseDir() throws IOException {
FileContext lfs = FileContext.getLocalFSFileContext();
lfs.delete(new Path(basedir.getPath()), true);
}
use of org.junit.After in project hadoop by apache.
the class TestResourceTrackerService method tearDown.
@After
public void tearDown() {
if (hostFile != null && hostFile.exists()) {
hostFile.delete();
}
ClusterMetrics.destroy();
if (rm != null) {
rm.stop();
}
MetricsSystem ms = DefaultMetricsSystem.instance();
if (ms.getSource("ClusterMetrics") != null) {
DefaultMetricsSystem.shutdown();
}
}
use of org.junit.After in project hadoop by apache.
the class TestNameNodeMetrics method tearDown.
@After
public void tearDown() throws Exception {
MetricsSource source = DefaultMetricsSystem.instance().getSource("UgiMetrics");
if (source != null) {
// Run only once since the UGI metrics is cleaned up during teardown
MetricsRecordBuilder rb = getMetrics(source);
assertQuantileGauges("GetGroups1s", rb);
}
if (cluster != null) {
cluster.shutdown();
cluster = null;
}
}
Aggregations