aws-sdk-cloudwatchlogs 1.54.0 → 1.55.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a121086ebba8952e1000909754fa353f0302e3953ae1a62e70981c9b0ab5a312
4
- data.tar.gz: 2cfb07e97fa321507bddc66bc2ddbfa30577592beb6c9cf0df400cea992b72c3
3
+ metadata.gz: 32dd7b2068c2e7708061290672e92dd27eaf07b805ca1458c90eadda8f0f8ea2
4
+ data.tar.gz: cf817ef3a444a11c28d29af3da24f1b1b087c7737358048448d3fa658fced57b
5
5
  SHA512:
6
- metadata.gz: b2904447ccf2381c5e2795f04ed6609fa7cb93941a379e7de04ede14d3b583af44cd9d8e18b4429d3cec9c743bd78fd05a4f927e8d09b6de0c8693a5519315f5
7
- data.tar.gz: a5c495e8a783dae1e0b8ecfb0b30ea39f0f20fd78c754e340f2172603266771a01adc740d733b9a76bcd7630a2c97f632effeefc0b9066b229eada61cd37f1cd
6
+ metadata.gz: 5773ff63b78873baff73be81171dbc795f05edceffd87b8955211c2fe30ff0f81da30d1a87d356f573222adcd742bb453225f011f89347c13533bd855a4927d5
7
+ data.tar.gz: 28c6bf63de8f08a561aa9f9b8031462549687b47b41fc2c3b9cfc9486103a9ed91bfa23459d0089b1d88e38b6b32a96cf465a0fa675a67195ccb70d2564c7564
data/CHANGELOG.md CHANGED
@@ -1,6 +1,11 @@
1
1
  Unreleased Changes
2
2
  ------------------
3
3
 
4
+ 1.55.0 (2022-10-31)
5
+ ------------------
6
+
7
+ * Feature - SDK release to support tagging for destinations and log groups with TagResource. Also supports tag on create with PutDestination.
8
+
4
9
  1.54.0 (2022-10-25)
5
10
  ------------------
6
11
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.54.0
1
+ 1.55.0
@@ -464,12 +464,6 @@ module Aws::CloudWatchLogs
464
464
  # permission to write to the S3 bucket that you specify as the
465
465
  # destination.
466
466
  #
467
- # Exporting log data to Amazon S3 buckets that are encrypted by KMS is
468
- # not supported. Exporting log data to Amazon S3 buckets that have S3
469
- # Object Lock enabled with a retention period is not supported.
470
- #
471
- # Exporting to S3 buckets that are encrypted with AES-256 is supported.
472
- #
473
467
  # This is an asynchronous call. If all the required information is
474
468
  # provided, this operation initiates an export task and responds with
475
469
  # the ID of the task. After the task has started, you can use
@@ -482,11 +476,8 @@ module Aws::CloudWatchLogs
482
476
  # you can specify a prefix to be used as the Amazon S3 key prefix for
483
477
  # all exported objects.
484
478
  #
485
- # <note markdown="1"> Time-based sorting on chunks of log data inside an exported file is
486
- # not guaranteed. You can sort the exported log fild data by using Linux
487
- # utilities.
488
- #
489
- # </note>
479
+ # Exporting to S3 buckets that are encrypted with AES-256 is supported.
480
+ # Exporting to S3 buckets encrypted with SSE-KMS is not supported.
490
481
  #
491
482
  #
492
483
  #
@@ -1793,8 +1784,58 @@ module Aws::CloudWatchLogs
1793
1784
  req.send_request(options)
1794
1785
  end
1795
1786
 
1787
+ # Displays the tags associated with a CloudWatch Logs resource.
1788
+ # Currently, log groups and destinations support tagging.
1789
+ #
1790
+ # @option params [required, String] :resource_arn
1791
+ # The ARN of the resource that you want to view tags for.
1792
+ #
1793
+ # The ARN format of a log group is
1794
+ # `arn:aws:logs:Region:account-id:log-group:log-group-name `
1795
+ #
1796
+ # The ARN format of a destination is
1797
+ # `arn:aws:logs:Region:account-id:destination:destination-name `
1798
+ #
1799
+ # For more information about ARN format, see [CloudWatch Logs resources
1800
+ # and operations][1].
1801
+ #
1802
+ #
1803
+ #
1804
+ # [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html
1805
+ #
1806
+ # @return [Types::ListTagsForResourceResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
1807
+ #
1808
+ # * {Types::ListTagsForResourceResponse#tags #tags} => Hash&lt;String,String&gt;
1809
+ #
1810
+ # @example Request syntax with placeholder values
1811
+ #
1812
+ # resp = client.list_tags_for_resource({
1813
+ # resource_arn: "AmazonResourceName", # required
1814
+ # })
1815
+ #
1816
+ # @example Response structure
1817
+ #
1818
+ # resp.tags #=> Hash
1819
+ # resp.tags["TagKey"] #=> String
1820
+ #
1821
+ # @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/ListTagsForResource AWS API Documentation
1822
+ #
1823
+ # @overload list_tags_for_resource(params = {})
1824
+ # @param [Hash] params ({})
1825
+ def list_tags_for_resource(params = {}, options = {})
1826
+ req = build_request(:list_tags_for_resource, params)
1827
+ req.send_request(options)
1828
+ end
1829
+
1830
+ # The ListTagsLogGroup operation is on the path to deprecation. We
1831
+ # recommend that you use [ListTagsForResource][1] instead.
1832
+ #
1796
1833
  # Lists the tags for the specified log group.
