class FsCheckpointStreamFactory implements CheckpointStreamFactory {

	@Override
	public FsCheckpointStateOutputStream createCheckpointStateOutputStream(CheckpointedStateScope scope) throws IOException {
		Path target = scope == CheckpointedStateScope.EXCLUSIVE ? checkpointDirectory : sharedStateDirectory;
		int bufferSize = Math.max(writeBufferSize, fileStateThreshold);

		final boolean absolutePath = entropyInjecting || scope == CheckpointedStateScope.SHARED;
		return new FsCheckpointStateOutputStream(target, filesystem, bufferSize, fileStateThreshold, !absolutePath);
	}

	public  FsCheckpointStreamFactory(
			FileSystem fileSystem,
			Path checkpointDirectory,
			Path sharedStateDirectory,
			int fileStateSizeThreshold,
			int writeBufferSize);

}