org.apache.flink.runtime.webmonitor.history.JsonArchivist Java Examples

The following examples show how to use org.apache.flink.runtime.webmonitor.history.JsonArchivist. 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: HistoryServerArchivist.java    From Flink-CEPplus with Apache License 2.0 5 votes vote down vote up
static HistoryServerArchivist createHistoryServerArchivist(Configuration configuration, JsonArchivist jsonArchivist) {
	final String configuredArchivePath = configuration.getString(JobManagerOptions.ARCHIVE_DIR);

	if (configuredArchivePath != null) {
		final Path archivePath = WebMonitorUtils.validateAndNormalizeUri(new Path(configuredArchivePath).toUri());

		return new JsonResponseHistoryServerArchivist(jsonArchivist, archivePath);
	} else {
		return VoidHistoryServerArchivist.INSTANCE;
	}
}
 
Example #2
Source File: WebMonitorEndpoint.java    From Flink-CEPplus with Apache License 2.0 5 votes vote down vote up
@Override
public Collection<ArchivedJson> archiveJsonWithPath(AccessExecutionGraph graph) throws IOException {
	Collection<ArchivedJson> archivedJson = new ArrayList<>(archivingHandlers.size());
	for (JsonArchivist archivist : archivingHandlers) {
		Collection<ArchivedJson> subArchive = archivist.archiveJsonWithPath(graph);
		archivedJson.addAll(subArchive);
	}
	return archivedJson;
}
 
Example #3
Source File: HistoryServerArchivist.java    From flink with Apache License 2.0 5 votes vote down vote up
static HistoryServerArchivist createHistoryServerArchivist(Configuration configuration, JsonArchivist jsonArchivist) {
	final String configuredArchivePath = configuration.getString(JobManagerOptions.ARCHIVE_DIR);

	if (configuredArchivePath != null) {
		final Path archivePath = WebMonitorUtils.validateAndNormalizeUri(new Path(configuredArchivePath).toUri());

		return new JsonResponseHistoryServerArchivist(jsonArchivist, archivePath);
	} else {
		return VoidHistoryServerArchivist.INSTANCE;
	}
}
 
Example #4
Source File: WebMonitorEndpoint.java    From flink with Apache License 2.0 5 votes vote down vote up
@Override
public Collection<ArchivedJson> archiveJsonWithPath(AccessExecutionGraph graph) throws IOException {
	Collection<ArchivedJson> archivedJson = new ArrayList<>(archivingHandlers.size());
	for (JsonArchivist archivist : archivingHandlers) {
		Collection<ArchivedJson> subArchive = archivist.archiveJsonWithPath(graph);
		archivedJson.addAll(subArchive);
	}
	return archivedJson;
}
 
Example #5
Source File: HistoryServerArchivist.java    From flink with Apache License 2.0 5 votes vote down vote up
static HistoryServerArchivist createHistoryServerArchivist(Configuration configuration, JsonArchivist jsonArchivist, Executor ioExecutor) {
	final String configuredArchivePath = configuration.getString(JobManagerOptions.ARCHIVE_DIR);

	if (configuredArchivePath != null) {
		final Path archivePath = WebMonitorUtils.validateAndNormalizeUri(new Path(configuredArchivePath).toUri());

		return new JsonResponseHistoryServerArchivist(jsonArchivist, archivePath, ioExecutor);
	} else {
		return VoidHistoryServerArchivist.INSTANCE;
	}
}
 
Example #6
Source File: WebMonitorEndpoint.java    From flink with Apache License 2.0 5 votes vote down vote up
@Override
public Collection<ArchivedJson> archiveJsonWithPath(AccessExecutionGraph graph) throws IOException {
	Collection<ArchivedJson> archivedJson = new ArrayList<>(archivingHandlers.size());
	for (JsonArchivist archivist : archivingHandlers) {
		Collection<ArchivedJson> subArchive = archivist.archiveJsonWithPath(graph);
		archivedJson.addAll(subArchive);
	}
	return archivedJson;
}
 
Example #7
Source File: JsonResponseHistoryServerArchivist.java    From Flink-CEPplus with Apache License 2.0 4 votes vote down vote up
JsonResponseHistoryServerArchivist(JsonArchivist jsonArchivist, Path archivePath) {
	this.jsonArchivist = Preconditions.checkNotNull(jsonArchivist);
	this.archivePath = Preconditions.checkNotNull(archivePath);
}
 
Example #8
Source File: JsonResponseHistoryServerArchivist.java    From flink with Apache License 2.0 4 votes vote down vote up
JsonResponseHistoryServerArchivist(JsonArchivist jsonArchivist, Path archivePath) {
	this.jsonArchivist = Preconditions.checkNotNull(jsonArchivist);
	this.archivePath = Preconditions.checkNotNull(archivePath);
}
 
Example #9
Source File: JsonResponseHistoryServerArchivist.java    From flink with Apache License 2.0 4 votes vote down vote up
JsonResponseHistoryServerArchivist(JsonArchivist jsonArchivist, Path archivePath, Executor ioExecutor) {
	this.jsonArchivist = Preconditions.checkNotNull(jsonArchivist);
	this.archivePath = Preconditions.checkNotNull(archivePath);
	this.ioExecutor = Preconditions.checkNotNull(ioExecutor);
}