1797
1834
  #
1835
+ #
1836
+ #
1837
+ # [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListTagsForResource.html
1838
+ #
1798
1839
  # @option params [required, String] :log_group_name
1799
1840
  # The name of the log group.
1800
1841
  #
@@ -1856,6 +1897,16 @@ module Aws::CloudWatchLogs
1856
1897
  # The ARN of an IAM role that grants CloudWatch Logs permissions to call
1857
1898
  # the Amazon Kinesis `PutRecord` operation on the destination stream.
1858
1899
  #
1900
+ # @option params [Hash<String,String>] :tags
1901
+ # An optional list of key-value pairs to associate with the resource.
1902
+ #
1903
+ # For more information about tagging, see [Tagging Amazon Web Services
1904
+ # resources][1]
1905
+ #
1906
+ #
1907
+ #
1908
+ # [1]: https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html
1909
+ #
1859
1910
  # @return [Types::PutDestinationResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
1860
1911
  #
1861
1912
  # * {Types::PutDestinationResponse#destination #destination} => Types::Destination
@@ -1866,6 +1917,9 @@ module Aws::CloudWatchLogs
1866
1917
  # destination_name: "DestinationName", # required
1867
1918
  # target_arn: "TargetArn", # required
1868
1919
  # role_arn: "RoleArn", # required
1920
+ # tags: {
1921
+ # "TagKey" => "TagValue",
1922
+ # },
1869
1923
  # })
1870
1924
  #
1871
1925
  # @example Response structure
@@ -2277,7 +2331,7 @@ module Aws::CloudWatchLogs
2277
2331
  # @option params [required, Integer] :retention_in_days
2278
2332
  # The number of days to retain the log events in the specified log
2279
2333
  # group. Possible values are: 1, 3, 5, 7, 14, 30, 60, 90, 120, 150, 180,
2280
- # 365, 400, 545, 731, 1827, 2192, 2557, 2922, 3288, and 3653.
2334
+ # 365, 400, 545, 731, 1827, and 3653.
2281
2335
  #
2282
2336
  # To set a log group to never have log events expire, use
2283
2337
  # [DeleteRetentionPolicy][1].
@@ -2520,26 +2574,30 @@ module Aws::CloudWatchLogs
2520
2574
  req.send_request(options)
2521
2575
  end
2522
2576
 
2577
+ # The TagLogGroup operation is on the path to deprecation. We recommend
2578
+ # that you use [TagResource][1] instead.
2579
+ #
2523
2580
  # Adds or updates the specified tags for the specified log group.
2524
2581
  #
2525
- # To list the tags for a log group, use [ListTagsLogGroup][1]. To remove
2526
- # tags, use [UntagLogGroup][2].
2582
+ # To list the tags for a log group, use [ListTagsForResource][2]. To
2583
+ # remove tags, use [UntagResource][3].
2527
2584
  #
2528
2585
  # For more information about tags, see [Tag Log Groups in Amazon
2529
- # CloudWatch Logs][3] in the *Amazon CloudWatch Logs User Guide*.
2586
+ # CloudWatch Logs][4] in the *Amazon CloudWatch Logs User Guide*.
2530
2587
  #
2531
2588
  # CloudWatch Logs doesn’t support IAM policies that prevent users from
2532
2589
  # assigning specified tags to log groups using the
2533
2590
  # `aws:Resource/key-name ` or `aws:TagKeys` condition keys. For more
2534
2591
  # information about using tags to control access, see [Controlling
2535
- # access to Amazon Web Services resources using tags][4].
2592
+ # access to Amazon Web Services resources using tags][5].
2536
2593
  #
2537
2594
  #
2538
2595
  #
2539
- # [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListTagsLogGroup.html
2540
- # [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_UntagLogGroup.html
2541
- # [3]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/Working-with-log-groups-and-streams.html#log-group-tagging
2542
- # [4]: https://docs.aws.amazon.com/IAM/latest/UserGuide/access_tags.html
2596
+ # [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_TagResource.html
2597
+ # [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListTagsForResource.html
2598
+ # [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_UntagResource.html
2599
+ # [4]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/Working-with-log-groups-and-streams.html#log-group-tagging
2600
+ # [5]: https://docs.aws.amazon.com/IAM/latest/UserGuide/access_tags.html
2543
2601
  #
2544
2602
  # @option params [required, String] :log_group_name
2545
2603
  # The name of the log group.
@@ -2567,6 +2625,64 @@ module Aws::CloudWatchLogs
2567
2625
  req.send_request(options)
2568
2626
  end
2569
2627
 
