NetworkFlowMonitor / Client / create_monitor
create_monitor#
- NetworkFlowMonitor.Client.create_monitor(**kwargs)#
Create a monitor for specific network flows between local and remote resources, so that you can monitor network performance for one or several of your workloads. For each monitor, Network Flow Monitor publishes detailed end-to-end performance metrics and a network health indicators (NHI) that informs you whether there were Amazon Web Services network issues for one or more of the network flows tracked by a monitor, during a time period that you choose.
See also: AWS API Documentation
Request Syntax
response = client.create_monitor( monitorName='string', localResources=[ { 'type': 'AWS::EC2::VPC'|'AWS::AvailabilityZone'|'AWS::EC2::Subnet', 'identifier': 'string' }, ], remoteResources=[ { 'type': 'AWS::EC2::VPC'|'AWS::AvailabilityZone'|'AWS::EC2::Subnet'|'AWS::AWSService', 'identifier': 'string' }, ], scopeArn='string', clientToken='string', tags={ 'string': 'string' } )
- Parameters:
monitorName (string) –
[REQUIRED]
The name of the monitor.
localResources (list) –
[REQUIRED]
The local resources to monitor. A local resource, in a bi-directional flow of a workload, is the host where the agent is installed. For example, if a workload consists of an interaction between a web service and a backend database (for example, Amazon Relational Database Service (RDS)), the EC2 instance hosting the web service, which also runs the agent, is the local resource.
(dict) –
A local resource is the host where the agent is installed. Local resources can be a a subnet, a VPC, or an Availability Zone.
type (string) – [REQUIRED]
The type of the local resource. Valid values are
AWS::EC2::VPC
AWS::AvailabilityZone
orAWS::EC2::Subnet
.identifier (string) – [REQUIRED]
The identifier of the local resource, such as an ARN.
remoteResources (list) –
The remote resources to monitor. A remote resource is the other endpoint in the bi-directional flow of a workload, with a local resource. For example, Amazon Relational Database Service (RDS) can be a remote resource.
(dict) –
A remote resource is the other endpoint in a network flow. That is, one endpoint is the local resource and the other is the remote resource. Remote resources can be a a subnet, a VPC, an Availability Zone, or an Amazon Web Services service.
type (string) – [REQUIRED]
The type of the remote resource. Valid values are
AWS::EC2::VPC
AWS::AvailabilityZone
,AWS::EC2::Subnet
, orAWS::AWSService
.identifier (string) – [REQUIRED]
The identifier of the remote resource, such as an ARN.
scopeArn (string) –
[REQUIRED]
The Amazon Resource Name (ARN) of the scope for the monitor.
clientToken (string) –
A unique, case-sensitive string of up to 64 ASCII characters that you specify to make an idempotent API request. Don’t reuse the same client token for other API requests.
This field is autopopulated if not provided.
tags (dict) –
The tags for a monitor. You can add a maximum of 200 tags.
(string) –
(string) –
- Return type:
dict
- Returns:
Response Syntax
{ 'monitorArn': 'string', 'monitorName': 'string', 'monitorStatus': 'PENDING'|'ACTIVE'|'INACTIVE'|'ERROR'|'DELETING', 'localResources': [ { 'type': 'AWS::EC2::VPC'|'AWS::AvailabilityZone'|'AWS::EC2::Subnet', 'identifier': 'string' }, ], 'remoteResources': [ { 'type': 'AWS::EC2::VPC'|'AWS::AvailabilityZone'|'AWS::EC2::Subnet'|'AWS::AWSService', 'identifier': 'string' }, ], 'createdAt': datetime(2015, 1, 1), 'modifiedAt': datetime(2015, 1, 1), 'tags': { 'string': 'string' } }
Response Structure
(dict) –
monitorArn (string) –
The Amazon Resource Name (ARN) of the monitor.
monitorName (string) –
The name of the monitor.
monitorStatus (string) –
The status of a monitor. The status can be one of the following
PENDING
: The monitor is in the process of being created.ACTIVE
: The monitor is active.INACTIVE
: The monitor is inactive.ERROR
: Monitor creation failed due to an error.DELETING
: The monitor is in the process of being deleted.
localResources (list) –
The local resources to monitor. A local resource, in a bi-directional flow of a workload, is the host where the agent is installed.
(dict) –
A local resource is the host where the agent is installed. Local resources can be a a subnet, a VPC, or an Availability Zone.
type (string) –
The type of the local resource. Valid values are
AWS::EC2::VPC
AWS::AvailabilityZone
orAWS::EC2::Subnet
.identifier (string) –
The identifier of the local resource, such as an ARN.
remoteResources (list) –
The remote resources to monitor. A remote resource is the other endpoint in the bi-directional flow of a workload, with a local resource. For example, Amazon Relational Database Service (RDS) can be a remote resource. The remote resource is identified by its ARN or an identifier.
(dict) –
A remote resource is the other endpoint in a network flow. That is, one endpoint is the local resource and the other is the remote resource. Remote resources can be a a subnet, a VPC, an Availability Zone, or an Amazon Web Services service.
type (string) –
The type of the remote resource. Valid values are
AWS::EC2::VPC
AWS::AvailabilityZone
,AWS::EC2::Subnet
, orAWS::AWSService
.identifier (string) –
The identifier of the remote resource, such as an ARN.
createdAt (datetime) –
The date and time when the monitor was created.
modifiedAt (datetime) –
The last date and time that the monitor was modified.
tags (dict) –
The tags for a monitor.
(string) –
(string) –
Exceptions