/** * Returns the status for components in the specified group. This request is * made by the specified user so the results will be filtered accordingly. * * @param groupId group id * @param user user making request * @return the component status */ public ProcessGroupStatus getGroupStatus(final String groupId, final NiFiUser user) { final RepositoryStatusReport repoStatusReport = generateRepositoryStatusReport(); return getGroupStatus(groupId, repoStatusReport, user); }
/** * Returns the status of all components in the specified group. This request * is not in the context of a user so the results will be unfiltered. * * @param groupId group id * @return the component status */ @Override public ProcessGroupStatus getGroupStatus(final String groupId) { final RepositoryStatusReport repoStatusReport = generateRepositoryStatusReport(); return getGroupStatus(groupId, repoStatusReport); }
/** * Returns the status for components in the specified group. This request is * made by the specified user so the results will be filtered accordingly. * * @param groupId group id * @param user user making request * @return the component status */ public ProcessGroupStatus getGroupStatus(final String groupId, final NiFiUser user, final int recursiveStatusDepth) { final RepositoryStatusReport repoStatusReport = generateRepositoryStatusReport(); return getGroupStatus(groupId, repoStatusReport, user, recursiveStatusDepth); }
/** * Returns the status of all components in the controller. This request is * not in the context of a user so the results will be unfiltered. * * @return the component status */ @Override public ProcessGroupStatus getControllerStatus() { return getGroupStatus(flowController.getFlowManager().getRootGroupId()); }
/** * Returns the status for the components in the specified group with the * specified report. This request is not in the context of a user so the * results will be unfiltered. * * @param groupId group id * @param statusReport report * @return the component status */ public ProcessGroupStatus getGroupStatus(final String groupId, final RepositoryStatusReport statusReport) { final ProcessGroup group = flowController.getFlowManager().getGroup(groupId); // this was invoked with no user context so the results will be unfiltered... necessary for aggregating status history return getGroupStatus(group, statusReport, authorizable -> true, Integer.MAX_VALUE, 1); }
/** * Returns the status for the components in the specified group with the * specified report. This request is made by the specified user so the * results will be filtered accordingly. * * @param groupId group id * @param statusReport report * @param user user making request * @return the component status */ public ProcessGroupStatus getGroupStatus(final String groupId, final RepositoryStatusReport statusReport, final NiFiUser user) { final ProcessGroup group = flowController.getFlowManager().getGroup(groupId); // on demand status request for a specific user... require authorization per component and filter results as appropriate return getGroupStatus(group, statusReport, authorizable -> authorizable.isAuthorized(flowController.getAuthorizer(), RequestAction.READ, user), Integer.MAX_VALUE, 1); }
/** * Returns the status for the components in the specified group with the * specified report. This request is made by the specified user so the * results will be filtered accordingly. * * @param groupId group id * @param statusReport report * @param user user making request * @param recursiveStatusDepth the number of levels deep we should recurse and still include the the processors' statuses, the groups' statuses, etc. in the returned ProcessGroupStatus * @return the component status */ public ProcessGroupStatus getGroupStatus(final String groupId, final RepositoryStatusReport statusReport, final NiFiUser user, final int recursiveStatusDepth) { final ProcessGroup group = flowController.getFlowManager().getGroup(groupId); // on demand status request for a specific user... require authorization per component and filter results as appropriate return getGroupStatus(group, statusReport, authorizable -> authorizable.isAuthorized(flowController.getAuthorizer(), RequestAction.READ, user), recursiveStatusDepth, 1); }
final ProcessGroupStatus childGroupStatus; if (populateChildStatuses) { childGroupStatus = getGroupStatus(childGroup, statusReport, isAuthorized, recursiveStatusDepth, currentDepth + 1); localChildGroupStatusCollection.add(childGroupStatus); } else { childGroupStatus = getGroupStatus(childGroup, statusReport, authorizable -> false, recursiveStatusDepth, currentDepth + 1);