2628
+ # Assigns one or more tags (key-value pairs) to the specified CloudWatch
2629
+ # Logs resource. Currently, the only CloudWatch Logs resources that can
2630
+ # be tagged are log groups and destinations.
2631
+ #
2632
+ # Tags can help you organize and categorize your resources. You can also
2633
+ # use them to scope user permissions by granting a user permission to
2634
+ # access or change only resources with certain tag values.
2635
+ #
2636
+ # Tags don't have any semantic meaning to Amazon Web Services and are
2637
+ # interpreted strictly as strings of characters.
2638
+ #
2639
+ # You can use the `TagResource` action with a resource that already has
2640
+ # tags. If you specify a new tag key for the alarm, this tag is appended
2641
+ # to the list of tags associated with the alarm. If you specify a tag
2642
+ # key that is already associated with the alarm, the new tag value that
2643
+ # you specify replaces the previous value for that tag.
2644
+ #
2645
+ # You can associate as many as 50 tags with a CloudWatch Logs resource.
2646
+ #
2647
+ # @option params [required, String] :resource_arn
2648
+ # The ARN of the resource that you're adding tags to.
2649
+ #
2650
+ # The ARN format of a log group is
2651
+ # `arn:aws:logs:Region:account-id:log-group:log-group-name `
2652
+ #
2653
+ # The ARN format of a destination is
2654
+ # `arn:aws:logs:Region:account-id:destination:destination-name `
2655
+ #
2656
+ # For more information about ARN format, see [CloudWatch Logs resources
2657
+ # and operations][1].
2658
+ #
2659
+ #
2660
+ #
2661
+ # [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html
2662
+ #
2663
+ # @option params [required, Hash<String,String>] :tags
2664
+ # The list of key-value pairs to associate with the resource.
2665
+ #
2666
+ # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
2667
+ #
2668
+ # @example Request syntax with placeholder values
2669
+ #
2670
+ # resp = client.tag_resource({
2671
+ # resource_arn: "AmazonResourceName", # required
2672
+ # tags: { # required
2673
+ # "TagKey" => "TagValue",
2674
+ # },
2675
+ # })
2676
+ #
2677
+ # @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/TagResource AWS API Documentation
2678
+ #
2679
+ # @overload tag_resource(params = {})
2680
+ # @param [Hash] params ({})
2681
+ def tag_resource(params = {}, options = {})
2682
+ req = build_request(:tag_resource, params)
2683
+ req.send_request(options)
2684
+ end
2685
+
2570
2686
  # Tests the filter pattern of a metric filter against a sample of log
2571
2687
  # event messages. You can use this operation to validate the correctness
2572
2688
  # of a metric filter pattern.
@@ -2608,10 +2724,13 @@ module Aws::CloudWatchLogs
2608
2724
  req.send_request(options)
2609
2725
  end
2610
2726
 
2727
+ # The UntagLogGroup operation is on the path to deprecation. We
2728
+ # recommend that you use [UntagResource][1] instead.
2729
+ #
2611
2730
  # Removes the specified tags from the specified log group.
2612
2731
  #
2613
- # To list the tags for a log group, use [ListTagsLogGroup][1]. To add
2614
- # tags, use [TagLogGroup][2].
2732
+ # To list the tags for a log group, use [ListTagsForResource][2]. To add
2733
+ # tags, use [TagResource][3].
2615
2734
  #
2616
2735
  # CloudWatch Logs doesn’t support IAM policies that prevent users from
2617
2736
  # assigning specified tags to log groups using the
@@ -2619,8 +2738,9 @@ module Aws::CloudWatchLogs
2619
2738
  #
2620
2739
  #
2621
2740
  #
2622
- # [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListTagsLogGroup.html
2623
- # [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_TagLogGroup.html
2741
+ # [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_UntagResource.html
2742
+ # [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListTagsForResource.html
2743
+ # [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_TagResource.html
2624
2744
  #
2625
2745
  # @option params [required, String] :log_group_name
2626
2746
  # The name of the log group.
@@ -2646,6 +2766,46 @@ module Aws::CloudWatchLogs
2646
2766
  req.send_request(options)
2647
2767
  end
2648
2768
 
2769
+ # Removes one or more tags from the specified resource.
2770
+ #
2771
+ # @option params [required, String] :resource_arn
2772
+ # The ARN of the CloudWatch Logs resource that you're removing tags
2773
+ # from.
2774
+ #
2775
+ # The ARN format of a log group is
2776
+ # `arn:aws:logs:Region:account-id:log-group:log-group-name `
2777
+ #
2778
+ # The ARN format of a destination is
2779
+ # `arn:aws:logs:Region:account-id:destination:destination-name `
2780
+ #
2781
+ # For more information about ARN format, see [CloudWatch Logs resources
2782
+ # and operations][1].
2783
+ #
2784
+ #
2785
+ #
2786
+ # [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html
2787
+ #
2788
+ # @option params [required, Array<String>] :tag_keys
2789
+ # The list of tag keys to remove from the resource.
2790
+ #
2791
+ # @return [Struct] Returns an empty {Seahorse::Client::Response response}.
2792
+ #
2793
+ # @example Request syntax with placeholder values
2794
+ #
2795
+ # resp = client.untag_resource({
2796
+ # resource_arn: "AmazonResourceName", # required
2797
+ # tag_keys: ["TagKey"], # required
2798
+ # })
2799
+ #
2800
+ # @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/UntagResource AWS API Documentation
2801
+ #
2802
+ # @overload untag_resource(params = {})
2803
+ # @param [Hash] params ({})
2804
+ def untag_resource(params = {}, options = {})
2805
+ req = build_request(:untag_resource, params)
2806
+ req.send_request(options)
2807
+ end
2808
+
2649
2809
  # @!endgroup
2650
2810
 
2651
2811
  # @param params ({})
@@ -2659,7 +2819,7 @@ module Aws::CloudWatchLogs
2659
2819
  params: params,
2660
2820
  config: config)
2661
2821
  context[:gem_name] = 'aws-sdk-cloudwatchlogs'
2662
- context[:gem_version] = '1.54.0'
2822
+ context[:gem_version] = '1.55.0'
2663
2823
  Seahorse::Client::Request.new(handlers, context)
2664
2824
  end
2665
2825
 
@@ -14,6 +14,7 @@ module Aws::CloudWatchLogs
14
14
  include Seahorse::Model
