HealthMonitorStateChangeCollection.GetAllAsync Method

Definition

Get the health state changes of a monitor of a virtual machine within the provided time window (default is the last 24 hours). Optional parameters: $expand (retrieve the monitor's evidence and configuration) and $filter (filter by heartbeat condition).

  • Request Path: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{providerName}/{resourceCollectionName}/{resourceName}/providers/Microsoft.WorkloadMonitor/monitors/{monitorId}/history
  • Operation Id: HealthMonitors_ListStateChanges
public virtual Azure.AsyncPageable<Azure.ResourceManager.WorkloadMonitor.HealthMonitorStateChangeResource> GetAllAsync (string filter = default, string expand = default, DateTimeOffset? startTimestampUtc = default, DateTimeOffset? endTimestampUtc = default, System.Threading.CancellationToken cancellationToken = default);
abstract member GetAllAsync : string * string * Nullable<DateTimeOffset> * Nullable<DateTimeOffset> * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.ResourceManager.WorkloadMonitor.HealthMonitorStateChangeResource>
override this.GetAllAsync : string * string * Nullable<DateTimeOffset> * Nullable<DateTimeOffset> * System.Threading.CancellationToken -> Azure.AsyncPageable<Azure.ResourceManager.WorkloadMonitor.HealthMonitorStateChangeResource>
Public Overridable Function GetAllAsync (Optional filter As String = Nothing, Optional expand As String = Nothing, Optional startTimestampUtc As Nullable(Of DateTimeOffset) = Nothing, Optional endTimestampUtc As Nullable(Of DateTimeOffset) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As AsyncPageable(Of HealthMonitorStateChangeResource)

Parameters

filter
String

Optionally filter by heartbeat condition. Example: $filter=isHeartbeat eq false.

expand
String

Optionally expand the monitor’s evidence and/or configuration. Example: $expand=evidence,configuration.

startTimestampUtc
Nullable<DateTimeOffset>

The start of the time window.

endTimestampUtc
Nullable<DateTimeOffset>

The end of the time window.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

An async collection of HealthMonitorStateChangeResource that may take multiple service requests to iterate over.

Applies to