markap14 commented on code in PR #8158:
URL: https://github.com/apache/nifi/pull/8158#discussion_r1426760635


##########
nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/StandardNiFiServiceFacade.java:
##########
@@ -6233,27 +6237,54 @@ protected Collection<AbstractMetricsRegistry> 
populateFlowMetrics() {
 
         // Get Connection Status Analytics (predictions, e.g.)
         Set<Connection> connections = 
controllerFacade.getFlowManager().findAllConnections();
-        for (Connection c : connections) {
-            // If a ResourceNotFoundException is thrown, analytics hasn't been 
enabled
+        Collection<Map<String, Long>> predictions = new 
ConcurrentLinkedDeque<>();

Review Comment:
   Why the use of ConcurrentLinkedDeque? Seems like a heavy implementation for 
this. Would recommend using `Collections.synchronizedList( new ArrayList<> )`



-- 
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.

To unsubscribe, e-mail: [email protected]

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

Reply via email to