15
15
 
16
16
  AccessPolicy = Shapes::StringShape.new(name: 'AccessPolicy')
17
+ AmazonResourceName = Shapes::StringShape.new(name: 'AmazonResourceName')
17
18
  Arn = Shapes::StringShape.new(name: 'Arn')
18
19
  AssociateKmsKeyRequest = Shapes::StructureShape.new(name: 'AssociateKmsKeyRequest')
19
20
  CancelExportTaskRequest = Shapes::StructureShape.new(name: 'CancelExportTaskRequest')
@@ -104,6 +105,8 @@ module Aws::CloudWatchLogs
104
105
  InvalidSequenceTokenException = Shapes::StructureShape.new(name: 'InvalidSequenceTokenException')
105
106
  KmsKeyId = Shapes::StringShape.new(name: 'KmsKeyId')
106
107
  LimitExceededException = Shapes::StructureShape.new(name: 'LimitExceededException')
108
+ ListTagsForResourceRequest = Shapes::StructureShape.new(name: 'ListTagsForResourceRequest')
109
+ ListTagsForResourceResponse = Shapes::StructureShape.new(name: 'ListTagsForResourceResponse')
107
110
  ListTagsLogGroupRequest = Shapes::StructureShape.new(name: 'ListTagsLogGroupRequest')
108
111
  ListTagsLogGroupResponse = Shapes::StructureShape.new(name: 'ListTagsLogGroupResponse')
109
112
  LogEventIndex = Shapes::IntegerShape.new(name: 'LogEventIndex')
@@ -189,8 +192,10 @@ module Aws::CloudWatchLogs
189
192
  SubscriptionFilters = Shapes::ListShape.new(name: 'SubscriptionFilters')
190
193
  Success = Shapes::BooleanShape.new(name: 'Success')
191
194
  TagKey = Shapes::StringShape.new(name: 'TagKey')
195
+ TagKeyList = Shapes::ListShape.new(name: 'TagKeyList')
192
196
  TagList = Shapes::ListShape.new(name: 'TagList')
193
197
  TagLogGroupRequest = Shapes::StructureShape.new(name: 'TagLogGroupRequest')
198
+ TagResourceRequest = Shapes::StructureShape.new(name: 'TagResourceRequest')
194
199
  TagValue = Shapes::StringShape.new(name: 'TagValue')
195
200
  Tags = Shapes::MapShape.new(name: 'Tags')
196
201
  TargetArn = Shapes::StringShape.new(name: 'TargetArn')
@@ -199,8 +204,10 @@ module Aws::CloudWatchLogs
199
204
  TestMetricFilterResponse = Shapes::StructureShape.new(name: 'TestMetricFilterResponse')
200
205
  Timestamp = Shapes::IntegerShape.new(name: 'Timestamp')
201
206
  Token = Shapes::StringShape.new(name: 'Token')
207
+ TooManyTagsException = Shapes::StructureShape.new(name: 'TooManyTagsException')
202
208
  UnrecognizedClientException = Shapes::StructureShape.new(name: 'UnrecognizedClientException')
203
209
  UntagLogGroupRequest = Shapes::StructureShape.new(name: 'UntagLogGroupRequest')
210
+ UntagResourceRequest = Shapes::StructureShape.new(name: 'UntagResourceRequest')
204
211
  Value = Shapes::StringShape.new(name: 'Value')
205
212
 
206
213
  AssociateKmsKeyRequest.add_member(:log_group_name, Shapes::ShapeRef.new(shape: LogGroupName, required: true, location_name: "logGroupName"))
@@ -470,6 +477,12 @@ module Aws::CloudWatchLogs
470
477
 
471
478
  LimitExceededException.struct_class = Types::LimitExceededException
472
479
 
480
+ ListTagsForResourceRequest.add_member(:resource_arn, Shapes::ShapeRef.new(shape: AmazonResourceName, required: true, location_name: "resourceArn"))
481
+ ListTagsForResourceRequest.struct_class = Types::ListTagsForResourceRequest
482
+
483
+ ListTagsForResourceResponse.add_member(:tags, Shapes::ShapeRef.new(shape: Tags, location_name: "tags"))
484
+ ListTagsForResourceResponse.struct_class = Types::ListTagsForResourceResponse
485
+
473
486
  ListTagsLogGroupRequest.add_member(:log_group_name, Shapes::ShapeRef.new(shape: LogGroupName, required: true, location_name: "logGroupName"))
474
487
  ListTagsLogGroupRequest.struct_class = Types::ListTagsLogGroupRequest
475
488
 
@@ -556,6 +569,7 @@ module Aws::CloudWatchLogs
556
569
  PutDestinationRequest.add_member(:destination_name, Shapes::ShapeRef.new(shape: DestinationName, required: true, location_name: "destinationName"))
557
570
  PutDestinationRequest.add_member(:target_arn, Shapes::ShapeRef.new(shape: TargetArn, required: true, location_name: "targetArn"))
558
571
  PutDestinationRequest.add_member(:role_arn, Shapes::ShapeRef.new(shape: RoleArn, required: true, location_name: "roleArn"))
572
+ PutDestinationRequest.add_member(:tags, Shapes::ShapeRef.new(shape: Tags, location_name: "tags"))
559
573
  PutDestinationRequest.struct_class = Types::PutDestinationRequest
560
574
 
561
575
  PutDestinationResponse.add_member(:destination, Shapes::ShapeRef.new(shape: Destination, location_name: "destination"))
