simonbence commented on a change in pull request #4420:
URL: https://github.com/apache/nifi/pull/4420#discussion_r484372894



##########
File path: 
nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/controller/status/history/VolatileComponentStatusRepository.java
##########
@@ -164,6 +183,182 @@ public StatusHistory 
getRemoteProcessGroupStatusHistory(final String remoteGroup
         return getStatusHistory(remoteGroupId, true, DEFAULT_RPG_METRICS, 
start, end, preferredDataPoints);
     }
 
+    @Override
+    public StatusHistory getNodeStatusHistory() {
+        final List<NodeStatus> nodeStatusList = nodeStatuses.asList();
+        final List<List<GarbageCollectionStatus>> gcStatusList = 
gcStatuses.asList();
+        final LinkedList<StatusSnapshot> snapshots = new LinkedList<>();
+
+        final Set<MetricDescriptor<?>> metricDescriptors = new 
HashSet<>(DEFAULT_NODE_METRICS);
+        final List<MetricDescriptor<List<GarbageCollectionStatus>>> 
gcMetricDescriptors = new LinkedList<>();
+        final List<MetricDescriptor<List<GarbageCollectionStatus>>> 
gcMetricDescriptorsDifferential = new LinkedList<>();
+        final List<MetricDescriptor<NodeStatus>> 
contentStorageStatusDescriptors = new LinkedList<>();
+        final List<MetricDescriptor<NodeStatus>> 
provenanceStorageStatusDescriptors = new LinkedList<>();
+
+        int ordinal = DEFAULT_NODE_METRICS.size() - 1;

Review comment:
       Thanks, it's simplified a bit!




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to