Java Code Examples for org.apache.flink.util.FileUtils#deleteDirectoryQuietly()

The following examples show how to use org.apache.flink.util.FileUtils#deleteDirectoryQuietly() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: PythonEnvUtils.java    From flink with Apache License 2.0 5 votes vote down vote up
public void run() {

			p.destroyForcibly();

			if (pyFileDir != null) {
				File pyDir = new File(pyFileDir);
				FileUtils.deleteDirectoryQuietly(pyDir);
			}
		}
 
Example 2
Source File: StatefulFunctionsAppContainers.java    From flink-statefun with Apache License 2.0 5 votes vote down vote up
@Override
protected void after() {
  master.stop();
  workers.forEach(GenericContainer::stop);

  FileUtils.deleteDirectoryQuietly(checkpointDir);
}
 
Example 3
Source File: RocksDBCheckpointIterator.java    From bravo with Apache License 2.0 5 votes vote down vote up
@Override
public void close() throws IOException {
	IOUtils.closeQuietly(cancelStreamRegistry);
	IOUtils.closeAllQuietly(stateColumnFamilyHandles);
	IOUtils.closeQuietly(db);
	IOUtils.closeQuietly(dbOptions);
	IOUtils.closeQuietly(colOptions);
	FileUtils.deleteDirectoryQuietly(new File(localPath));
}
 
Example 4
Source File: HiveDialectITCase.java    From flink with Apache License 2.0 5 votes vote down vote up
@After
public void tearDown() {
	if (hiveCatalog != null) {
		hiveCatalog.close();
	}
	if (warehouse != null) {
		FileUtils.deleteDirectoryQuietly(new File(warehouse));
	}
}
 
Example 5
Source File: PythonEnvUtils.java    From flink with Apache License 2.0 5 votes vote down vote up
public void run() {

			p.destroyForcibly();

			if (pyFileDir != null) {
				File pyDir = new File(pyFileDir);
				FileUtils.deleteDirectoryQuietly(pyDir);
			}
		}
 
Example 6
Source File: ProcessPythonEnvironmentManagerTest.java    From flink with Apache License 2.0 5 votes vote down vote up
@AfterClass
public static void cleanTempDirectory() {
	if (tmpDir != null) {
		FileUtils.deleteDirectoryQuietly(new File(tmpDir));
		tmpDir = null;
	}
}
 
Example 7
Source File: RowTsFileConnectorTestBase.java    From incubator-iotdb with Apache License 2.0 4 votes vote down vote up
@After
public void cleanTempDirectory() {
	File tmpDirFile = new File(tmpDir);
	FileUtils.deleteDirectoryQuietly(tmpDirFile);
}
 
Example 8
Source File: PythonEnvUtilsTest.java    From flink with Apache License 2.0 4 votes vote down vote up
@After
public void cleanEnvironment() {
	FileUtils.deleteDirectoryQuietly(new File(tmpDirPath));
}