@@ -696,12 +710,18 @@ module Aws::CloudWatchLogs
696
710
 
697
711
  SubscriptionFilters.member = Shapes::ShapeRef.new(shape: SubscriptionFilter)
698
712
 
713
+ TagKeyList.member = Shapes::ShapeRef.new(shape: TagKey)
714
+
699
715
  TagList.member = Shapes::ShapeRef.new(shape: TagKey)
700
716
 
701
717
  TagLogGroupRequest.add_member(:log_group_name, Shapes::ShapeRef.new(shape: LogGroupName, required: true, location_name: "logGroupName"))
702
718
  TagLogGroupRequest.add_member(:tags, Shapes::ShapeRef.new(shape: Tags, required: true, location_name: "tags"))
703
719
  TagLogGroupRequest.struct_class = Types::TagLogGroupRequest
704
720
 
721
+ TagResourceRequest.add_member(:resource_arn, Shapes::ShapeRef.new(shape: AmazonResourceName, required: true, location_name: "resourceArn"))
722
+ TagResourceRequest.add_member(:tags, Shapes::ShapeRef.new(shape: Tags, required: true, location_name: "tags"))
723
+ TagResourceRequest.struct_class = Types::TagResourceRequest
724
+
705
725
  Tags.key = Shapes::ShapeRef.new(shape: TagKey)
706
726
  Tags.value = Shapes::ShapeRef.new(shape: TagValue)
707
727
 
@@ -714,12 +734,20 @@ module Aws::CloudWatchLogs
714
734
  TestMetricFilterResponse.add_member(:matches, Shapes::ShapeRef.new(shape: MetricFilterMatches, location_name: "matches"))
715
735
  TestMetricFilterResponse.struct_class = Types::TestMetricFilterResponse
716
736
 
737
+ TooManyTagsException.add_member(:message, Shapes::ShapeRef.new(shape: Message, location_name: "message"))
738
+ TooManyTagsException.add_member(:resource_name, Shapes::ShapeRef.new(shape: AmazonResourceName, location_name: "resourceName"))
739
+ TooManyTagsException.struct_class = Types::TooManyTagsException
740
+
717
741
  UnrecognizedClientException.struct_class = Types::UnrecognizedClientException
718
742
 
719
743
  UntagLogGroupRequest.add_member(:log_group_name, Shapes::ShapeRef.new(shape: LogGroupName, required: true, location_name: "logGroupName"))
720
744
  UntagLogGroupRequest.add_member(:tags, Shapes::ShapeRef.new(shape: TagList, required: true, location_name: "tags"))
721
745
  UntagLogGroupRequest.struct_class = Types::UntagLogGroupRequest
722
746
 
747
+ UntagResourceRequest.add_member(:resource_arn, Shapes::ShapeRef.new(shape: AmazonResourceName, required: true, location_name: "resourceArn"))
748
+ UntagResourceRequest.add_member(:tag_keys, Shapes::ShapeRef.new(shape: TagKeyList, required: true, location_name: "tagKeys"))
749
+ UntagResourceRequest.struct_class = Types::UntagResourceRequest
750
+
723
751
 
724
752
  # @api private
725
753
  API = Seahorse::Model::Api.new.tap do |api|
@@ -1100,10 +1128,22 @@ module Aws::CloudWatchLogs
1100
1128
  o.errors << Shapes::ShapeRef.new(shape: ServiceUnavailableException)
1101
1129
  end)
1102
1130
 
1131
+ api.add_operation(:list_tags_for_resource, Seahorse::Model::Operation.new.tap do |o|
1132
+ o.name = "ListTagsForResource"
1133
+ o.http_method = "POST"
1134
+ o.http_request_uri = "/"
1135
+ o.input = Shapes::ShapeRef.new(shape: ListTagsForResourceRequest)
1136
+ o.output = Shapes::ShapeRef.new(shape: ListTagsForResourceResponse)
1137
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
1138
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
1139
+ o.errors << Shapes::ShapeRef.new(shape: ServiceUnavailableException)
1140
+ end)
1141
+
1103
1142
  api.add_operation(:list_tags_log_group, Seahorse::Model::Operation.new.tap do |o|
1104
1143
  o.name = "ListTagsLogGroup"
1105
1144
  o.http_method = "POST"
1106
1145
  o.http_request_uri = "/"
1146
+ o.deprecated = true
1107
1147
  o.input = Shapes::ShapeRef.new(shape: ListTagsLogGroupRequest)
1108
1148
  o.output = Shapes::ShapeRef.new(shape: ListTagsLogGroupResponse)
1109
1149
  o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
@@ -1235,12 +1275,25 @@ module Aws::CloudWatchLogs
1235
1275
  o.name = "TagLogGroup"
1236
1276
  o.http_method = "POST"
1237
1277
  o.http_request_uri = "/"
1278
+ o.deprecated = true
1238
1279
  o.input = Shapes::ShapeRef.new(shape: TagLogGroupRequest)
1239
1280
  o.output = Shapes::ShapeRef.new(shape: Shapes::StructureShape.new(struct_class: Aws::EmptyStructure))
1240
1281
  o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
1241
1282
  o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
1242
1283
  end)
1243
1284
 
