servicediscovery_get_instances_health_status: Gets the current health status (Healthy, Unhealthy, or...

Description Usage Arguments Value Request syntax Examples

View source: R/servicediscovery_operations.R

Description

Gets the current health status (Healthy, Unhealthy, or Unknown) of one or more instances that are associated with a specified service.

There is a brief delay between when you register an instance and when the health status for the instance is available.

Usage

1
2
servicediscovery_get_instances_health_status(ServiceId, Instances,
  MaxResults, NextToken)

Arguments

ServiceId

[required] The ID of the service that the instance is associated with.

Instances

An array that contains the IDs of all the instances that you want to get the health status for.

If you omit Instances, AWS Cloud Map returns the health status for all the instances that are associated with the specified service.

To get the IDs for the instances that you've registered by using a specified service, submit a list_instances request.

MaxResults

The maximum number of instances that you want AWS Cloud Map to return in the response to a get_instances_health_status request. If you don't specify a value for MaxResults, AWS Cloud Map returns up to 100 instances.

NextToken

For the first get_instances_health_status request, omit this value.

If more than MaxResults instances match the specified criteria, you can submit another get_instances_health_status request to get the next group of results. Specify the value of NextToken from the previous response in the next request.

Value

A list with the following syntax:

1
2
3
4
5
6
list(
  Status = list(
    "HEALTHY"|"UNHEALTHY"|"UNKNOWN"
  ),
  NextToken = "string"
)

Request syntax

1
2
3
4
5
6
7
8
svc$get_instances_health_status(
  ServiceId = "string",
  Instances = list(
    "string"
  ),
  MaxResults = 123,
  NextToken = "string"
)

Examples

1
2
3
4
5
6
7
8
## Not run: 
# This example gets the current health status of one or more instances
# that are associate with a specified service.
svc$get_instances_health_status(
  ServiceId = "srv-e4anhexample0004"
)

## End(Not run)

paws.networking documentation built on March 7, 2021, 5:08 p.m.