aws-sdk-cloudwatchrum 1.8.0 → 1.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 20bb52ab04849ccff2aa8e3b4693d60fe788a58e95d6fdcb3f5189049692ac54
4
- data.tar.gz: 503e19e7f22fa108214cae2aaa9a5ae4afb8a508c8a3e9daa03633bd04ae3f02
3
+ metadata.gz: 9b0a930f1aeddabdd05066e8aed44696135857a631d28b77dd755c17f9700a17
4
+ data.tar.gz: b019010acf76af8382445a3e396cfda0b808705f06059efba15a11c8b4eabeb3
5
5
  SHA512:
6
- metadata.gz: 255be46858c8501eec0d0a4e5a120a45601fcf487b36366fce45a251138e4a75950aa9ce368455408e83f3115dbd673897a26d907edf795823c43429b1680562
7
- data.tar.gz: 5c6923940bbd6d077a80316e8fb3eb8061b4d8f6890ef5913edcc570b5d175dd20e3dea2af0a0f270f4330a751eb47b50dbfae49123a23f9ea0f90b21854c875
6
+ metadata.gz: c68cc9c88c896706e1946e39e2bbbfeae47df4be0ebd9e5ce696c0609d6541251fa00b18512e1978d68644c72b500f39b0320b3e81856ba2f12a30263e981452
7
+ data.tar.gz: f061dd498ab3929eca0c1e54eeff59cc964a97848d57282275c1b97310a9eb24c3848baab18691c215f09e39a2ba99179f3e4ca8b9f1d3ee1e3da5006a267c15
data/CHANGELOG.md CHANGED
@@ -1,6 +1,11 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 1.9.0 (2023-02-22)
5
+ ------------------
6
+
7
+ * Feature - CloudWatch RUM now supports CloudWatch Custom Metrics
8
+
4
9
  1.8.0 (2023-01-18)
5
10
  ------------------
6
11
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.8.0
1
+ 1.9.0
@@ -368,21 +368,37 @@ module Aws::CloudWatchRUM
368
368
 
369
369
  # @!group API Operations
370
370
 
371
- # Specifies the extended metrics that you want a CloudWatch RUM app
372
- # monitor to send to a destination. Valid destinations include
373
- # CloudWatch and Evidently.
371
+ # Specifies the extended metrics and custom metrics that you want a
372
+ # CloudWatch RUM app monitor to send to a destination. Valid
373
+ # destinations include CloudWatch and Evidently.
374
374
  #
375
375
  # By default, RUM app monitors send some metrics to CloudWatch. These
376
376
  # default metrics are listed in [CloudWatch metrics that you can collect
377
377
  # with CloudWatch RUM][1].
378
378
  #
379
- # If you also send extended metrics, you can send metrics to Evidently
380
- # as well as CloudWatch, and you can also optionally send the metrics
381
- # with additional dimensions. The valid dimension names for the
382
- # additional dimensions are `BrowserName`, `CountryCode`, `DeviceType`,
383
- # `FileType`, `OSName`, and `PageId`. For more information, see [
384
- # Extended metrics that you can send to CloudWatch and CloudWatch
385
- # Evidently][2].
379
+ # In addition to these default metrics, you can choose to send extended
380
+ # metrics or custom metrics or both.
381
+ #
382
+ # * Extended metrics enable you to send metrics with additional
383
+ # dimensions not included in the default metrics. You can also send
384
+ # extended metrics to Evidently as well as CloudWatch. The valid
385
+ # dimension names for the additional dimensions for extended metrics
386
+ # are `BrowserName`, `CountryCode`, `DeviceType`, `FileType`,
387
+ # `OSName`, and `PageId`. For more information, see [ Extended metrics
388
+ # that you can send to CloudWatch and CloudWatch Evidently][2].
389
+ #
390
+ # * Custom metrics are metrics that you define. You can send custom
391
+ # metrics to CloudWatch or to CloudWatch Evidently or to both. With
392
+ # custom metrics, you can use any metric name and namespace, and to
393
+ # derive the metrics you can use any custom events, built-in events,
394
+ # custom attributes, or default attributes.
395
+ #
396
+ # You can't send custom metrics to the `AWS/RUM` namespace. You must
397
+ # send custom metrics to a custom namespace that you define. The
398
+ # namespace that you use can't start with `AWS/`. CloudWatch RUM
399
+ # prepends `RUM/CustomMetrics/` to the custom namespace that you
400
+ # define, so the final namespace for your metrics in CloudWatch is
401
+ # `RUM/CustomMetrics/your-custom-namespace `.
386
402
  #
387
403
  # The maximum number of metric definitions that you can specify in one
388
404
  # `BatchCreateRumMetricDefinitions` operation is 200.