1285
+ api.add_operation(:tag_resource, Seahorse::Model::Operation.new.tap do |o|
1286
+ o.name = "TagResource"
1287
+ o.http_method = "POST"
1288
+ o.http_request_uri = "/"
1289
+ o.input = Shapes::ShapeRef.new(shape: TagResourceRequest)
1290
+ o.output = Shapes::ShapeRef.new(shape: Shapes::StructureShape.new(struct_class: Aws::EmptyStructure))
1291
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
1292
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
1293
+ o.errors << Shapes::ShapeRef.new(shape: ServiceUnavailableException)
1294
+ o.errors << Shapes::ShapeRef.new(shape: TooManyTagsException)
1295
+ end)
1296
+
1244
1297
  api.add_operation(:test_metric_filter, Seahorse::Model::Operation.new.tap do |o|
1245
1298
  o.name = "TestMetricFilter"
1246
1299
  o.http_method = "POST"
@@ -1255,10 +1308,22 @@ module Aws::CloudWatchLogs
1255
1308
  o.name = "UntagLogGroup"
1256
1309
  o.http_method = "POST"
1257
1310
  o.http_request_uri = "/"
1311
+ o.deprecated = true
1258
1312
  o.input = Shapes::ShapeRef.new(shape: UntagLogGroupRequest)
1259
1313
  o.output = Shapes::ShapeRef.new(shape: Shapes::StructureShape.new(struct_class: Aws::EmptyStructure))
1260
1314
  o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
1261
1315
  end)
1316
+
1317
+ api.add_operation(:untag_resource, Seahorse::Model::Operation.new.tap do |o|
1318
+ o.name = "UntagResource"
1319
+ o.http_method = "POST"
1320
+ o.http_request_uri = "/"
1321
+ o.input = Shapes::ShapeRef.new(shape: UntagResourceRequest)
1322
+ o.output = Shapes::ShapeRef.new(shape: Shapes::StructureShape.new(struct_class: Aws::EmptyStructure))
1323
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
1324
+ o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
1325
+ o.errors << Shapes::ShapeRef.new(shape: ServiceUnavailableException)
1326
+ end)
1262
1327
  end
1263
1328
 
1264
1329
  end
@@ -403,6 +403,20 @@ module Aws::CloudWatchLogs
403
403
  end
404
404
  end
405
405
 
406
+ class ListTagsForResource
407
+ def self.build(context)
408
+ unless context.config.regional_endpoint
409
+ endpoint = context.config.endpoint.to_s
410
+ end
411
+ Aws::CloudWatchLogs::EndpointParameters.new(
412
+ region: context.config.region,
413
+ use_dual_stack: context.config.use_dualstack_endpoint,
414
+ use_fips: context.config.use_fips_endpoint,
415
+ endpoint: endpoint,
416
+ )
417
+ end
418
+ end
419
+
406
420
  class ListTagsLogGroup
407
421
  def self.build(context)
408
422
  unless context.config.regional_endpoint
@@ -571,6 +585,20 @@ module Aws::CloudWatchLogs
571
585
  end
572
586
  end
573
587
 
588
+ class TagResource
589
+ def self.build(context)
590
+ unless context.config.regional_endpoint
591
+ endpoint = context.config.endpoint.to_s
592
+ end
593
+ Aws::CloudWatchLogs::EndpointParameters.new(
594
+ region: context.config.region,
595
+ use_dual_stack: context.config.use_dualstack_endpoint,
596
+ use_fips: context.config.use_fips_endpoint,
597
+ endpoint: endpoint,
598
+ )
599
+ end
600
+ end
601
+
574
602
  class TestMetricFilter
575
603
  def self.build(context)
576
604
  unless context.config.regional_endpoint
@@ -599,5 +627,19 @@ module Aws::CloudWatchLogs
599
627
  end
600
628
  end
601
629
 
630
+ class UntagResource
631
+ def self.build(context)
632
+ unless context.config.regional_endpoint
633
+ endpoint = context.config.endpoint.to_s
634
+ end
635
+ Aws::CloudWatchLogs::EndpointParameters.new(
636
+ region: context.config.region,
637
+ use_dual_stack: context.config.use_dualstack_endpoint,
638
+ use_fips: context.config.use_fips_endpoint,
639
+ endpoint: endpoint,
640
+ )
641
+ end
642
+ end
643
+
602
644
  end
603
645
  end
@@ -37,6 +37,7 @@ module Aws::CloudWatchLogs
37
37
  # * {ResourceAlreadyExistsException}
38
38
  # * {ResourceNotFoundException}
39
39
  # * {ServiceUnavailableException}
40
+ # * {TooManyTagsException}
40
41
  # * {UnrecognizedClientException}
41
42
  #
42
43
  # Additionally, error classes are dynamically generated for service errors based on the error code
@@ -160,6 +161,26 @@ module Aws::CloudWatchLogs
160
161
  end
161
162
  end
162
163
 
164
+ class TooManyTagsException < ServiceError
165
+
166
+ # @param [Seahorse::Client::RequestContext] context
167
+ # @param [String] message
168
+ # @param [Aws::CloudWatchLogs::Types::TooManyTagsException] data
169
+ def initialize(context, message, data = Aws::EmptyStructure.new)
170
+ super(context, message, data)
171
+ end
172
+
173
+ # @return [String]
174
+ def message
175
+ @message || @data[:message]
176
+ end
177
+
178
+ # @return [String]
179
+ def resource_name
180
+ @data[:resource_name]
181
+ end
182
+ end
183
+
163
184
  class UnrecognizedClientException < ServiceError
164
185
 
165
186
  # @param [Seahorse::Client::RequestContext] context
@@ -112,6 +112,8 @@ module Aws::CloudWatchLogs
112
112
  Aws::CloudWatchLogs::Endpoints::GetLogRecord.build(context)
