David Handermann created NIFI-15076:
---------------------------------------

             Summary: Possible ArithmeticException in Processor Status 
Descriptor Value Reducers
                 Key: NIFI-15076
                 URL: https://issues.apache.org/jira/browse/NIFI-15076
             Project: Apache NiFi
          Issue Type: Bug
          Components: Core Framework
            Reporter: David Handermann
            Assignee: David Handermann


The ProcessorStatusDescriptor enumeration has ValueReducer implementations for 
percentage calculation of several metrics, include CPU usage and Garbage 
Collection. The ValueReducer implementations calculate a percent based on time 
spent in nanoseconds after converting nanoseconds to milliseconds. For 
nanosecond values less than 1000, the TimeUnit.MILLISECOND.convert() method can 
return 0, resulting in an ArithmeticException due to attempted divide by zero.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to