@@ -390,10 +406,10 @@ module Aws::CloudWatchRUM
390
406
  # The maximum number of metric definitions that one destination can
391
407
  # contain is 2000.
392
408
  #
393
- # Extended metrics sent are charged as CloudWatch custom metrics. Each
394
- # combination of additional dimension name and dimension value counts as
395
- # a custom metric. For more information, see [Amazon CloudWatch
396
- # Pricing][3].
409
+ # Extended metrics sent to CloudWatch and RUM custom metrics are charged
410
+ # as CloudWatch custom metrics. Each combination of additional dimension
411
+ # name and dimension value counts as a custom metric. For more
412
+ # information, see [Amazon CloudWatch Pricing][3].
397
413
  #
398
414
  # You must have already created a destination for the metrics before you
399
415
  # send them. For more information, see [PutRumMetricsDestination][4].
@@ -455,6 +471,7 @@ module Aws::CloudWatchRUM
455
471
  # },
456
472
  # event_pattern: "EventPattern",
457
473
  # name: "MetricName", # required
474
+ # namespace: "Namespace",
458
475
  # unit_label: "UnitLabel",
459
476
  # value_key: "ValueKey",
460
477
  # },
@@ -470,6 +487,7 @@ module Aws::CloudWatchRUM
470
487
  # resp.errors[0].metric_definition.dimension_keys["DimensionKey"] #=> String
471
488
  # resp.errors[0].metric_definition.event_pattern #=> String
472
489
  # resp.errors[0].metric_definition.name #=> String
490
+ # resp.errors[0].metric_definition.namespace #=> String
473
491
  # resp.errors[0].metric_definition.unit_label #=> String
474
492
  # resp.errors[0].metric_definition.value_key #=> String
475
493
  # resp.metric_definitions #=> Array
@@ -478,6 +496,7 @@ module Aws::CloudWatchRUM
478
496
  # resp.metric_definitions[0].event_pattern #=> String
479
497
  # resp.metric_definitions[0].metric_definition_id #=> String
480
498
  # resp.metric_definitions[0].name #=> String
499
+ # resp.metric_definitions[0].namespace #=> String
481
500
  # resp.metric_definitions[0].unit_label #=> String
482
501
  # resp.metric_definitions[0].value_key #=> String
483
502
  #
@@ -609,6 +628,7 @@ module Aws::CloudWatchRUM
609
628
  # resp.metric_definitions[0].event_pattern #=> String
610
629
  # resp.metric_definitions[0].metric_definition_id #=> String
611
630
  # resp.metric_definitions[0].name #=> String
631
+ # resp.metric_definitions[0].namespace #=> String
612
632
  # resp.metric_definitions[0].unit_label #=> String
613
633
  # resp.metric_definitions[0].value_key #=> String
614
634
  # resp.next_token #=> String
@@ -1083,20 +1103,20 @@ module Aws::CloudWatchRUM
1083
1103
  # name: "String",
1084
1104
  # version: "String",
1085
1105
  # },
1086
- # batch_id: "String", # required
1087
- # id: "AppMonitorId", # required
1106
+ # batch_id: "PutRumEventsRequestBatchIdString", # required
1107
+ # id: "PutRumEventsRequestIdString", # required
1088
1108
  # rum_events: [ # required
1089
1109
  # {
1090
1110
  # details: "JsonValue", # required
1091
- # id: "String", # required
1111
+ # id: "RumEventIdString", # required
1092
1112
  # metadata: "JsonValue",
1093
1113
  # timestamp: Time.now, # required
1094
1114
  # type: "String", # required
1095
1115
  # },
1096
1116
  # ],
1097
1117
  # user_details: { # required
1098
- # session_id: "String",
1099
- # user_id: "String",
1118
+ # session_id: "UserDetailsSessionIdString",
1119
+ # user_id: "UserDetailsUserIdString",
1100
1120
  # },
1101
1121
  # })
1102
1122
  #
@@ -1113,11 +1133,12 @@ module Aws::CloudWatchRUM
1113
1133
  # CloudWatch RUM. You can send extended metrics to CloudWatch or to a
1114
1134
  # CloudWatch Evidently experiment.
1115
1135
  #
1116
- # For more information about extended metrics, see [AddRumMetrics][1].
1136
+ # For more information about extended metrics, see
1137
+ # [BatchCreateRumMetricDefinitions][1].
1117
1138
  #
1118
1139
  #
1119
1140
  #
1120
- # [1]: https://docs.aws.amazon.com/cloudwatchrum/latest/APIReference/API_AddRumMetrics.html
1141
+ # [1]: https://docs.aws.amazon.com/cloudwatchrum/latest/APIReference/API_BatchCreateRumMetricDefinitions.html
1121
1142
  #
1122
1143
  # @option params [required, String] :app_monitor_name