113
113
  when :get_query_results
114
114
  Aws::CloudWatchLogs::Endpoints::GetQueryResults.build(context)
115
+ when :list_tags_for_resource
116
+ Aws::CloudWatchLogs::Endpoints::ListTagsForResource.build(context)
115
117
  when :list_tags_log_group
116
118
  Aws::CloudWatchLogs::Endpoints::ListTagsLogGroup.build(context)
117
119
  when :put_destination
@@ -136,10 +138,14 @@ module Aws::CloudWatchLogs
136
138
  Aws::CloudWatchLogs::Endpoints::StopQuery.build(context)
137
139
  when :tag_log_group
138
140
  Aws::CloudWatchLogs::Endpoints::TagLogGroup.build(context)
141
+ when :tag_resource
142
+ Aws::CloudWatchLogs::Endpoints::TagResource.build(context)
139
143
  when :test_metric_filter
140
144
  Aws::CloudWatchLogs::Endpoints::TestMetricFilter.build(context)
141
145
  when :untag_log_group
142
146
  Aws::CloudWatchLogs::Endpoints::UntagLogGroup.build(context)
147
+ when :untag_resource
148
+ Aws::CloudWatchLogs::Endpoints::UntagResource.build(context)
143
149
  end
144
150
  end
145
151
  end
@@ -1569,6 +1569,50 @@ module Aws::CloudWatchLogs
1569
1569
  #
1570
1570
  class LimitExceededException < Aws::EmptyStructure; end
1571
1571
 
1572
+ # @note When making an API call, you may pass ListTagsForResourceRequest
1573
+ # data as a hash:
1574
+ #
1575
+ # {
1576
+ # resource_arn: "AmazonResourceName", # required
1577
+ # }
1578
+ #
1579
+ # @!attribute [rw] resource_arn
1580
+ # The ARN of the resource that you want to view tags for.
1581
+ #
1582
+ # The ARN format of a log group is
1583
+ # `arn:aws:logs:Region:account-id:log-group:log-group-name `
1584
+ #
1585
+ # The ARN format of a destination is
1586
+ # `arn:aws:logs:Region:account-id:destination:destination-name `
1587
+ #
1588
+ # For more information about ARN format, see [CloudWatch Logs
1589
+ # resources and operations][1].
1590
+ #
1591
+ #
1592
+ #
1593
+ # [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html
1594
+ # @return [String]
1595
+ #
1596
+ # @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/ListTagsForResourceRequest AWS API Documentation
1597
+ #
1598
+ class ListTagsForResourceRequest < Struct.new(
1599
+ :resource_arn)
1600
+ SENSITIVE = []
1601
+ include Aws::Structure
1602
+ end
1603
+
1604
+ # @!attribute [rw] tags
1605
+ # The list of tags associated with the requested resource.&gt;
1606
+ # @return [Hash<String,String>]
1607
+ #
1608
+ # @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/ListTagsForResourceResponse AWS API Documentation
1609
+ #
1610
+ class ListTagsForResourceResponse < Struct.new(
1611
+ :tags)
1612
+ SENSITIVE = []
1613
+ include Aws::Structure
1614
+ end
1615
+
1572
1616
  # @note When making an API call, you may pass ListTagsLogGroupRequest
1573
1617
  # data as a hash:
1574
1618
  #
@@ -1614,7 +1658,7 @@ module Aws::CloudWatchLogs
1614
1658
  # @!attribute [rw] retention_in_days
1615
1659
  # The number of days to retain the log events in the specified log
1616
1660
  # group. Possible values are: 1, 3, 5, 7, 14, 30, 60, 90, 120, 150,
1617
- # 180, 365, 400, 545, 731, 1827, 2192, 2557, 2922, 3288, and 3653.
1661
+ # 180, 365, 400, 545, 731, 1827, and 3653.
1618
1662
  #
1619
1663
  # To set a log group to never have log events expire, use
1620
1664
  # [DeleteRetentionPolicy][1].
@@ -1997,6 +2041,9 @@ module Aws::CloudWatchLogs
1997
2041
  # destination_name: "DestinationName", # required
1998
2042
  # target_arn: "TargetArn", # required
1999
2043
  # role_arn: "RoleArn", # required
2044
+ # tags: {
2045
+ # "TagKey" => "TagValue",
2046
+ # },
2000
2047
  # }
2001
2048
  #
2002
2049
  # @!attribute [rw] destination_name
@@ -2014,12 +2061,24 @@ module Aws::CloudWatchLogs
2014
2061
  # stream.
2015
2062
  # @return [String]
2016
2063
  #
2064
+ # @!attribute [rw] tags
2065
+ # An optional list of key-value pairs to associate with the resource.
2066
+ #
2067
+ # For more information about tagging, see [Tagging Amazon Web Services
2068
+ # resources][1]
2069
+ #
2070
+ #
2071
+ #
2072
+ # [1]: https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html
2073
+ # @return [Hash<String,String>]
2074
+ #
2017
2075
  # @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/PutDestinationRequest AWS API Documentation
2018
2076
  #
2019
2077
  class PutDestinationRequest < Struct.new(
2020
2078
  :destination_name,
2021
2079
  :target_arn,
2022
- :role_arn)
2080
+ :role_arn,
2081
+ :tags)
2023
2082
  SENSITIVE = []
2024
2083
  include Aws::Structure
2025
2084
  end
