bipinprasad commented on a change in pull request #3421:
URL: https://github.com/apache/storm/pull/3421#discussion_r741482321



##########
File path: storm-server/src/main/java/org/apache/storm/daemon/nimbus/Nimbus.java
##########
@@ -985,6 +985,37 @@ private static boolean 
isTopologyActiveOrActivating(IStormClusterState state, St
         return isTopologyActive(state, topoName) || 
state.activeStorms().contains(topoName);
     }
 
+    /**
+     * Returns the topologyId of the topology using this blob.
+     * @param state the cluster state
+     * @param topoCache the topology cache
+     * @param key the blob key
+     * @return null or id
+     */
+    private static String topologyUsingThisBlob(IStormClusterState state, 
TopoCache topoCache, String key) {
+        for (String topologyId : state.activeStorms()) {
+            Map<String, Object> topoConf = null;
+            try {
+                topoConf = readTopoConfAsNimbus(topologyId, topoCache);
+            } catch (KeyNotFoundException e) {
+                continue;
+            } catch (AuthorizationException e) {
+                continue;
+            } catch (IOException e) {
+                continue;
+            }

Review comment:
       I think it will be more compact to catch all on same line:
    catch (KeyNotFoundException | AuthorizationException | IOException e) {
          continue;
    }




-- 
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: dev-unsubscr...@storm.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to