1123
1144
  # The name of the CloudWatch RUM app monitor that will send the metrics.
@@ -1384,6 +1405,7 @@ module Aws::CloudWatchRUM
1384
1405
  # },
1385
1406
  # event_pattern: "EventPattern",
1386
1407
  # name: "MetricName", # required
1408
+ # namespace: "Namespace",
1387
1409
  # unit_label: "UnitLabel",
1388
1410
  # value_key: "ValueKey",
1389
1411
  # },
@@ -1412,7 +1434,7 @@ module Aws::CloudWatchRUM
1412
1434
  params: params,
1413
1435
  config: config)
1414
1436
  context[:gem_name] = 'aws-sdk-cloudwatchrum'
1415
- context[:gem_version] = '1.8.0'
1437
+ context[:gem_version] = '1.9.0'
1416
1438
  Seahorse::Client::Request.new(handlers, context)
1417
1439
  end
1418
1440
 
@@ -81,8 +81,11 @@ module Aws::CloudWatchRUM
81
81
  MetricDestinationSummary = Shapes::StructureShape.new(name: 'MetricDestinationSummary')
82
82
  MetricDestinationSummaryList = Shapes::ListShape.new(name: 'MetricDestinationSummaryList')
83
83
  MetricName = Shapes::StringShape.new(name: 'MetricName')
84
+ Namespace = Shapes::StringShape.new(name: 'Namespace')
84
85
  Pages = Shapes::ListShape.new(name: 'Pages')
85
86
  PutRumEventsRequest = Shapes::StructureShape.new(name: 'PutRumEventsRequest')
87
+ PutRumEventsRequestBatchIdString = Shapes::StringShape.new(name: 'PutRumEventsRequestBatchIdString')
88
+ PutRumEventsRequestIdString = Shapes::StringShape.new(name: 'PutRumEventsRequestIdString')
86
89
  PutRumEventsResponse = Shapes::StructureShape.new(name: 'PutRumEventsResponse')
87
90
  PutRumMetricsDestinationRequest = Shapes::StructureShape.new(name: 'PutRumMetricsDestinationRequest')
88
91
  PutRumMetricsDestinationResponse = Shapes::StructureShape.new(name: 'PutRumMetricsDestinationResponse')
@@ -94,6 +97,7 @@ module Aws::CloudWatchRUM
94
97
  QueryTimestamp = Shapes::IntegerShape.new(name: 'QueryTimestamp')
95
98
  ResourceNotFoundException = Shapes::StructureShape.new(name: 'ResourceNotFoundException')
96
99
  RumEvent = Shapes::StructureShape.new(name: 'RumEvent')
100
+ RumEventIdString = Shapes::StringShape.new(name: 'RumEventIdString')
97
101
  RumEventList = Shapes::ListShape.new(name: 'RumEventList')
98
102
  ServiceQuotaExceededException = Shapes::StructureShape.new(name: 'ServiceQuotaExceededException')
99
103
  SessionSampleRate = Shapes::FloatShape.new(name: 'SessionSampleRate')
@@ -120,6 +124,8 @@ module Aws::CloudWatchRUM
120
124
  UpdateRumMetricDefinitionResponse = Shapes::StructureShape.new(name: 'UpdateRumMetricDefinitionResponse')
121
125
  Url = Shapes::StringShape.new(name: 'Url')
122
126
  UserDetails = Shapes::StructureShape.new(name: 'UserDetails')
127
+ UserDetailsSessionIdString = Shapes::StringShape.new(name: 'UserDetailsSessionIdString')
128
+ UserDetailsUserIdString = Shapes::StringShape.new(name: 'UserDetailsUserIdString')
123
129
  ValidationException = Shapes::StructureShape.new(name: 'ValidationException')
124
130
  ValueKey = Shapes::StringShape.new(name: 'ValueKey')
125
131
 
@@ -302,6 +308,7 @@ module Aws::CloudWatchRUM
302
308
  MetricDefinition.add_member(:event_pattern, Shapes::ShapeRef.new(shape: EventPattern, location_name: "EventPattern"))
303
309
  MetricDefinition.add_member(:metric_definition_id, Shapes::ShapeRef.new(shape: MetricDefinitionId, required: true, location_name: "MetricDefinitionId"))
304
310
  MetricDefinition.add_member(:name, Shapes::ShapeRef.new(shape: MetricName, required: true, location_name: "Name"))
311
+ MetricDefinition.add_member(:namespace, Shapes::ShapeRef.new(shape: Namespace, location_name: "Namespace"))
305
312
  MetricDefinition.add_member(:unit_label, Shapes::ShapeRef.new(shape: UnitLabel, location_name: "UnitLabel"))
306
313
  MetricDefinition.add_member(:value_key, Shapes::ShapeRef.new(shape: ValueKey, location_name: "ValueKey"))
