
co.spraybot.messagerunner.ReportSummary Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of message-runner Show documentation
Show all versions of message-runner Show documentation
A micro-framework to allow easily passing specific Vert.x messages to specific addresses for processing of those messages.
The newest version!
package co.spraybot.messagerunner;
import co.spraybot.messagerunner.builders.ReportSummaryBuilder;
import javax.annotation.Nullable;
import java.time.Duration;
import java.time.LocalDateTime;
/**
* A type that represents a ReportStream has finished processing and includes various data and metrics about the
* ReportStreams operations.
*
* It is not expected that the ReportStream itself will generate this summary but instead the Verticle responsible for
* actually running the ReportStream.
*
* @since 0.1.0
*/
public interface ReportSummary {
/**
* @return The date that the report was generated
*/
LocalDateTime getReportDate();
/**
* @return The number of individual entities that were sent across the ReportStream
*/
int getItemCount();
/**
* @return The number of seconds it took to execute this request
*/
Duration getExecutionTime();
/**
* @return Whether or not the ReportStreamm ended successfully
*/
boolean isSucceeded();
/**
* @return Whether or not the ReportStream ended failed
*/
boolean isFailed();
/**
* @return Only if ifFailed is true returns the reason the ReportStream failed, otherwise null
*/
@Nullable Throwable getCause();
static ReportSummaryBuilder builder() {
return new ReportSummaryBuilder();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy