Interface SmartGroups


public interface SmartGroups
Resource collection API of SmartGroups.
  • Method Details

    • list

      com.azure.core.http.rest.PagedIterable<SmartGroup> list()
      Get all Smart Groups within a specified subscription

      List all the Smart Groups within a specified subscription.

      Returns:
      list the alerts as paginated response with PagedIterable.
      Throws:
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • list

      com.azure.core.http.rest.PagedIterable<SmartGroup> list(String targetResource, String targetResourceGroup, String targetResourceType, MonitorService monitorService, MonitorCondition monitorCondition, Severity severity, AlertState smartGroupState, TimeRange timeRange, Long pageCount, SmartGroupsSortByFields sortBy, SortOrder sortOrder, com.azure.core.util.Context context)
      Get all Smart Groups within a specified subscription

      List all the Smart Groups within a specified subscription.

      Parameters:
      targetResource - Filter by target resource( which is full ARM ID) Default value is select all.
      targetResourceGroup - Filter by target resource group name. Default value is select all.
      targetResourceType - Filter by target resource type. Default value is select all.
      monitorService - Filter by monitor service which generates the alert instance. Default value is select all.
      monitorCondition - Filter by monitor condition which is either 'Fired' or 'Resolved'. Default value is to select all.
      severity - Filter by severity. Default value is select all.
      smartGroupState - Filter by state of the smart group. Default value is to select all.
      timeRange - Filter by time range by below listed values. Default value is 1 day.
      pageCount - Determines number of alerts returned per page in response. Permissible value is between 1 to 250. When the "includeContent" filter is selected, maximum value allowed is 25. Default value is 25.
      sortBy - Sort the query results by input field. Default value is sort by 'lastModifiedDateTime'.
      sortOrder - Sort the query results order in either ascending or descending. Default value is 'desc' for time fields and 'asc' for others.
      context - The context to associate with this operation.
      Returns:
      list the alerts as paginated response with PagedIterable.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • getById

      SmartGroup getById(String smartGroupId)
      Get information related to a specific Smart Group.
      Parameters:
      smartGroupId - Smart group unique id.
      Returns:
      information related to a specific Smart Group.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • getByIdWithResponse

      com.azure.core.http.rest.Response<SmartGroup> getByIdWithResponse(String smartGroupId, com.azure.core.util.Context context)
      Get information related to a specific Smart Group.
      Parameters:
      smartGroupId - Smart group unique id.
      context - The context to associate with this operation.
      Returns:
      information related to a specific Smart Group.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • changeState

      SmartGroup changeState(String smartGroupId, AlertState newState)
      Change the state of a Smart Group.
      Parameters:
      smartGroupId - Smart group unique id.
      newState - New state of the alert.
      Returns:
      set of related alerts grouped together smartly by AMS.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • changeStateWithResponse

      com.azure.core.http.rest.Response<SmartGroup> changeStateWithResponse(String smartGroupId, AlertState newState, com.azure.core.util.Context context)
      Change the state of a Smart Group.
      Parameters:
      smartGroupId - Smart group unique id.
      newState - New state of the alert.
      context - The context to associate with this operation.
      Returns:
      set of related alerts grouped together smartly by AMS.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • getHistory

      SmartGroupModification getHistory(String smartGroupId)
      Get the history a smart group, which captures any Smart Group state changes (New/Acknowledged/Closed) .
      Parameters:
      smartGroupId - Smart group unique id.
      Returns:
      the history a smart group, which captures any Smart Group state changes (New/Acknowledged/Closed).
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • getHistoryWithResponse

      com.azure.core.http.rest.Response<SmartGroupModification> getHistoryWithResponse(String smartGroupId, com.azure.core.util.Context context)
      Get the history a smart group, which captures any Smart Group state changes (New/Acknowledged/Closed) .
      Parameters:
      smartGroupId - Smart group unique id.
      context - The context to associate with this operation.
      Returns:
      the history a smart group, which captures any Smart Group state changes (New/Acknowledged/Closed) along with Response.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.