Java Code Examples for org.apache.nifi.controller.status.ProcessGroupStatus#getProcessorStatus()

The following examples show how to use org.apache.nifi.controller.status.ProcessGroupStatus#getProcessorStatus() . 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: StandardGangliaReporter.java    From localization_nifi with Apache License 2.0 5 votes vote down vote up
private long calculateProcessingNanos(final ProcessGroupStatus status) {
    long nanos = 0L;

    for (final ProcessorStatus procStats : status.getProcessorStatus()) {
        nanos += procStats.getProcessingNanos();
    }

    for (final ProcessGroupStatus childGroupStatus : status.getProcessGroupStatus()) {
        nanos += calculateProcessingNanos(childGroupStatus);
    }

    return nanos;
}
 
Example 2
Source File: MetricsService.java    From localization_nifi with Apache License 2.0 5 votes vote down vote up
protected long calculateProcessingNanos(final ProcessGroupStatus status) {
    long nanos = 0L;

    for (final ProcessorStatus procStats : status.getProcessorStatus()) {
        nanos += procStats.getProcessingNanos();
    }

    for (final ProcessGroupStatus childGroupStatus : status.getProcessGroupStatus()) {
        nanos += calculateProcessingNanos(childGroupStatus);
    }

    return nanos;
}
 
Example 3
Source File: MetricsService.java    From localization_nifi with Apache License 2.0 5 votes vote down vote up
protected long calculateProcessingNanos(final ProcessGroupStatus status) {
    long nanos = 0L;

    for (final ProcessorStatus procStats : status.getProcessorStatus()) {
        nanos += procStats.getProcessingNanos();
    }

    for (final ProcessGroupStatus childGroupStatus : status.getProcessGroupStatus()) {
        nanos += calculateProcessingNanos(childGroupStatus);
    }

    return nanos;
}
 
Example 4
Source File: MetricsService.java    From nifi-prometheus-reporter with Apache License 2.0 5 votes vote down vote up
protected long calculateProcessingNanos(final ProcessGroupStatus status) {
    long nanos = 0L;

    for (final ProcessorStatus procStats : status.getProcessorStatus()) {
        nanos += procStats.getProcessingNanos();
    }

    for (final ProcessGroupStatus childGroupStatus : status.getProcessGroupStatus()) {
        nanos += calculateProcessingNanos(childGroupStatus);
    }

    return nanos;
}
 
Example 5
Source File: AzureLogAnalyticsMetricsFactory.java    From nifi with Apache License 2.0 5 votes vote down vote up
static long calculateProcessingNanos(final ProcessGroupStatus status) {
    long nanos = 0L;

    for (final ProcessorStatus procStats : status.getProcessorStatus()) {
        nanos += procStats.getProcessingNanos();
    }

    for (final ProcessGroupStatus childGroupStatus : status.getProcessGroupStatus()) {
        nanos += calculateProcessingNanos(childGroupStatus);
    }

    return nanos;
}
 
Example 6
Source File: MetricsService.java    From nifi with Apache License 2.0 5 votes vote down vote up
protected long calculateProcessingNanos(final ProcessGroupStatus status) {
    long nanos = 0L;

    for (final ProcessorStatus procStats : status.getProcessorStatus()) {
        nanos += procStats.getProcessingNanos();
    }

    for (final ProcessGroupStatus childGroupStatus : status.getProcessGroupStatus()) {
        nanos += calculateProcessingNanos(childGroupStatus);
    }

    return nanos;
}
 
Example 7
Source File: StandardGangliaReporter.java    From nifi with Apache License 2.0 5 votes vote down vote up
private long calculateProcessingNanos(final ProcessGroupStatus status) {
    long nanos = 0L;

    for (final ProcessorStatus procStats : status.getProcessorStatus()) {
        nanos += procStats.getProcessingNanos();
    }

    for (final ProcessGroupStatus childGroupStatus : status.getProcessGroupStatus()) {
        nanos += calculateProcessingNanos(childGroupStatus);
    }

    return nanos;
}
 
Example 8
Source File: FlowMetricSet.java    From nifi with Apache License 2.0 5 votes vote down vote up
/**
 * Calculate the total processing time of a process group.
 *
 * @param status the current process group status.
 * @return the total amount of nanoseconds spent in each processor in the process group.
 */
private long calculateProcessingNanos(final ProcessGroupStatus status) {
    long nanos = 0L;

    for (final ProcessorStatus procStats : status.getProcessorStatus()) {
        nanos += procStats.getProcessingNanos();
    }

    for (final ProcessGroupStatus childGroupStatus : status.getProcessGroupStatus()) {
        nanos += calculateProcessingNanos(childGroupStatus);
    }

    return nanos;
}
 
Example 9
Source File: MetricsService.java    From nifi with Apache License 2.0 5 votes vote down vote up
protected long calculateProcessingNanos(final ProcessGroupStatus status) {
    long nanos = 0L;

    for (final ProcessorStatus procStats : status.getProcessorStatus()) {
        nanos += procStats.getProcessingNanos();
    }

    for (final ProcessGroupStatus childGroupStatus : status.getProcessGroupStatus()) {
        nanos += calculateProcessingNanos(childGroupStatus);
    }

    return nanos;
}