307
314
  MetricDefinition.struct_class = Types::MetricDefinition
@@ -311,6 +318,7 @@ module Aws::CloudWatchRUM
311
318
  MetricDefinitionRequest.add_member(:dimension_keys, Shapes::ShapeRef.new(shape: DimensionKeysMap, location_name: "DimensionKeys"))
312
319
  MetricDefinitionRequest.add_member(:event_pattern, Shapes::ShapeRef.new(shape: EventPattern, location_name: "EventPattern"))
313
320
  MetricDefinitionRequest.add_member(:name, Shapes::ShapeRef.new(shape: MetricName, required: true, location_name: "Name"))
321
+ MetricDefinitionRequest.add_member(:namespace, Shapes::ShapeRef.new(shape: Namespace, location_name: "Namespace"))
314
322
  MetricDefinitionRequest.add_member(:unit_label, Shapes::ShapeRef.new(shape: UnitLabel, location_name: "UnitLabel"))
315
323
  MetricDefinitionRequest.add_member(:value_key, Shapes::ShapeRef.new(shape: ValueKey, location_name: "ValueKey"))
316
324
  MetricDefinitionRequest.struct_class = Types::MetricDefinitionRequest
@@ -329,8 +337,8 @@ module Aws::CloudWatchRUM
329
337
  Pages.member = Shapes::ShapeRef.new(shape: Url)
330
338
 
331
339
  PutRumEventsRequest.add_member(:app_monitor_details, Shapes::ShapeRef.new(shape: AppMonitorDetails, required: true, location_name: "AppMonitorDetails"))
332
- PutRumEventsRequest.add_member(:batch_id, Shapes::ShapeRef.new(shape: String, required: true, location_name: "BatchId"))
333
- PutRumEventsRequest.add_member(:id, Shapes::ShapeRef.new(shape: AppMonitorId, required: true, location: "uri", location_name: "Id"))
340
+ PutRumEventsRequest.add_member(:batch_id, Shapes::ShapeRef.new(shape: PutRumEventsRequestBatchIdString, required: true, location_name: "BatchId"))
341
+ PutRumEventsRequest.add_member(:id, Shapes::ShapeRef.new(shape: PutRumEventsRequestIdString, required: true, location: "uri", location_name: "Id"))
334
342
  PutRumEventsRequest.add_member(:rum_events, Shapes::ShapeRef.new(shape: RumEventList, required: true, location_name: "RumEvents"))
335
343
  PutRumEventsRequest.add_member(:user_details, Shapes::ShapeRef.new(shape: UserDetails, required: true, location_name: "UserDetails"))
336
344
  PutRumEventsRequest.struct_class = Types::PutRumEventsRequest
@@ -359,7 +367,7 @@ module Aws::CloudWatchRUM
359
367
  ResourceNotFoundException.struct_class = Types::ResourceNotFoundException
360
368
 
361
369
  RumEvent.add_member(:details, Shapes::ShapeRef.new(shape: JsonValue, required: true, location_name: "details", metadata: {"jsonvalue"=>true}))
362
- RumEvent.add_member(:id, Shapes::ShapeRef.new(shape: String, required: true, location_name: "id"))
370
+ RumEvent.add_member(:id, Shapes::ShapeRef.new(shape: RumEventIdString, required: true, location_name: "id"))
363
371
  RumEvent.add_member(:metadata, Shapes::ShapeRef.new(shape: JsonValue, location_name: "metadata", metadata: {"jsonvalue"=>true}))
364
372
  RumEvent.add_member(:timestamp, Shapes::ShapeRef.new(shape: Timestamp, required: true, location_name: "timestamp"))
365
373
  RumEvent.add_member(:type, Shapes::ShapeRef.new(shape: String, required: true, location_name: "type"))
@@ -417,8 +425,8 @@ module Aws::CloudWatchRUM
417
425
 
418
426
  UpdateRumMetricDefinitionResponse.struct_class = Types::UpdateRumMetricDefinitionResponse
419
427
 
420
- UserDetails.add_member(:session_id, Shapes::ShapeRef.new(shape: String, location_name: "sessionId"))
421
- UserDetails.add_member(:user_id, Shapes::ShapeRef.new(shape: String, location_name: "userId"))
428
+ UserDetails.add_member(:session_id, Shapes::ShapeRef.new(shape: UserDetailsSessionIdString, location_name: "sessionId"))
429
+ UserDetails.add_member(:user_id, Shapes::ShapeRef.new(shape: UserDetailsUserIdString, location_name: "userId"))
422
430
  UserDetails.struct_class = Types::UserDetails
423
431
 
424
432
  ValidationException.add_member(:message, Shapes::ShapeRef.new(shape: String, required: true, location_name: "message"))
