Class CfnAppMonitor
A CloudFormation AWS::RUM::AppMonitor
.
Inherited Members
Namespace: Amazon.CDK.AWS.RUM
Assembly: Amazon.CDK.AWS.RUM.dll
Syntax (csharp)
public class CfnAppMonitor : CfnResource, IConstruct, IDependable, IInspectable
Syntax (vb)
Public Class CfnAppMonitor
Inherits CfnResource
Implements IConstruct, IDependable, IInspectable
Remarks
Creates a CloudWatch RUM app monitor, which you can use to collect telemetry data from your application and send it to CloudWatch RUM. The data includes performance and reliability information such as page load time, client-side errors, and user behavior.
After you create an app monitor, sign in to the CloudWatch RUM console to get the JavaScript code snippet to add to your web application. For more information, see How do I find a code snippet that I've already generated?
CloudformationResource: AWS::RUM::AppMonitor
Link: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-rum-appmonitor.html
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.RUM;
var cfnAppMonitor = new CfnAppMonitor(this, "MyCfnAppMonitor", new CfnAppMonitorProps {
Domain = "domain",
Name = "name",
// the properties below are optional
AppMonitorConfiguration = new AppMonitorConfigurationProperty {
AllowCookies = false,
EnableXRay = false,
ExcludedPages = new [] { "excludedPages" },
FavoritePages = new [] { "favoritePages" },
GuestRoleArn = "guestRoleArn",
IdentityPoolId = "identityPoolId",
IncludedPages = new [] { "includedPages" },
MetricDestinations = new [] { new MetricDestinationProperty {
Destination = "destination",
// the properties below are optional
DestinationArn = "destinationArn",
IamRoleArn = "iamRoleArn",
MetricDefinitions = new [] { new MetricDefinitionProperty {
Name = "name",
// the properties below are optional
DimensionKeys = new Dictionary<string, string> {
{ "dimensionKeysKey", "dimensionKeys" }
},
EventPattern = "eventPattern",
Namespace = "namespace",
UnitLabel = "unitLabel",
ValueKey = "valueKey"
} }
} },
SessionSampleRate = 123,
Telemetries = new [] { "telemetries" }
},
CustomEvents = new CustomEventsProperty {
Status = "status"
},
CwLogEnabled = false,
Tags = new [] { new CfnTag {
Key = "key",
Value = "value"
} }
});
Synopsis
Constructors
CfnAppMonitor(Construct, String, ICfnAppMonitorProps) | Create a new |
CfnAppMonitor(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
CfnAppMonitor(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
Properties
AppMonitorConfiguration | A structure that contains much of the configuration data for the app monitor. |
AttrId | The ID of the app monitor, such as |
CFN_RESOURCE_TYPE_NAME | The CloudFormation resource type name for this resource class. |
CfnProperties | |
CustomEvents | Specifies whether this app monitor allows the web client to define and send custom events. |
CwLogEnabled | Data collected by CloudWatch RUM is kept by RUM for 30 days and then deleted. |
Domain | The top-level internet domain name for which your application has administrative authority. |
Name | A name for the app monitor. |
Tags | Assigns one or more tags (key-value pairs) to the app monitor. |
Methods
Inspect(TreeInspector) | Examines the CloudFormation resource and discloses attributes. |
RenderProperties(IDictionary<String, Object>) |
Constructors
CfnAppMonitor(Construct, String, ICfnAppMonitorProps)
Create a new AWS::RUM::AppMonitor
.
public CfnAppMonitor(Construct scope, string id, ICfnAppMonitorProps props)
Parameters
- scope Construct
- scope in which this resource is defined.
- id System.String
- scoped id of the resource.
- props ICfnAppMonitorProps
- resource properties.
CfnAppMonitor(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected CfnAppMonitor(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
CfnAppMonitor(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected CfnAppMonitor(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
Properties
AppMonitorConfiguration
A structure that contains much of the configuration data for the app monitor.
public virtual object AppMonitorConfiguration { get; set; }
Property Value
System.Object
Remarks
If you are using Amazon Cognito for authorization, you must include this structure in your request, and it must include the ID of the Amazon Cognito identity pool to use for authorization. If you don't include AppMonitorConfiguration
, you must set up your own authorization method. For more information, see Authorize your application to send data to AWS .
If you omit this argument, the sample rate used for CloudWatch RUM is set to 10% of the user sessions.
AttrId
The ID of the app monitor, such as 123456ab-1234-4ca9-9d2f-a1b2c3456789
.
public virtual string AttrId { get; }
Property Value
System.String
Remarks
CloudformationAttribute: Id
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
public static string CFN_RESOURCE_TYPE_NAME { get; }
Property Value
System.String
CfnProperties
protected override IDictionary<string, object> CfnProperties { get; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.Object>
Overrides
CustomEvents
Specifies whether this app monitor allows the web client to define and send custom events.
public virtual object CustomEvents { get; set; }
Property Value
System.Object
Remarks
If you omit this parameter, custom events are DISABLED
.
CwLogEnabled
Data collected by CloudWatch RUM is kept by RUM for 30 days and then deleted.
public virtual object CwLogEnabled { get; set; }
Property Value
System.Object
Remarks
This parameter specifies whether CloudWatch RUM sends a copy of this telemetry data to Amazon CloudWatch Logs in your account. This enables you to keep the telemetry data for more than 30 days, but it does incur Amazon CloudWatch Logs charges.
If you omit this parameter, the default is false
.
Domain
The top-level internet domain name for which your application has administrative authority.
public virtual string Domain { get; set; }
Property Value
System.String
Remarks
This parameter is required.
Name
A name for the app monitor.
public virtual string Name { get; set; }
Property Value
System.String
Remarks
This parameter is required.
Tags
Assigns one or more tags (key-value pairs) to the app monitor.
public virtual TagManager Tags { get; }
Property Value
Remarks
Tags can help you organize and categorize your resources. You can also use them to scope user permissions by granting a user permission to access or change only resources with certain tag values.
Tags don't have any semantic meaning to AWS and are interpreted strictly as strings of characters.
You can associate as many as 50 tags with an app monitor.
For more information, see Tagging AWS resources .
Methods
Inspect(TreeInspector)
Examines the CloudFormation resource and discloses attributes.
public virtual void Inspect(TreeInspector inspector)
Parameters
- inspector TreeInspector
- tree inspector to collect and process attributes.
RenderProperties(IDictionary<String, Object>)
protected override IDictionary<string, object> RenderProperties(IDictionary<string, object> props)
Parameters
- props System.Collections.Generic.IDictionary<System.String, System.Object>
Returns
System.Collections.Generic.IDictionary<System.String, System.Object>