@@ -2314,7 +2373,7 @@ module Aws::CloudWatchLogs
2314
2373
  # @!attribute [rw] retention_in_days
2315
2374
  # The number of days to retain the log events in the specified log
2316
2375
  # group. Possible values are: 1, 3, 5, 7, 14, 30, 60, 90, 120, 150,
2317
- # 180, 365, 400, 545, 731, 1827, 2192, 2557, 2922, 3288, and 3653.
2376
+ # 180, 365, 400, 545, 731, 1827, and 3653.
2318
2377
  #
2319
2378
  # To set a log group to never have log events expire, use
2320
2379
  # [DeleteRetentionPolicy][1].
@@ -2860,6 +2919,46 @@ module Aws::CloudWatchLogs
2860
2919
  include Aws::Structure
2861
2920
  end
2862
2921
 
2922
+ # @note When making an API call, you may pass TagResourceRequest
2923
+ # data as a hash:
2924
+ #
2925
+ # {
2926
+ # resource_arn: "AmazonResourceName", # required
2927
+ # tags: { # required
2928
+ # "TagKey" => "TagValue",
2929
+ # },
2930
+ # }
2931
+ #
2932
+ # @!attribute [rw] resource_arn
2933
+ # The ARN of the resource that you're adding tags to.
2934
+ #
2935
+ # The ARN format of a log group is
2936
+ # `arn:aws:logs:Region:account-id:log-group:log-group-name `
2937
+ #
2938
+ # The ARN format of a destination is
2939
+ # `arn:aws:logs:Region:account-id:destination:destination-name `
2940
+ #
2941
+ # For more information about ARN format, see [CloudWatch Logs
2942
+ # resources and operations][1].
2943
+ #
2944
+ #
2945
+ #
2946
+ # [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html
2947
+ # @return [String]
2948
+ #
2949
+ # @!attribute [rw] tags
2950
+ # The list of key-value pairs to associate with the resource.
2951
+ # @return [Hash<String,String>]
2952
+ #
2953
+ # @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/TagResourceRequest AWS API Documentation
2954
+ #
2955
+ class TagResourceRequest < Struct.new(
2956
+ :resource_arn,
2957
+ :tags)
2958
+ SENSITIVE = []
2959
+ include Aws::Structure
2960
+ end
2961
+
2863
2962
  # @note When making an API call, you may pass TestMetricFilterRequest
2864
2963
  # data as a hash:
2865
2964
  #
@@ -2900,6 +2999,24 @@ module Aws::CloudWatchLogs
2900
2999
  include Aws::Structure
2901
3000
  end
2902
3001
 
3002
+ # A resource can have no more than 50 tags.
3003
+ #
3004
+ # @!attribute [rw] message
3005
+ # @return [String]
3006
+ #
3007
+ # @!attribute [rw] resource_name
3008
+ # The name of the resource.
3009
+ # @return [String]
3010
+ #
3011
+ # @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/TooManyTagsException AWS API Documentation
3012
+ #
3013
+ class TooManyTagsException < Struct.new(
3014
+ :message,
3015
+ :resource_name)
3016
+ SENSITIVE = []
3017
+ include Aws::Structure
3018
+ end
3019
+
2903
3020
  # The most likely cause is an invalid Amazon Web Services access key ID
2904
3021
  # or secret key.
2905
3022
  #
@@ -2932,5 +3049,44 @@ module Aws::CloudWatchLogs
2932
3049
  include Aws::Structure
2933
3050
  end
2934
3051
 
3052
+ # @note When making an API call, you may pass UntagResourceRequest
3053
+ # data as a hash:
3054
+ #
3055
+ # {
3056
+ # resource_arn: "AmazonResourceName", # required
3057
+ # tag_keys: ["TagKey"], # required
3058
+ # }
3059
+ #
3060
+ # @!attribute [rw] resource_arn
3061
+ # The ARN of the CloudWatch Logs resource that you're removing tags
3062
+ # from.
3063
+ #
3064
+ # The ARN format of a log group is
3065
+ # `arn:aws:logs:Region:account-id:log-group:log-group-name `
3066
+ #
3067
+ # The ARN format of a destination is
3068
+ # `arn:aws:logs:Region:account-id:destination:destination-name `
3069
+ #
3070
+ # For more information about ARN format, see [CloudWatch Logs
3071
+ # resources and operations][1].
3072
+ #
3073
+ #
3074
+ #
3075
+ # [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/iam-access-control-overview-cwl.html
3076
+ # @return [String]
3077
+ #
3078
+ # @!attribute [rw] tag_keys
3079
+ # The list of tag keys to remove from the resource.
3080
+ # @return [Array<String>]
3081
+ #
3082
+ # @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/UntagResourceRequest AWS API Documentation
3083
+ #
3084
+ class UntagResourceRequest < Struct.new(
3085
+ :resource_arn,
3086
+ :tag_keys)
3087
+ SENSITIVE = []
3088
+ include Aws::Structure
3089
+ end
3090
+
2935
3091
  end
2936
3092
  end
@@ -52,6 +52,6 @@ require_relative 'aws-sdk-cloudwatchlogs/customizations'
52
52
  # @!group service
53
53
  module Aws::CloudWatchLogs
54
54
 
55
- GEM_VERSION = '1.54.0'
55
+ GEM_VERSION = '1.55.0'
56
56
 
57
57
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-cloudwatchlogs
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.54.0
4
+ version: 1.55.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: 2022-10-25 00:00:00.000000000 Z
11
+ date: 2022-10-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core