@@ -14,36 +14,39 @@ module Aws::CloudWatchRUM
14
14
  use_dual_stack = parameters.use_dual_stack
15
15
  use_fips = parameters.use_fips
16
16
  endpoint = parameters.endpoint
17
- if (partition_result = Aws::Endpoints::Matchers.aws_partition(region))
18
- if Aws::Endpoints::Matchers.set?(endpoint) && (url = Aws::Endpoints::Matchers.parse_url(endpoint))
19
- if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
20
- raise ArgumentError, "Invalid Configuration: FIPS and custom endpoint are not supported"
21
- end
22
- if Aws::Endpoints::Matchers.boolean_equals?(use_dual_stack, true)
23
- raise ArgumentError, "Invalid Configuration: Dualstack and custom endpoint are not supported"
24
- end
25
- return Aws::Endpoints::Endpoint.new(url: endpoint, headers: {}, properties: {})
26
- end
27
- if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true) && Aws::Endpoints::Matchers.boolean_equals?(use_dual_stack, true)
28
- if Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsFIPS")) && Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsDualStack"))
29
- return Aws::Endpoints::Endpoint.new(url: "https://rum-fips.#{region}.#{partition_result['dualStackDnsSuffix']}", headers: {}, properties: {})
30
- end
31
- raise ArgumentError, "FIPS and DualStack are enabled, but this partition does not support one or both"
32
- end
17
+ if Aws::Endpoints::Matchers.set?(endpoint)
33
18
  if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
34
- if Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsFIPS"))
35
- return Aws::Endpoints::Endpoint.new(url: "https://rum-fips.#{region}.#{partition_result['dnsSuffix']}", headers: {}, properties: {})
36
- end
37
- raise ArgumentError, "FIPS is enabled but this partition does not support FIPS"
19
+ raise ArgumentError, "Invalid Configuration: FIPS and custom endpoint are not supported"
38
20
  end
39
21
  if Aws::Endpoints::Matchers.boolean_equals?(use_dual_stack, true)
40
- if Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsDualStack"))
41
- return Aws::Endpoints::Endpoint.new(url: "https://rum.#{region}.#{partition_result['dualStackDnsSuffix']}", headers: {}, properties: {})
22
+ raise ArgumentError, "Invalid Configuration: Dualstack and custom endpoint are not supported"
23
+ end
24
+ return Aws::Endpoints::Endpoint.new(url: endpoint, headers: {}, properties: {})
25
+ end
26
+ if Aws::Endpoints::Matchers.set?(region)
27
+ if (partition_result = Aws::Endpoints::Matchers.aws_partition(region))
28
+ if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true) && Aws::Endpoints::Matchers.boolean_equals?(use_dual_stack, true)
29
+ if Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsFIPS")) && Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsDualStack"))
30
+ return Aws::Endpoints::Endpoint.new(url: "https://rum-fips.#{region}.#{partition_result['dualStackDnsSuffix']}", headers: {}, properties: {})
31
+ end
32
+ raise ArgumentError, "FIPS and DualStack are enabled, but this partition does not support one or both"
33
+ end
34
+ if Aws::Endpoints::Matchers.boolean_equals?(use_fips, true)
35
+ if Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsFIPS"))
36
+ return Aws::Endpoints::Endpoint.new(url: "https://rum-fips.#{region}.#{partition_result['dnsSuffix']}", headers: {}, properties: {})
37
+ end
38
+ raise ArgumentError, "FIPS is enabled but this partition does not support FIPS"
39
+ end
40
+ if Aws::Endpoints::Matchers.boolean_equals?(use_dual_stack, true)
41
+ if Aws::Endpoints::Matchers.boolean_equals?(true, Aws::Endpoints::Matchers.attr(partition_result, "supportsDualStack"))
42
+ return Aws::Endpoints::Endpoint.new(url: "https://rum.#{region}.#{partition_result['dualStackDnsSuffix']}", headers: {}, properties: {})
43
+ end
44
+ raise ArgumentError, "DualStack is enabled but this partition does not support DualStack"
42
45
  end
43
- raise ArgumentError, "DualStack is enabled but this partition does not support DualStack"
46
+ return Aws::Endpoints::Endpoint.new(url: "https://rum.#{region}.#{partition_result['dnsSuffix']}", headers: {}, properties: {})
44
47
  end
45
- return Aws::Endpoints::Endpoint.new(url: "https://rum.#{region}.#{partition_result['dnsSuffix']}", headers: {}, properties: {})
46
48
  end
49
+ raise ArgumentError, "Invalid Configuration: Missing Region"
47
50
  raise ArgumentError, 'No endpoint could be resolved'
48
51
 
49
52
  end
@@ -965,6 +965,12 @@ module Aws::CloudWatchRUM
965
965
  # The name of the metric that is defined in this structure.
966
966
  # @return [String]
967
967
  #
968
+ # @!attribute [rw] namespace
969
+ # If this metric definition is for a custom metric instead of an
970
+ # extended metric, this field displays the metric namespace that the
971
+ # custom metric is published to.
972
+ # @return [String]
973
+ #
968
974
  # @!attribute [rw] unit_label
969
975
  # Use this field only if you are sending this metric to CloudWatch. It
970
976
  # defines the CloudWatch metric unit that this metric is measured in.
@@ -982,79 +988,151 @@ module Aws::CloudWatchRUM
982
988
  :event_pattern,
983
989
  :metric_definition_id,
984
990
  :name,
991
+ :namespace,
985
992
  :unit_label,
986
993
  :value_key)
987
994
  SENSITIVE = []
988
995
  include Aws::Structure
989
996
  end
990
997
 
991
- # Use this structure to define one extended metric that RUM will send to
992
- # CloudWatch or CloudWatch Evidently. For more information, see [
993
- # Additional metrics that you can send to CloudWatch and CloudWatch
994
- # Evidently][1].
998
+ # Use this structure to define one extended metric or custom metric that
999
+ # RUM will send to CloudWatch or CloudWatch Evidently. For more
1000
+ # information, see [ Additional metrics that you can send to CloudWatch
1001
+ # and CloudWatch Evidently][1].
1002
+ #
1003
+ # This structure is validated differently for extended metrics and
1004
+ # custom metrics. For extended metrics that are sent to the `AWS/RUM`
1005
+ # namespace, the following validations apply:
1006
+ #
1007
+ # * The `Namespace` parameter must be omitted or set to `AWS/RUM`.
1008
+ #
1009
+ # * Only certain combinations of values for `Name`, `ValueKey`, and
1010
+ # `EventPattern` are valid. In addition to what is displayed in the
1011
+ # list below, the `EventPattern` can also include information used by
1012
+ # the `DimensionKeys` field.
1013
+ #
1014
+ # * If `Name` is `PerformanceNavigationDuration`, then `ValueKey`must
1015
+ # be `event_details.duration` and the `EventPattern` must include
1016
+ # `\{"event_type":["com.amazon.rum.performance_navigation_event"]\}`
1017
+ #
1018
+ # * If `Name` is `PerformanceResourceDuration`, then `ValueKey`must be
1019
+ # `event_details.duration` and the `EventPattern` must include
1020
+ # `\{"event_type":["com.amazon.rum.performance_resource_event"]\}`
1021
+ #
1022
+ # * If `Name` is `NavigationSatisfiedTransaction`, then `ValueKey`must
1023
+ # be null and the `EventPattern` must include `\{ "event_type":
1024
+ # ["com.amazon.rum.performance_navigation_event"], "event_details":
1025
+ # \{ "duration": [\{ "numeric": [">",2000] \}] \} \}`
1026
+ #
1027
+ # * If `Name` is `NavigationToleratedTransaction`, then `ValueKey`must
1028
+ # be null and the `EventPattern` must include `\{ "event_type":
1029
+ # ["com.amazon.rum.performance_navigation_event"], "event_details":
1030
+ # \{ "duration": [\{ "numeric": [">=",2000,"<"8000] \}] \} \}`
1031
+ #
1032
+ # * If `Name` is `NavigationFrustratedTransaction`, then
1033
+ # `ValueKey`must be null and the `EventPattern` must include `\{
1034
+ # "event_type": ["com.amazon.rum.performance_navigation_event"],
1035
+ # "event_details": \{ "duration": [\{ "numeric": [">=",8000] \}] \}
1036
+ # \}`
1037
+ #
1038
+ # * If `Name` is `WebVitalsCumulativeLayoutShift`, then `ValueKey`must
1039
+ # be `event_details.value` and the `EventPattern` must include
1040
+ # `\{"event_type":["com.amazon.rum.cumulative_layout_shift_event"]\}`
1041
+ #
1042
+ # * If `Name` is `WebVitalsFirstInputDelay`, then `ValueKey`must be
1043
+ # `event_details.value` and the `EventPattern` must include
1044
+ # `\{"event_type":["com.amazon.rum.first_input_delay_event"]\}`
1045
+ #
1046
+ # * If `Name` is `WebVitalsLargestContentfulPaint`, then
1047
+ # `ValueKey`must be `event_details.value` and the `EventPattern`
1048
+ # must include
1049
+ # `\{"event_type":["com.amazon.rum.largest_contentful_paint_event"]\}`
1050
+ #
1051
+ # * If `Name` is `JsErrorCount`, then `ValueKey`must be null and the
1052
+ # `EventPattern` must include
1053
+ # `\{"event_type":["com.amazon.rum.js_error_event"]\}`
1054
+ #
1055
+ # * If `Name` is `HttpErrorCount`, then `ValueKey`must be null and the
1056
+ # `EventPattern` must include
1057
+ # `\{"event_type":["com.amazon.rum.http_event"]\}`
1058
+ #
1059
+ # * If `Name` is `SessionCount`, then `ValueKey`must be null and the
1060
+ # `EventPattern` must include
1061
+ # `\{"event_type":["com.amazon.rum.session_start_event"]\}`
995
1062
  #
996
- # Only certain combinations of values for `Name`, `ValueKey`, and
997
- # `EventPattern` are valid. In addition to what is displayed in the list
998
- # below, the `EventPattern` can also include information used by the
999
- # `DimensionKeys` field.
1063
+ # For custom metrics, the following validation rules apply:
1000
1064
  #
1001
- # * If `Name` is `PerformanceNavigationDuration`, then `ValueKey`must be
1002
- # `event_details.duration` and the `EventPattern` must include
1003
- # `\{"event_type":["com.amazon.rum.performance_navigation_event"]\}`
1065
+ # * The namespace can't be omitted and can't be `AWS/RUM`. You can use
1066
+ # the `AWS/RUM` namespace only for extended metrics.
1004
1067
  #
1005
- # * If `Name` is `PerformanceResourceDuration`, then `ValueKey`must be
1006
- # `event_details.duration` and the `EventPattern` must include
1007
- # `\{"event_type":["com.amazon.rum.performance_resource_event"]\}`
1068
+ # * All dimensions listed in the `DimensionKeys` field must be present
1069
+ # in the value of `EventPattern`.
1008
1070
  #
1009
- # * If `Name` is `NavigationSatisfiedTransaction`, then `ValueKey`must
1010
- # be null and the `EventPattern` must include `\{ "event_type":
1011
- # ["com.amazon.rum.performance_navigation_event"], "event_details": \{
1012
- # "duration": [\{ "numeric": [">",2000] \}] \} \}`
1071
+ # * The values that you specify for `ValueKey`, `EventPattern`, and
1072
+ # `DimensionKeys` must be fields in RUM events, so all first-level
1073
+ # keys in these fields must be one of the keys in the list later in
1074
+ # this section.
1013
1075
  #
1014
- # * If `Name` is `NavigationToleratedTransaction`, then `ValueKey`must
1015
- # be null and the `EventPattern` must include `\{ "event_type":
1016
- # ["com.amazon.rum.performance_navigation_event"], "event_details": \{
1017
- # "duration": [\{ "numeric": [">=",2000,"<"8000] \}] \} \}`
1076
+ # * If you set a value for `EventPattern`, it must be a JSON object.
1018
1077
  #
1019
- # * If `Name` is `NavigationFrustratedTransaction`, then `ValueKey`must
1020
- # be null and the `EventPattern` must include `\{ "event_type":
1021
- # ["com.amazon.rum.performance_navigation_event"], "event_details": \{
1022
- # "duration": [\{ "numeric": [">=",8000] \}] \} \}`
1078
+ # * For every non-empty `event_details`, there must be a non-empty
1079
+ # `event_type`.
1023
1080
  #
1024
- # * If `Name` is `WebVitalsCumulativeLayoutShift`, then `ValueKey`must
1025
- # be `event_details.value` and the `EventPattern` must include
1026
- # `\{"event_type":["com.amazon.rum.cumulative_layout_shift_event"]\}`
1081
+ # * If `EventPattern` contains an `event_details` field, it must also
1082
+ # contain an `event_type`. For every built-in `event_type` that you
1083
+ # use, you must use a value for `event_details` that corresponds to
1084
+ # that `event_type`. For information about event details that
1085
+ # correspond to event types, see [ RUM event details][2].
1027
1086
  #
1028
- # * If `Name` is `WebVitalsFirstInputDelay`, then `ValueKey`must be
1029
- # `event_details.value` and the `EventPattern` must include
1030
- # `\{"event_type":["com.amazon.rum.first_input_delay_event"]\}`
1087
+ # * In `EventPattern`, any JSON array must contain only one value.
1031
1088
  #
1032
- # * If `Name` is `WebVitalsLargestContentfulPaint`, then `ValueKey`must
1033
- # be `event_details.value` and the `EventPattern` must include
1034
- # `\{"event_type":["com.amazon.rum.largest_contentful_paint_event"]\}`
1089
+ # Valid key values for first-level keys in the `ValueKey`,
1090
+ # `EventPattern`, and `DimensionKeys` fields:
1035
1091
  #
1036
- # * If `Name` is `JsErrorCount`, then `ValueKey`must be null and the
1037
- # `EventPattern` must include
1038
- # `\{"event_type":["com.amazon.rum.js_error_event"]\}`
1092
+ # * `account_id`
1039
1093
  #
1040
- # * If `Name` is `HttpErrorCount`, then `ValueKey`must be null and the
1041
- # `EventPattern` must include
1042
- # `\{"event_type":["com.amazon.rum.http_event"]\}`
1094
+ # * `application_Id`
1043
1095
  #
1044
- # * If `Name` is `SessionCount`, then `ValueKey`must be null and the
1045
- # `EventPattern` must include
1046
- # `\{"event_type":["com.amazon.rum.session_start_event"]\}`
1096
+ # * `application_version`
1097
+ #
1098
+ # * `application_name`
1099
+ #
1100
+ # * `batch_id`
1101
+ #
1102
+ # * `event_details`
1103
+ #
1104
+ # * `event_id`
1105
+ #
1106
+ # * `event_interaction`
1107
+ #
1108
+ # * `event_timestamp`
1109
+ #
1110
+ # * `event_type`
1111
+ #
1112
+ # * `event_version`
1113
+ #
1114
+ # * `log_stream`
1115
+ #
1116
+ # * `metadata`
1117
+ #
1118
+ # * `sessionId`
1119
+ #
1120
+ # * `user_details`
1121
+ #
1122
+ # * `userId`
1047
1123
  #
1048
1124
  #
1049
1125
  #
1050
1126
  # [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-RUM-vended-metrics.html
1127
+ # [2]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-RUM-datacollected.html#CloudWatch-RUM-datacollected-eventDetails
1051
1128
  #
1052
1129
  # @!attribute [rw] dimension_keys
1053
1130
  # Use this field only if you are sending the metric to CloudWatch.
1054
1131
  #
1055
1132
  # This field is a map of field paths to dimension names. It defines
1056
- # the dimensions to associate with this metric in CloudWatch. Valid
1057
- # values for the entries in this field are the following:
1133
+ # the dimensions to associate with this metric in CloudWatch. For
1134
+ # extended metrics, valid values for the entries in this field are the
1135
+ # following:
1058
1136
  #
1059
1137
  # * `"metadata.pageId": "PageId"`
1060
1138
  #
@@ -1068,8 +1146,8 @@ module Aws::CloudWatchRUM
1068
1146
  #
1069
1147
  # * `"event_details.fileType": "FileType"`
1070
1148
  #
1071
- # All dimensions listed in this field must also be included in
1072
- # `EventPattern`.
1149
+ # For both extended metrics and custom metrics, all dimensions listed
1150
+ # in this field must also be included in `EventPattern`.
1073
1151
  # @return [Hash<String,String>]
1074
1152
  #
1075
1153
  # @!attribute [rw] event_pattern
@@ -1103,8 +1181,9 @@ module Aws::CloudWatchRUM
1103
1181
  # @return [String]
1104
1182
  #
1105
1183
  # @!attribute [rw] name
1106
- # The name for the metric that is defined in this structure. Valid
1107
- # values are the following:
1184
+ # The name for the metric that is defined in this structure. For
1185
+ # custom metrics, you can specify any name that you like. For extended
1186
+ # metrics, valid values are the following:
1108
1187
  #
1109
1188
  # * `PerformanceNavigationDuration`
1110
1189
  #
@@ -1129,6 +1208,16 @@ module Aws::CloudWatchRUM
1129
1208
  # * `SessionCount`
1130
1209
  # @return [String]
1131
1210
  #
1211
+ # @!attribute [rw] namespace
1212
+ # If this structure is for a custom metric instead of an extended
1213
+ # metrics, use this parameter to define the metric namespace for that
1214
+ # custom metric. Do not specify this parameter if this structure is
1215
+ # for an extended metric.
1216
+ #
1217
+ # You cannot use any string that starts with `AWS/` for your
1218
+ # namespace.
1219
+ # @return [String]
1220
+ #
1132
1221
  # @!attribute [rw] unit_label
1133
1222
  # The CloudWatch metric unit to use for this metric. If you omit this
1134
1223
  # field, the metric is recorded with no unit.
@@ -1153,6 +1242,7 @@ module Aws::CloudWatchRUM
1153
1242
  :dimension_keys,
1154
1243
  :event_pattern,
1155
1244
  :name,
1245
+ :namespace,
1156
1246
  :unit_label,
1157
1247
  :value_key)
1158
1248
  SENSITIVE = []
@@ -52,6 +52,6 @@ require_relative 'aws-sdk-cloudwatchrum/customizations'
52
52
  # @!group service
53
53
  module Aws::CloudWatchRUM
54
54
 
55
- GEM_VERSION = '1.8.0'
55
+ GEM_VERSION = '1.9.0'
56
56
 
57
57
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-cloudwatchrum
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.8.0
4
+ version: 1.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-01-18 00:00:00.000000000 Z
11
+ date: 2023-02-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core