aws-sdk-cloudwatchlogs 1.74.0 → 1.76.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +10 -0
- data/VERSION +1 -1
- data/lib/aws-sdk-cloudwatchlogs/client.rb +300 -7
- data/lib/aws-sdk-cloudwatchlogs/client_api.rb +77 -0
- data/lib/aws-sdk-cloudwatchlogs/endpoints.rb +14 -0
- data/lib/aws-sdk-cloudwatchlogs/errors.rb +32 -0
- data/lib/aws-sdk-cloudwatchlogs/event_streams.rb +64 -0
- data/lib/aws-sdk-cloudwatchlogs/plugins/endpoints.rb +5 -2
- data/lib/aws-sdk-cloudwatchlogs/types.rb +281 -4
- data/lib/aws-sdk-cloudwatchlogs.rb +2 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3d0d35998ca54f9a04a515684b803b4a7b890de6f9bd8d19ea12c5ca4114abd3
|
4
|
+
data.tar.gz: 78c8699b98c8cb435696411e647ccd528226bc2983ee99806af1f541f2546a8e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7dfa1468403bcf30e534f03de7d6dc9025f3c8d36bc659f6d6d93a379f5695161fa823600020ed39883b53798ec57b9ed1d40e7952d0290fbf1e24b990c2f645
|
7
|
+
data.tar.gz: e7af85674f396f0bd7df7e982daf910e1844361cfe1f560e5f4b66328fe493e298281427a062c906ab51db6a3f0172065aca665fecf18382b7eea395e2f8e277
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,16 @@
|
|
1
1
|
Unreleased Changes
|
2
2
|
------------------
|
3
3
|
|
4
|
+
1.76.0 (2023-12-12)
|
5
|
+
------------------
|
6
|
+
|
7
|
+
* Feature - This release introduces the StartLiveTail API to tail ingested logs in near real time.
|
8
|
+
|
9
|
+
1.75.0 (2023-11-28)
|
10
|
+
------------------
|
11
|
+
|
12
|
+
* Feature - Code Generated Changes, see `./build_tools` or `aws-sdk-core`'s CHANGELOG.md for details.
|
13
|
+
|
4
14
|
1.74.0 (2023-11-27)
|
5
15
|
------------------
|
6
16
|
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.
|
1
|
+
1.76.0
|
@@ -33,6 +33,7 @@ require 'aws-sdk-core/plugins/defaults_mode.rb'
|
|
33
33
|
require 'aws-sdk-core/plugins/recursion_detection.rb'
|
34
34
|
require 'aws-sdk-core/plugins/sign.rb'
|
35
35
|
require 'aws-sdk-core/plugins/protocols/json_rpc.rb'
|
36
|
+
require 'aws-sdk-core/plugins/event_stream_configuration.rb'
|
36
37
|
|
37
38
|
Aws::Plugins::GlobalConfiguration.add_identifier(:cloudwatchlogs)
|
38
39
|
|
@@ -83,6 +84,7 @@ module Aws::CloudWatchLogs
|
|
83
84
|
add_plugin(Aws::Plugins::RecursionDetection)
|
84
85
|
add_plugin(Aws::Plugins::Sign)
|
85
86
|
add_plugin(Aws::Plugins::Protocols::JsonRpc)
|
87
|
+
add_plugin(Aws::Plugins::EventStreamConfiguration)
|
86
88
|
add_plugin(Aws::CloudWatchLogs::Plugins::Endpoints)
|
87
89
|
|
88
90
|
# @overload initialize(options)
|
@@ -216,10 +218,16 @@ module Aws::CloudWatchLogs
|
|
216
218
|
# @option options [Boolean] :endpoint_discovery (false)
|
217
219
|
# When set to `true`, endpoint discovery will be enabled for operations when available.
|
218
220
|
#
|
221
|
+
# @option options [Proc] :event_stream_handler
|
222
|
+
# When an EventStream or Proc object is provided, it will be used as callback for each chunk of event stream response received along the way.
|
223
|
+
#
|
219
224
|
# @option options [Boolean] :ignore_configured_endpoint_urls
|
220
225
|
# Setting to true disables use of endpoint URLs provided via environment
|
221
226
|
# variables and the shared configuration file.
|
222
227
|
#
|
228
|
+
# @option options [Proc] :input_event_stream_handler
|
229
|
+
# When an EventStream or Proc object is provided, it can be used for sending events for the event stream.
|
230
|
+
#
|
223
231
|
# @option options [Aws::Log::Formatter] :log_formatter (Aws::Log::Formatter.default)
|
224
232
|
# The log formatter.
|
225
233
|
#
|
@@ -236,6 +244,9 @@ module Aws::CloudWatchLogs
|
|
236
244
|
# setting this value to 5 will result in a request being retried up to
|
237
245
|
# 4 times. Used in `standard` and `adaptive` retry modes.
|
238
246
|
#
|
247
|
+
# @option options [Proc] :output_event_stream_handler
|
248
|
+
# When an EventStream or Proc object is provided, it will be used as callback for each chunk of event stream response received along the way.
|
249
|
+
#
|
239
250
|
# @option options [String] :profile ("default")
|
240
251
|
# Used when loading credentials from the shared credentials file
|
241
252
|
# at HOME/.aws/credentials. When not specified, 'default' is used.
|
@@ -592,7 +603,7 @@ module Aws::CloudWatchLogs
|
|
592
603
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/AWS-logs-and-resource-policy.html
|
593
604
|
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliverySource.html
|
594
605
|
# [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestination.html
|
595
|
-
# [4]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/
|
606
|
+
# [4]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestinationPolicy.html
|
596
607
|
#
|
597
608
|
# @option params [required, String] :delivery_source_name
|
598
609
|
# The name of the delivery source to use for this delivery.
|
@@ -777,8 +788,8 @@ module Aws::CloudWatchLogs
|
|
777
788
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/mask-sensitive-log-data.html
|
778
789
|
#
|
779
790
|
# @option params [required, Array<String>] :log_group_arn_list
|
780
|
-
# An array containing the
|
781
|
-
# detector will watch. You
|
791
|
+
# An array containing the ARN of the log group that this anomaly
|
792
|
+
# detector will watch. You can specify only one log group ARN.
|
782
793
|
#
|
783
794
|
# @option params [String] :detector_name
|
784
795
|
# A name for this anomaly detector.
|
@@ -939,6 +950,8 @@ module Aws::CloudWatchLogs
|
|
939
950
|
#
|
940
951
|
# If you omit this parameter, the default of `STANDARD` is used.
|
941
952
|
#
|
953
|
+
# After a log group is created, its class can't be changed.
|
954
|
+
#
|
942
955
|
# For details about the features supported by each class, see [Log
|
943
956
|
# classes][1]
|
944
957
|
#
|
@@ -2107,7 +2120,9 @@ module Aws::CloudWatchLogs
|
|
2107
2120
|
end
|
2108
2121
|
|
2109
2122
|
# This operation returns a paginated list of your saved CloudWatch Logs
|
2110
|
-
# Insights query definitions.
|
2123
|
+
# Insights query definitions. You can retrieve query definitions from
|
2124
|
+
# the current account or from a source account that is linked to the
|
2125
|
+
# current account.
|
2111
2126
|
#
|
2112
2127
|
# You can use the `queryDefinitionNamePrefix` parameter to limit the
|
2113
2128
|
# results to only the query definitions that have names that start with
|
@@ -3532,7 +3547,7 @@ module Aws::CloudWatchLogs
|
|
3532
3547
|
#
|
3533
3548
|
#
|
3534
3549
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliverySource.html
|
3535
|
-
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/
|
3550
|
+
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestinationPolicy.html
|
3536
3551
|
# [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_CreateDelivery.html
|
3537
3552
|
# [4]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/AWS-logs-and-resource-policy.html
|
3538
3553
|
#
|
@@ -3703,7 +3718,7 @@ module Aws::CloudWatchLogs
|
|
3703
3718
|
#
|
3704
3719
|
#
|
3705
3720
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestination.html
|
3706
|
-
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/
|
3721
|
+
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestinationPolicy.html
|
3707
3722
|
# [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_CreateDelivery.html
|
3708
3723
|
# [4]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/AWS-logs-and-resource-policy.html
|
3709
3724
|
#
|
@@ -4398,6 +4413,284 @@ module Aws::CloudWatchLogs
|
|
4398
4413
|
req.send_request(options)
|
4399
4414
|
end
|
4400
4415
|
|
4416
|
+
# Starts a Live Tail streaming session for one or more log groups. A
|
4417
|
+
# Live Tail session returns a stream of log events that have been
|
4418
|
+
# recently ingested in the log groups. For more information, see [Use
|
4419
|
+
# Live Tail to view logs in near real time][1].
|
4420
|
+
#
|
4421
|
+
# The response to this operation is a response stream, over which the
|
4422
|
+
# server sends live log events and the client receives them.
|
4423
|
+
#
|
4424
|
+
# The following objects are sent over the stream:
|
4425
|
+
#
|
4426
|
+
# * A single [LiveTailSessionStart][2] object is sent at the start of
|
4427
|
+
# the session.
|
4428
|
+
#
|
4429
|
+
# * Every second, a [LiveTailSessionUpdate][3] object is sent. Each of
|
4430
|
+
# these objects contains an array of the actual log events.
|
4431
|
+
#
|
4432
|
+
# If no new log events were ingested in the past second, the
|
4433
|
+
# `LiveTailSessionUpdate` object will contain an empty array.
|
4434
|
+
#
|
4435
|
+
# The array of log events contained in a `LiveTailSessionUpdate` can
|
4436
|
+
# include as many as 500 log events. If the number of log events
|
4437
|
+
# matching the request exceeds 500 per second, the log events are
|
4438
|
+
# sampled down to 500 log events to be included in each
|
4439
|
+
# `LiveTailSessionUpdate` object.
|
4440
|
+
#
|
4441
|
+
# If your client consumes the log events slower than the server
|
4442
|
+
# produces them, CloudWatch Logs buffers up to 10
|
4443
|
+
# `LiveTailSessionUpdate` events or 5000 log events, after which it
|
4444
|
+
# starts dropping the oldest events.
|
4445
|
+
#
|
4446
|
+
# * A [SessionStreamingException][4] object is returned if an unknown
|
4447
|
+
# error occurs on the server side.
|
4448
|
+
#
|
4449
|
+
# * A [SessionTimeoutException][5] object is returned when the session
|
4450
|
+
# times out, after it has been kept open for three hours.
|
4451
|
+
#
|
4452
|
+
# You can end a session before it times out by closing the session
|
4453
|
+
# stream or by closing the client that is receiving the stream. The
|
4454
|
+
# session also ends if the established connection between the client and
|
4455
|
+
# the server breaks.
|
4456
|
+
#
|
4457
|
+
#
|
4458
|
+
#
|
4459
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatchLogs_LiveTail.html
|
4460
|
+
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_LiveTailSessionStart.html
|
4461
|
+
# [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_LiveTailSessionUpdate.html
|
4462
|
+
# [4]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_SessionStreamingException.html
|
4463
|
+
# [5]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_SessionTimeoutException.html
|
4464
|
+
#
|
4465
|
+
# @option params [required, Array<String>] :log_group_identifiers
|
4466
|
+
# An array where each item in the array is a log group to include in the
|
4467
|
+
# Live Tail session.
|
4468
|
+
#
|
4469
|
+
# Specify each log group by its ARN.
|
4470
|
+
#
|
4471
|
+
# If you specify an ARN, the ARN can't end with an asterisk (*).
|
4472
|
+
#
|
4473
|
+
# <note markdown="1"> You can include up to 10 log groups.
|
4474
|
+
#
|
4475
|
+
# </note>
|
4476
|
+
#
|
4477
|
+
# @option params [Array<String>] :log_stream_names
|
4478
|
+
# If you specify this parameter, then only log events in the log streams
|
4479
|
+
# that you specify here are included in the Live Tail session.
|
4480
|
+
#
|
4481
|
+
# <note markdown="1"> You can specify this parameter only if you specify only one log group
|
4482
|
+
# in `logGroupIdentifiers`.
|
4483
|
+
#
|
4484
|
+
# </note>
|
4485
|
+
#
|
4486
|
+
# @option params [Array<String>] :log_stream_name_prefixes
|
4487
|
+
# If you specify this parameter, then only log events in the log streams
|
4488
|
+
# that have names that start with the prefixes that you specify here are
|
4489
|
+
# included in the Live Tail session.
|
4490
|
+
#
|
4491
|
+
# <note markdown="1"> You can specify this parameter only if you specify only one log group
|
4492
|
+
# in `logGroupIdentifiers`.
|
4493
|
+
#
|
4494
|
+
# </note>
|
4495
|
+
#
|
4496
|
+
# @option params [String] :log_event_filter_pattern
|
4497
|
+
# An optional pattern to use to filter the results to include only log
|
4498
|
+
# events that match the pattern. For example, a filter pattern of `error
|
4499
|
+
# 404` causes only log events that include both `error` and `404` to be
|
4500
|
+
# included in the Live Tail stream.
|
4501
|
+
#
|
4502
|
+
# Regular expression filter patterns are supported.
|
4503
|
+
#
|
4504
|
+
# For more information about filter pattern syntax, see [Filter and
|
4505
|
+
# Pattern Syntax][1].
|
4506
|
+
#
|
4507
|
+
#
|
4508
|
+
#
|
4509
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/FilterAndPatternSyntax.html
|
4510
|
+
#
|
4511
|
+
# @return [Types::StartLiveTailResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
4512
|
+
#
|
4513
|
+
# * {Types::StartLiveTailResponse#response_stream #response_stream} => Types::StartLiveTailResponseStream
|
4514
|
+
#
|
4515
|
+
# @example EventStream Operation Example
|
4516
|
+
#
|
4517
|
+
# You can process event once it arrives immediately, or wait until
|
4518
|
+
# full response complete and iterate through eventstream enumerator.
|
4519
|
+
#
|
4520
|
+
# To interact with event immediately, you need to register #start_live_tail
|
4521
|
+
# with callbacks, callbacks can be register for specifc events or for all events,
|
4522
|
+
# callback for errors in the event stream is also available for register.
|
4523
|
+
#
|
4524
|
+
# Callbacks can be passed in by `:event_stream_handler` option or within block
|
4525
|
+
# statement attached to #start_live_tail call directly. Hybrid pattern of both
|
4526
|
+
# is also supported.
|
4527
|
+
#
|
4528
|
+
# `:event_stream_handler` option takes in either Proc object or
|
4529
|
+
# Aws::CloudWatchLogs::EventStreams::StartLiveTailResponseStream object.
|
4530
|
+
#
|
4531
|
+
# Usage pattern a): callbacks with a block attached to #start_live_tail
|
4532
|
+
# Example for registering callbacks for all event types and error event
|
4533
|
+
#
|
4534
|
+
# client.start_live_tail( # params input# ) do |stream|
|
4535
|
+
# stream.on_error_event do |event|
|
4536
|
+
# # catch unmodeled error event in the stream
|
4537
|
+
# raise event
|
4538
|
+
# # => Aws::Errors::EventError
|
4539
|
+
# # event.event_type => :error
|
4540
|
+
# # event.error_code => String
|
4541
|
+
# # event.error_message => String
|
4542
|
+
# end
|
4543
|
+
#
|
4544
|
+
# stream.on_event do |event|
|
4545
|
+
# # process all events arrive
|
4546
|
+
# puts event.event_type
|
4547
|
+
# ...
|
4548
|
+
# end
|
4549
|
+
#
|
4550
|
+
# end
|
4551
|
+
#
|
4552
|
+
# Usage pattern b): pass in `:event_stream_handler` for #start_live_tail
|
4553
|
+
#
|
4554
|
+
# 1) create a Aws::CloudWatchLogs::EventStreams::StartLiveTailResponseStream object
|
4555
|
+
# Example for registering callbacks with specific events
|
4556
|
+
#
|
4557
|
+
# handler = Aws::CloudWatchLogs::EventStreams::StartLiveTailResponseStream.new
|
4558
|
+
# handler.on_session_start_event do |event|
|
4559
|
+
# event # => Aws::CloudWatchLogs::Types::sessionStart
|
4560
|
+
# end
|
4561
|
+
# handler.on_session_update_event do |event|
|
4562
|
+
# event # => Aws::CloudWatchLogs::Types::sessionUpdate
|
4563
|
+
# end
|
4564
|
+
# handler.on_session_timeout_exception_event do |event|
|
4565
|
+
# event # => Aws::CloudWatchLogs::Types::SessionTimeoutException
|
4566
|
+
# end
|
4567
|
+
# handler.on_session_streaming_exception_event do |event|
|
4568
|
+
# event # => Aws::CloudWatchLogs::Types::SessionStreamingException
|
4569
|
+
# end
|
4570
|
+
#
|
4571
|
+
# client.start_live_tail( # params input #, event_stream_handler: handler)
|
4572
|
+
#
|
4573
|
+
# 2) use a Ruby Proc object
|
4574
|
+
# Example for registering callbacks with specific events
|
4575
|
+
#
|
4576
|
+
# handler = Proc.new do |stream|
|
4577
|
+
# stream.on_session_start_event do |event|
|
4578
|
+
# event # => Aws::CloudWatchLogs::Types::sessionStart
|
4579
|
+
# end
|
4580
|
+
# stream.on_session_update_event do |event|
|
4581
|
+
# event # => Aws::CloudWatchLogs::Types::sessionUpdate
|
4582
|
+
# end
|
4583
|
+
# stream.on_session_timeout_exception_event do |event|
|
4584
|
+
# event # => Aws::CloudWatchLogs::Types::SessionTimeoutException
|
4585
|
+
# end
|
4586
|
+
# stream.on_session_streaming_exception_event do |event|
|
4587
|
+
# event # => Aws::CloudWatchLogs::Types::SessionStreamingException
|
4588
|
+
# end
|
4589
|
+
# end
|
4590
|
+
#
|
4591
|
+
# client.start_live_tail( # params input #, event_stream_handler: handler)
|
4592
|
+
#
|
4593
|
+
# Usage pattern c): hybird pattern of a) and b)
|
4594
|
+
#
|
4595
|
+
# handler = Aws::CloudWatchLogs::EventStreams::StartLiveTailResponseStream.new
|
4596
|
+
# handler.on_session_start_event do |event|
|
4597
|
+
# event # => Aws::CloudWatchLogs::Types::sessionStart
|
4598
|
+
# end
|
4599
|
+
# handler.on_session_update_event do |event|
|
4600
|
+
# event # => Aws::CloudWatchLogs::Types::sessionUpdate
|
4601
|
+
# end
|
4602
|
+
# handler.on_session_timeout_exception_event do |event|
|
4603
|
+
# event # => Aws::CloudWatchLogs::Types::SessionTimeoutException
|
4604
|
+
# end
|
4605
|
+
# handler.on_session_streaming_exception_event do |event|
|
4606
|
+
# event # => Aws::CloudWatchLogs::Types::SessionStreamingException
|
4607
|
+
# end
|
4608
|
+
#
|
4609
|
+
# client.start_live_tail( # params input #, event_stream_handler: handler) do |stream|
|
4610
|
+
# stream.on_error_event do |event|
|
4611
|
+
# # catch unmodeled error event in the stream
|
4612
|
+
# raise event
|
4613
|
+
# # => Aws::Errors::EventError
|
4614
|
+
# # event.event_type => :error
|
4615
|
+
# # event.error_code => String
|
4616
|
+
# # event.error_message => String
|
4617
|
+
# end
|
4618
|
+
# end
|
4619
|
+
#
|
4620
|
+
# Besides above usage patterns for process events when they arrive immediately, you can also
|
4621
|
+
# iterate through events after response complete.
|
4622
|
+
#
|
4623
|
+
# Events are available at resp.response_stream # => Enumerator
|
4624
|
+
# For parameter input example, please refer to following request syntax
|
4625
|
+
#
|
4626
|
+
# @example Request syntax with placeholder values
|
4627
|
+
#
|
4628
|
+
# resp = client.start_live_tail({
|
4629
|
+
# log_group_identifiers: ["LogGroupIdentifier"], # required
|
4630
|
+
# log_stream_names: ["LogStreamName"],
|
4631
|
+
# log_stream_name_prefixes: ["LogStreamName"],
|
4632
|
+
# log_event_filter_pattern: "FilterPattern",
|
4633
|
+
# })
|
4634
|
+
#
|
4635
|
+
# @example Response structure
|
4636
|
+
#
|
4637
|
+
# All events are available at resp.response_stream:
|
4638
|
+
# resp.response_stream #=> Enumerator
|
4639
|
+
# resp.response_stream.event_types #=> [:session_start, :session_update, :session_timeout_exception, :session_streaming_exception]
|
4640
|
+
#
|
4641
|
+
# For :session_start event available at #on_session_start_event callback and response eventstream enumerator:
|
4642
|
+
# event.request_id #=> String
|
4643
|
+
# event.session_id #=> String
|
4644
|
+
# event.log_group_identifiers #=> Array
|
4645
|
+
# event.log_group_identifiers[0] #=> String
|
4646
|
+
# event.log_stream_names #=> Array
|
4647
|
+
# event.log_stream_names[0] #=> String
|
4648
|
+
# event.log_stream_name_prefixes #=> Array
|
4649
|
+
# event.log_stream_name_prefixes[0] #=> String
|
4650
|
+
# event.log_event_filter_pattern #=> String
|
4651
|
+
#
|
4652
|
+
# For :session_update event available at #on_session_update_event callback and response eventstream enumerator:
|
4653
|
+
# event.session_metadata.sampled #=> Boolean
|
4654
|
+
# event.session_results #=> Array
|
4655
|
+
# event.session_results[0].log_stream_name #=> String
|
4656
|
+
# event.session_results[0].log_group_identifier #=> String
|
4657
|
+
# event.session_results[0].message #=> String
|
4658
|
+
# event.session_results[0].timestamp #=> Integer
|
4659
|
+
# event.session_results[0].ingestion_time #=> Integer
|
4660
|
+
#
|
4661
|
+
# For :session_timeout_exception event available at #on_session_timeout_exception_event callback and response eventstream enumerator:
|
4662
|
+
# event.message #=> String
|
4663
|
+
#
|
4664
|
+
# For :session_streaming_exception event available at #on_session_streaming_exception_event callback and response eventstream enumerator:
|
4665
|
+
# event.message #=> String
|
4666
|
+
#
|
4667
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/StartLiveTail AWS API Documentation
|
4668
|
+
#
|
4669
|
+
# @overload start_live_tail(params = {})
|
4670
|
+
# @param [Hash] params ({})
|
4671
|
+
def start_live_tail(params = {}, options = {})
|
4672
|
+
params = params.dup
|
4673
|
+
event_stream_handler = case handler = params.delete(:event_stream_handler)
|
4674
|
+
when EventStreams::StartLiveTailResponseStream then handler
|
4675
|
+
when Proc then EventStreams::StartLiveTailResponseStream.new.tap(&handler)
|
4676
|
+
when nil then EventStreams::StartLiveTailResponseStream.new
|
4677
|
+
else
|
4678
|
+
msg = "expected :event_stream_handler to be a block or "\
|
4679
|
+
"instance of Aws::CloudWatchLogs::EventStreams::StartLiveTailResponseStream"\
|
4680
|
+
", got `#{handler.inspect}` instead"
|
4681
|
+
raise ArgumentError, msg
|
4682
|
+
end
|
4683
|
+
|
4684
|
+
yield(event_stream_handler) if block_given?
|
4685
|
+
|
4686
|
+
req = build_request(:start_live_tail, params)
|
4687
|
+
|
4688
|
+
req.context[:event_stream_handler] = event_stream_handler
|
4689
|
+
req.handlers.add(Aws::Binary::DecodeHandler, priority: 95)
|
4690
|
+
|
4691
|
+
req.send_request(options)
|
4692
|
+
end
|
4693
|
+
|
4401
4694
|
# Schedules a query of a log group using CloudWatch Logs Insights. You
|
4402
4695
|
# specify the log group and time range to query and the query string to
|
4403
4696
|
# use.
|
@@ -4912,7 +5205,7 @@ module Aws::CloudWatchLogs
|
|
4912
5205
|
params: params,
|
4913
5206
|
config: config)
|
4914
5207
|
context[:gem_name] = 'aws-sdk-cloudwatchlogs'
|
4915
|
-
context[:gem_version] = '1.
|
5208
|
+
context[:gem_version] = '1.76.0'
|
4916
5209
|
Seahorse::Client::Request.new(handlers, context)
|
4917
5210
|
end
|
4918
5211
|
|
@@ -178,6 +178,7 @@ module Aws::CloudWatchLogs
|
|
178
178
|
InvalidOperationException = Shapes::StructureShape.new(name: 'InvalidOperationException')
|
179
179
|
InvalidParameterException = Shapes::StructureShape.new(name: 'InvalidParameterException')
|
180
180
|
InvalidSequenceTokenException = Shapes::StructureShape.new(name: 'InvalidSequenceTokenException')
|
181
|
+
IsSampled = Shapes::BooleanShape.new(name: 'IsSampled')
|
181
182
|
KmsKeyId = Shapes::StringShape.new(name: 'KmsKeyId')
|
182
183
|
LimitExceededException = Shapes::StructureShape.new(name: 'LimitExceededException')
|
183
184
|
ListAnomaliesLimit = Shapes::IntegerShape.new(name: 'ListAnomaliesLimit')
|
@@ -190,6 +191,11 @@ module Aws::CloudWatchLogs
|
|
190
191
|
ListTagsForResourceResponse = Shapes::StructureShape.new(name: 'ListTagsForResourceResponse')
|
191
192
|
ListTagsLogGroupRequest = Shapes::StructureShape.new(name: 'ListTagsLogGroupRequest')
|
192
193
|
ListTagsLogGroupResponse = Shapes::StructureShape.new(name: 'ListTagsLogGroupResponse')
|
194
|
+
LiveTailSessionLogEvent = Shapes::StructureShape.new(name: 'LiveTailSessionLogEvent')
|
195
|
+
LiveTailSessionMetadata = Shapes::StructureShape.new(name: 'LiveTailSessionMetadata')
|
196
|
+
LiveTailSessionResults = Shapes::ListShape.new(name: 'LiveTailSessionResults')
|
197
|
+
LiveTailSessionStart = Shapes::StructureShape.new(name: 'LiveTailSessionStart')
|
198
|
+
LiveTailSessionUpdate = Shapes::StructureShape.new(name: 'LiveTailSessionUpdate')
|
193
199
|
LogEvent = Shapes::StringShape.new(name: 'LogEvent')
|
194
200
|
LogEventIndex = Shapes::IntegerShape.new(name: 'LogEventIndex')
|
195
201
|
LogGroup = Shapes::StructureShape.new(name: 'LogGroup')
|
@@ -278,6 +284,7 @@ module Aws::CloudWatchLogs
|
|
278
284
|
QueryStatus = Shapes::StringShape.new(name: 'QueryStatus')
|
279
285
|
QueryString = Shapes::StringShape.new(name: 'QueryString')
|
280
286
|
RejectedLogEventsInfo = Shapes::StructureShape.new(name: 'RejectedLogEventsInfo')
|
287
|
+
RequestId = Shapes::StringShape.new(name: 'RequestId')
|
281
288
|
ResourceAlreadyExistsException = Shapes::StructureShape.new(name: 'ResourceAlreadyExistsException')
|
282
289
|
ResourceArns = Shapes::ListShape.new(name: 'ResourceArns')
|
283
290
|
ResourceIdentifier = Shapes::StringShape.new(name: 'ResourceIdentifier')
|
@@ -294,8 +301,15 @@ module Aws::CloudWatchLogs
|
|
294
301
|
Service = Shapes::StringShape.new(name: 'Service')
|
295
302
|
ServiceQuotaExceededException = Shapes::StructureShape.new(name: 'ServiceQuotaExceededException')
|
296
303
|
ServiceUnavailableException = Shapes::StructureShape.new(name: 'ServiceUnavailableException')
|
304
|
+
SessionId = Shapes::StringShape.new(name: 'SessionId')
|
305
|
+
SessionStreamingException = Shapes::StructureShape.new(name: 'SessionStreamingException')
|
306
|
+
SessionTimeoutException = Shapes::StructureShape.new(name: 'SessionTimeoutException')
|
297
307
|
StandardUnit = Shapes::StringShape.new(name: 'StandardUnit')
|
298
308
|
StartFromHead = Shapes::BooleanShape.new(name: 'StartFromHead')
|
309
|
+
StartLiveTailLogGroupIdentifiers = Shapes::ListShape.new(name: 'StartLiveTailLogGroupIdentifiers')
|
310
|
+
StartLiveTailRequest = Shapes::StructureShape.new(name: 'StartLiveTailRequest')
|
311
|
+
StartLiveTailResponse = Shapes::StructureShape.new(name: 'StartLiveTailResponse')
|
312
|
+
StartLiveTailResponseStream = Shapes::StructureShape.new(name: 'StartLiveTailResponseStream')
|
299
313
|
StartQueryRequest = Shapes::StructureShape.new(name: 'StartQueryRequest')
|
300
314
|
StartQueryResponse = Shapes::StructureShape.new(name: 'StartQueryResponse')
|
301
315
|
State = Shapes::StringShape.new(name: 'State')
|
@@ -864,6 +878,30 @@ module Aws::CloudWatchLogs
|
|
864
878
|
ListTagsLogGroupResponse.add_member(:tags, Shapes::ShapeRef.new(shape: Tags, location_name: "tags"))
|
865
879
|
ListTagsLogGroupResponse.struct_class = Types::ListTagsLogGroupResponse
|
866
880
|
|
881
|
+
LiveTailSessionLogEvent.add_member(:log_stream_name, Shapes::ShapeRef.new(shape: LogStreamName, location_name: "logStreamName"))
|
882
|
+
LiveTailSessionLogEvent.add_member(:log_group_identifier, Shapes::ShapeRef.new(shape: LogGroupIdentifier, location_name: "logGroupIdentifier"))
|
883
|
+
LiveTailSessionLogEvent.add_member(:message, Shapes::ShapeRef.new(shape: EventMessage, location_name: "message"))
|
884
|
+
LiveTailSessionLogEvent.add_member(:timestamp, Shapes::ShapeRef.new(shape: Timestamp, location_name: "timestamp"))
|
885
|
+
LiveTailSessionLogEvent.add_member(:ingestion_time, Shapes::ShapeRef.new(shape: Timestamp, location_name: "ingestionTime"))
|
886
|
+
LiveTailSessionLogEvent.struct_class = Types::LiveTailSessionLogEvent
|
887
|
+
|
888
|
+
LiveTailSessionMetadata.add_member(:sampled, Shapes::ShapeRef.new(shape: IsSampled, location_name: "sampled"))
|
889
|
+
LiveTailSessionMetadata.struct_class = Types::LiveTailSessionMetadata
|
890
|
+
|
891
|
+
LiveTailSessionResults.member = Shapes::ShapeRef.new(shape: LiveTailSessionLogEvent)
|
892
|
+
|
893
|
+
LiveTailSessionStart.add_member(:request_id, Shapes::ShapeRef.new(shape: RequestId, location_name: "requestId"))
|
894
|
+
LiveTailSessionStart.add_member(:session_id, Shapes::ShapeRef.new(shape: SessionId, location_name: "sessionId"))
|
895
|
+
LiveTailSessionStart.add_member(:log_group_identifiers, Shapes::ShapeRef.new(shape: StartLiveTailLogGroupIdentifiers, location_name: "logGroupIdentifiers"))
|
896
|
+
LiveTailSessionStart.add_member(:log_stream_names, Shapes::ShapeRef.new(shape: InputLogStreamNames, location_name: "logStreamNames"))
|
897
|
+
LiveTailSessionStart.add_member(:log_stream_name_prefixes, Shapes::ShapeRef.new(shape: InputLogStreamNames, location_name: "logStreamNamePrefixes"))
|
898
|
+
LiveTailSessionStart.add_member(:log_event_filter_pattern, Shapes::ShapeRef.new(shape: FilterPattern, location_name: "logEventFilterPattern"))
|
899
|
+
LiveTailSessionStart.struct_class = Types::LiveTailSessionStart
|
900
|
+
|
901
|
+
LiveTailSessionUpdate.add_member(:session_metadata, Shapes::ShapeRef.new(shape: LiveTailSessionMetadata, location_name: "sessionMetadata"))
|
902
|
+
LiveTailSessionUpdate.add_member(:session_results, Shapes::ShapeRef.new(shape: LiveTailSessionResults, location_name: "sessionResults"))
|
903
|
+
LiveTailSessionUpdate.struct_class = Types::LiveTailSessionUpdate
|
904
|
+
|
867
905
|
LogGroup.add_member(:log_group_name, Shapes::ShapeRef.new(shape: LogGroupName, location_name: "logGroupName"))
|
868
906
|
LogGroup.add_member(:creation_time, Shapes::ShapeRef.new(shape: Timestamp, location_name: "creationTime"))
|
869
907
|
LogGroup.add_member(:retention_in_days, Shapes::ShapeRef.new(shape: Days, location_name: "retentionInDays"))
|
@@ -1125,6 +1163,29 @@ module Aws::CloudWatchLogs
|
|
1125
1163
|
|
1126
1164
|
ServiceUnavailableException.struct_class = Types::ServiceUnavailableException
|
1127
1165
|
|
1166
|
+
SessionStreamingException.add_member(:message, Shapes::ShapeRef.new(shape: Message, location_name: "message"))
|
1167
|
+
SessionStreamingException.struct_class = Types::SessionStreamingException
|
1168
|
+
|
1169
|
+
SessionTimeoutException.add_member(:message, Shapes::ShapeRef.new(shape: Message, location_name: "message"))
|
1170
|
+
SessionTimeoutException.struct_class = Types::SessionTimeoutException
|
1171
|
+
|
1172
|
+
StartLiveTailLogGroupIdentifiers.member = Shapes::ShapeRef.new(shape: LogGroupIdentifier)
|
1173
|
+
|
1174
|
+
StartLiveTailRequest.add_member(:log_group_identifiers, Shapes::ShapeRef.new(shape: StartLiveTailLogGroupIdentifiers, required: true, location_name: "logGroupIdentifiers"))
|
1175
|
+
StartLiveTailRequest.add_member(:log_stream_names, Shapes::ShapeRef.new(shape: InputLogStreamNames, location_name: "logStreamNames"))
|
1176
|
+
StartLiveTailRequest.add_member(:log_stream_name_prefixes, Shapes::ShapeRef.new(shape: InputLogStreamNames, location_name: "logStreamNamePrefixes"))
|
1177
|
+
StartLiveTailRequest.add_member(:log_event_filter_pattern, Shapes::ShapeRef.new(shape: FilterPattern, location_name: "logEventFilterPattern"))
|
1178
|
+
StartLiveTailRequest.struct_class = Types::StartLiveTailRequest
|
1179
|
+
|
1180
|
+
StartLiveTailResponse.add_member(:response_stream, Shapes::ShapeRef.new(shape: StartLiveTailResponseStream, eventstream: true, location_name: "responseStream"))
|
1181
|
+
StartLiveTailResponse.struct_class = Types::StartLiveTailResponse
|
1182
|
+
|
1183
|
+
StartLiveTailResponseStream.add_member(:session_start, Shapes::ShapeRef.new(shape: LiveTailSessionStart, event: true, location_name: "sessionStart"))
|
1184
|
+
StartLiveTailResponseStream.add_member(:session_update, Shapes::ShapeRef.new(shape: LiveTailSessionUpdate, event: true, location_name: "sessionUpdate"))
|
1185
|
+
StartLiveTailResponseStream.add_member(:session_timeout_exception, Shapes::ShapeRef.new(shape: SessionTimeoutException, location_name: "SessionTimeoutException"))
|
1186
|
+
StartLiveTailResponseStream.add_member(:session_streaming_exception, Shapes::ShapeRef.new(shape: SessionStreamingException, location_name: "SessionStreamingException"))
|
1187
|
+
StartLiveTailResponseStream.struct_class = Types::StartLiveTailResponseStream
|
1188
|
+
|
1128
1189
|
StartQueryRequest.add_member(:log_group_name, Shapes::ShapeRef.new(shape: LogGroupName, location_name: "logGroupName"))
|
1129
1190
|
StartQueryRequest.add_member(:log_group_names, Shapes::ShapeRef.new(shape: LogGroupNames, location_name: "logGroupNames"))
|
1130
1191
|
StartQueryRequest.add_member(:log_group_identifiers, Shapes::ShapeRef.new(shape: LogGroupIdentifiers, location_name: "logGroupIdentifiers"))
|
@@ -2072,6 +2133,22 @@ module Aws::CloudWatchLogs
|
|
2072
2133
|
o.errors << Shapes::ShapeRef.new(shape: ServiceUnavailableException)
|
2073
2134
|
end)
|
2074
2135
|
|
2136
|
+
api.add_operation(:start_live_tail, Seahorse::Model::Operation.new.tap do |o|
|
2137
|
+
o.name = "StartLiveTail"
|
2138
|
+
o.http_method = "POST"
|
2139
|
+
o.http_request_uri = "/"
|
2140
|
+
o.endpoint_pattern = {
|
2141
|
+
"hostPrefix" => "streaming-",
|
2142
|
+
}
|
2143
|
+
o.input = Shapes::ShapeRef.new(shape: StartLiveTailRequest)
|
2144
|
+
o.output = Shapes::ShapeRef.new(shape: StartLiveTailResponse)
|
2145
|
+
o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
|
2146
|
+
o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
|
2147
|
+
o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
|
2148
|
+
o.errors << Shapes::ShapeRef.new(shape: LimitExceededException)
|
2149
|
+
o.errors << Shapes::ShapeRef.new(shape: InvalidOperationException)
|
2150
|
+
end)
|
2151
|
+
|
2075
2152
|
api.add_operation(:start_query, Seahorse::Model::Operation.new.tap do |o|
|
2076
2153
|
o.name = "StartQuery"
|
2077
2154
|
o.http_method = "POST"
|
@@ -908,6 +908,20 @@ module Aws::CloudWatchLogs
|
|
908
908
|
end
|
909
909
|
end
|
910
910
|
|
911
|
+
class StartLiveTail
|
912
|
+
def self.build(context)
|
913
|
+
unless context.config.regional_endpoint
|
914
|
+
endpoint = context.config.endpoint.to_s
|
915
|
+
end
|
916
|
+
Aws::CloudWatchLogs::EndpointParameters.new(
|
917
|
+
region: context.config.region,
|
918
|
+
use_dual_stack: context.config.use_dualstack_endpoint,
|
919
|
+
use_fips: context.config.use_fips_endpoint,
|
920
|
+
endpoint: endpoint,
|
921
|
+
)
|
922
|
+
end
|
923
|
+
end
|
924
|
+
|
911
925
|
class StartQuery
|
912
926
|
def self.build(context)
|
913
927
|
unless context.config.regional_endpoint
|
@@ -40,6 +40,8 @@ module Aws::CloudWatchLogs
|
|
40
40
|
# * {ResourceNotFoundException}
|
41
41
|
# * {ServiceQuotaExceededException}
|
42
42
|
# * {ServiceUnavailableException}
|
43
|
+
# * {SessionStreamingException}
|
44
|
+
# * {SessionTimeoutException}
|
43
45
|
# * {ThrottlingException}
|
44
46
|
# * {TooManyTagsException}
|
45
47
|
# * {UnrecognizedClientException}
|
@@ -196,6 +198,36 @@ module Aws::CloudWatchLogs
|
|
196
198
|
end
|
197
199
|
end
|
198
200
|
|
201
|
+
class SessionStreamingException < ServiceError
|
202
|
+
|
203
|
+
# @param [Seahorse::Client::RequestContext] context
|
204
|
+
# @param [String] message
|
205
|
+
# @param [Aws::CloudWatchLogs::Types::SessionStreamingException] data
|
206
|
+
def initialize(context, message, data = Aws::EmptyStructure.new)
|
207
|
+
super(context, message, data)
|
208
|
+
end
|
209
|
+
|
210
|
+
# @return [String]
|
211
|
+
def message
|
212
|
+
@message || @data[:message]
|
213
|
+
end
|
214
|
+
end
|
215
|
+
|
216
|
+
class SessionTimeoutException < ServiceError
|
217
|
+
|
218
|
+
# @param [Seahorse::Client::RequestContext] context
|
219
|
+
# @param [String] message
|
220
|
+
# @param [Aws::CloudWatchLogs::Types::SessionTimeoutException] data
|
221
|
+
def initialize(context, message, data = Aws::EmptyStructure.new)
|
222
|
+
super(context, message, data)
|
223
|
+
end
|
224
|
+
|
225
|
+
# @return [String]
|
226
|
+
def message
|
227
|
+
@message || @data[:message]
|
228
|
+
end
|
229
|
+
end
|
230
|
+
|
199
231
|
class ThrottlingException < ServiceError
|
200
232
|
|
201
233
|
# @param [Seahorse::Client::RequestContext] context
|
@@ -0,0 +1,64 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# WARNING ABOUT GENERATED CODE
|
4
|
+
#
|
5
|
+
# This file is generated. See the contributing guide for more information:
|
6
|
+
# https://github.com/aws/aws-sdk-ruby/blob/version-3/CONTRIBUTING.md
|
7
|
+
#
|
8
|
+
# WARNING ABOUT GENERATED CODE
|
9
|
+
|
10
|
+
module Aws::CloudWatchLogs
|
11
|
+
module EventStreams
|
12
|
+
class StartLiveTailResponseStream
|
13
|
+
|
14
|
+
def initialize
|
15
|
+
@event_emitter = Aws::EventEmitter.new
|
16
|
+
end
|
17
|
+
|
18
|
+
def on_session_start_event(&block)
|
19
|
+
@event_emitter.on(:session_start, block) if block_given?
|
20
|
+
end
|
21
|
+
|
22
|
+
def on_session_update_event(&block)
|
23
|
+
@event_emitter.on(:session_update, block) if block_given?
|
24
|
+
end
|
25
|
+
|
26
|
+
def on_session_timeout_exception_event(&block)
|
27
|
+
@event_emitter.on(:session_timeout_exception, block) if block_given?
|
28
|
+
end
|
29
|
+
|
30
|
+
def on_session_streaming_exception_event(&block)
|
31
|
+
@event_emitter.on(:session_streaming_exception, block) if block_given?
|
32
|
+
end
|
33
|
+
|
34
|
+
def on_error_event(&block)
|
35
|
+
@event_emitter.on(:error, block) if block_given?
|
36
|
+
end
|
37
|
+
|
38
|
+
def on_initial_response_event(&block)
|
39
|
+
@event_emitter.on(:initial_response, block) if block_given?
|
40
|
+
end
|
41
|
+
|
42
|
+
def on_unknown_event(&block)
|
43
|
+
@event_emitter.on(:unknown_event, block) if block_given?
|
44
|
+
end
|
45
|
+
|
46
|
+
def on_event(&block)
|
47
|
+
on_session_start_event(&block)
|
48
|
+
on_session_update_event(&block)
|
49
|
+
on_session_timeout_exception_event(&block)
|
50
|
+
on_session_streaming_exception_event(&block)
|
51
|
+
on_error_event(&block)
|
52
|
+
on_initial_response_event(&block)
|
53
|
+
on_unknown_event(&block)
|
54
|
+
end
|
55
|
+
|
56
|
+
# @api private
|
57
|
+
# @return Aws::EventEmitter
|
58
|
+
attr_reader :event_emitter
|
59
|
+
|
60
|
+
end
|
61
|
+
|
62
|
+
end
|
63
|
+
end
|
64
|
+
|
@@ -25,16 +25,17 @@ module Aws::CloudWatchLogs
|
|
25
25
|
# @api private
|
26
26
|
class Handler < Seahorse::Client::Handler
|
27
27
|
def call(context)
|
28
|
-
# If endpoint was discovered, do not resolve or apply the endpoint.
|
29
28
|
unless context[:discovered_endpoint]
|
30
29
|
params = parameters_for_operation(context)
|
31
30
|
endpoint = context.config.endpoint_provider.resolve_endpoint(params)
|
32
31
|
|
33
32
|
context.http_request.endpoint = endpoint.url
|
34
33
|
apply_endpoint_headers(context, endpoint.headers)
|
34
|
+
|
35
|
+
context[:endpoint_params] = params
|
36
|
+
context[:endpoint_properties] = endpoint.properties
|
35
37
|
end
|
36
38
|
|
37
|
-
context[:endpoint_params] = params
|
38
39
|
context[:auth_scheme] =
|
39
40
|
Aws::Endpoints.resolve_auth_scheme(context, endpoint)
|
40
41
|
|
@@ -184,6 +185,8 @@ module Aws::CloudWatchLogs
|
|
184
185
|
Aws::CloudWatchLogs::Endpoints::PutRetentionPolicy.build(context)
|
185
186
|
when :put_subscription_filter
|
186
187
|
Aws::CloudWatchLogs::Endpoints::PutSubscriptionFilter.build(context)
|
188
|
+
when :start_live_tail
|
189
|
+
Aws::CloudWatchLogs::Endpoints::StartLiveTail.build(context)
|
187
190
|
when :start_query
|
188
191
|
Aws::CloudWatchLogs::Endpoints::StartQuery.build(context)
|
189
192
|
when :stop_query
|
@@ -458,8 +458,8 @@ module Aws::CloudWatchLogs
|
|
458
458
|
end
|
459
459
|
|
460
460
|
# @!attribute [rw] log_group_arn_list
|
461
|
-
# An array containing the
|
462
|
-
# detector will watch. You
|
461
|
+
# An array containing the ARN of the log group that this anomaly
|
462
|
+
# detector will watch. You can specify only one log group ARN.
|
463
463
|
# @return [Array<String>]
|
464
464
|
#
|
465
465
|
# @!attribute [rw] detector_name
|
@@ -589,6 +589,8 @@ module Aws::CloudWatchLogs
|
|
589
589
|
#
|
590
590
|
# If you omit this parameter, the default of `STANDARD` is used.
|
591
591
|
#
|
592
|
+
# After a log group is created, its class can't be changed.
|
593
|
+
#
|
592
594
|
# For details about the features supported by each class, see [Log
|
593
595
|
# classes][1]
|
594
596
|
#
|
@@ -969,7 +971,7 @@ module Aws::CloudWatchLogs
|
|
969
971
|
#
|
970
972
|
#
|
971
973
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliverySource.html
|
972
|
-
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/
|
974
|
+
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestinationPolicy.html
|
973
975
|
# [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_CreateDelivery.html
|
974
976
|
#
|
975
977
|
# @!attribute [rw] name
|
@@ -1069,7 +1071,7 @@ module Aws::CloudWatchLogs
|
|
1069
1071
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/AWS-logs-and-resource-policy.html
|
1070
1072
|
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliverySource.html
|
1071
1073
|
# [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestination.html
|
1072
|
-
# [4]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/
|
1074
|
+
# [4]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDeliveryDestinationPolicy.html
|
1073
1075
|
# [5]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_CreateDelivery.html
|
1074
1076
|
#
|
1075
1077
|
# @!attribute [rw] name
|
@@ -2853,6 +2855,152 @@ module Aws::CloudWatchLogs
|
|
2853
2855
|
include Aws::Structure
|
2854
2856
|
end
|
2855
2857
|
|
2858
|
+
# This object contains the information for one log event returned in a
|
2859
|
+
# Live Tail stream.
|
2860
|
+
#
|
2861
|
+
# @!attribute [rw] log_stream_name
|
2862
|
+
# The name of the log stream that ingested this log event.
|
2863
|
+
# @return [String]
|
2864
|
+
#
|
2865
|
+
# @!attribute [rw] log_group_identifier
|
2866
|
+
# The name or ARN of the log group that ingested this log event.
|
2867
|
+
# @return [String]
|
2868
|
+
#
|
2869
|
+
# @!attribute [rw] message
|
2870
|
+
# The log event message text.
|
2871
|
+
# @return [String]
|
2872
|
+
#
|
2873
|
+
# @!attribute [rw] timestamp
|
2874
|
+
# The timestamp specifying when this log event was created.
|
2875
|
+
# @return [Integer]
|
2876
|
+
#
|
2877
|
+
# @!attribute [rw] ingestion_time
|
2878
|
+
# The timestamp specifying when this log event was ingested into the
|
2879
|
+
# log group.
|
2880
|
+
# @return [Integer]
|
2881
|
+
#
|
2882
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/LiveTailSessionLogEvent AWS API Documentation
|
2883
|
+
#
|
2884
|
+
class LiveTailSessionLogEvent < Struct.new(
|
2885
|
+
:log_stream_name,
|
2886
|
+
:log_group_identifier,
|
2887
|
+
:message,
|
2888
|
+
:timestamp,
|
2889
|
+
:ingestion_time)
|
2890
|
+
SENSITIVE = []
|
2891
|
+
include Aws::Structure
|
2892
|
+
end
|
2893
|
+
|
2894
|
+
# This object contains the metadata for one `LiveTailSessionUpdate`
|
2895
|
+
# structure. It indicates whether that update includes only a sample of
|
2896
|
+
# 500 log events out of a larger number of ingested log events, or if it
|
2897
|
+
# contains all of the matching log events ingested during that second of
|
2898
|
+
# time.
|
2899
|
+
#
|
2900
|
+
# @!attribute [rw] sampled
|
2901
|
+
# If this is `true`, then more than 500 log events matched the request
|
2902
|
+
# for this update, and the `sessionResults` includes a sample of 500
|
2903
|
+
# of those events.
|
2904
|
+
#
|
2905
|
+
# If this is `false`, then 500 or fewer log events matched the request
|
2906
|
+
# for this update, so no sampling was necessary. In this case, the
|
2907
|
+
# `sessionResults` array includes all log events that matched your
|
2908
|
+
# request during this time.
|
2909
|
+
# @return [Boolean]
|
2910
|
+
#
|
2911
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/LiveTailSessionMetadata AWS API Documentation
|
2912
|
+
#
|
2913
|
+
class LiveTailSessionMetadata < Struct.new(
|
2914
|
+
:sampled)
|
2915
|
+
SENSITIVE = []
|
2916
|
+
include Aws::Structure
|
2917
|
+
end
|
2918
|
+
|
2919
|
+
# This object contains information about this Live Tail session,
|
2920
|
+
# including the log groups included and the log stream filters, if any.
|
2921
|
+
#
|
2922
|
+
# @!attribute [rw] request_id
|
2923
|
+
# The unique ID generated by CloudWatch Logs to identify this Live
|
2924
|
+
# Tail session request.
|
2925
|
+
# @return [String]
|
2926
|
+
#
|
2927
|
+
# @!attribute [rw] session_id
|
2928
|
+
# The unique ID generated by CloudWatch Logs to identify this Live
|
2929
|
+
# Tail session.
|
2930
|
+
# @return [String]
|
2931
|
+
#
|
2932
|
+
# @!attribute [rw] log_group_identifiers
|
2933
|
+
# An array of the names and ARNs of the log groups included in this
|
2934
|
+
# Live Tail session.
|
2935
|
+
# @return [Array<String>]
|
2936
|
+
#
|
2937
|
+
# @!attribute [rw] log_stream_names
|
2938
|
+
# If your StartLiveTail operation request included a `logStreamNames`
|
2939
|
+
# parameter that filtered the session to only include certain log
|
2940
|
+
# streams, these streams are listed here.
|
2941
|
+
# @return [Array<String>]
|
2942
|
+
#
|
2943
|
+
# @!attribute [rw] log_stream_name_prefixes
|
2944
|
+
# If your StartLiveTail operation request included a
|
2945
|
+
# `logStreamNamePrefixes` parameter that filtered the session to only
|
2946
|
+
# include log streams that have names that start with certain
|
2947
|
+
# prefixes, these prefixes are listed here.
|
2948
|
+
# @return [Array<String>]
|
2949
|
+
#
|
2950
|
+
# @!attribute [rw] log_event_filter_pattern
|
2951
|
+
# An optional pattern to filter the results to include only log events
|
2952
|
+
# that match the pattern. For example, a filter pattern of `error 404`
|
2953
|
+
# displays only log events that include both `error` and `404`.
|
2954
|
+
#
|
2955
|
+
# For more information about filter pattern syntax, see [Filter and
|
2956
|
+
# Pattern Syntax][1].
|
2957
|
+
#
|
2958
|
+
#
|
2959
|
+
#
|
2960
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/FilterAndPatternSyntax.html
|
2961
|
+
# @return [String]
|
2962
|
+
#
|
2963
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/LiveTailSessionStart AWS API Documentation
|
2964
|
+
#
|
2965
|
+
class LiveTailSessionStart < Struct.new(
|
2966
|
+
:request_id,
|
2967
|
+
:session_id,
|
2968
|
+
:log_group_identifiers,
|
2969
|
+
:log_stream_names,
|
2970
|
+
:log_stream_name_prefixes,
|
2971
|
+
:log_event_filter_pattern,
|
2972
|
+
:event_type)
|
2973
|
+
SENSITIVE = []
|
2974
|
+
include Aws::Structure
|
2975
|
+
end
|
2976
|
+
|
2977
|
+
# This object contains the log events and metadata for a Live Tail
|
2978
|
+
# session.
|
2979
|
+
#
|
2980
|
+
# @!attribute [rw] session_metadata
|
2981
|
+
# This object contains the session metadata for a Live Tail session.
|
2982
|
+
# @return [Types::LiveTailSessionMetadata]
|
2983
|
+
#
|
2984
|
+
# @!attribute [rw] session_results
|
2985
|
+
# An array, where each member of the array includes the information
|
2986
|
+
# for one log event in the Live Tail session.
|
2987
|
+
#
|
2988
|
+
# A `sessionResults` array can include as many as 500 log events. If
|
2989
|
+
# the number of log events matching the request exceeds 500 per
|
2990
|
+
# second, the log events are sampled down to 500 log events to be
|
2991
|
+
# included in each `sessionUpdate` structure.
|
2992
|
+
# @return [Array<Types::LiveTailSessionLogEvent>]
|
2993
|
+
#
|
2994
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/LiveTailSessionUpdate AWS API Documentation
|
2995
|
+
#
|
2996
|
+
class LiveTailSessionUpdate < Struct.new(
|
2997
|
+
:session_metadata,
|
2998
|
+
:session_results,
|
2999
|
+
:event_type)
|
3000
|
+
SENSITIVE = []
|
3001
|
+
include Aws::Structure
|
3002
|
+
end
|
3003
|
+
|
2856
3004
|
# Represents a log group.
|
2857
3005
|
#
|
2858
3006
|
# @!attribute [rw] log_group_name
|
@@ -4251,6 +4399,110 @@ module Aws::CloudWatchLogs
|
|
4251
4399
|
#
|
4252
4400
|
class ServiceUnavailableException < Aws::EmptyStructure; end
|
4253
4401
|
|
4402
|
+
# his exception is returned if an unknown error occurs during a Live
|
4403
|
+
# Tail session.
|
4404
|
+
#
|
4405
|
+
# @!attribute [rw] message
|
4406
|
+
# @return [String]
|
4407
|
+
#
|
4408
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/SessionStreamingException AWS API Documentation
|
4409
|
+
#
|
4410
|
+
class SessionStreamingException < Struct.new(
|
4411
|
+
:message,
|
4412
|
+
:event_type)
|
4413
|
+
SENSITIVE = []
|
4414
|
+
include Aws::Structure
|
4415
|
+
end
|
4416
|
+
|
4417
|
+
# This exception is returned in a Live Tail stream when the Live Tail
|
4418
|
+
# session times out. Live Tail sessions time out after three hours.
|
4419
|
+
#
|
4420
|
+
# @!attribute [rw] message
|
4421
|
+
# @return [String]
|
4422
|
+
#
|
4423
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/SessionTimeoutException AWS API Documentation
|
4424
|
+
#
|
4425
|
+
class SessionTimeoutException < Struct.new(
|
4426
|
+
:message,
|
4427
|
+
:event_type)
|
4428
|
+
SENSITIVE = []
|
4429
|
+
include Aws::Structure
|
4430
|
+
end
|
4431
|
+
|
4432
|
+
# @!attribute [rw] log_group_identifiers
|
4433
|
+
# An array where each item in the array is a log group to include in
|
4434
|
+
# the Live Tail session.
|
4435
|
+
#
|
4436
|
+
# Specify each log group by its ARN.
|
4437
|
+
#
|
4438
|
+
# If you specify an ARN, the ARN can't end with an asterisk (*).
|
4439
|
+
#
|
4440
|
+
# <note markdown="1"> You can include up to 10 log groups.
|
4441
|
+
#
|
4442
|
+
# </note>
|
4443
|
+
# @return [Array<String>]
|
4444
|
+
#
|
4445
|
+
# @!attribute [rw] log_stream_names
|
4446
|
+
# If you specify this parameter, then only log events in the log
|
4447
|
+
# streams that you specify here are included in the Live Tail session.
|
4448
|
+
#
|
4449
|
+
# <note markdown="1"> You can specify this parameter only if you specify only one log
|
4450
|
+
# group in `logGroupIdentifiers`.
|
4451
|
+
#
|
4452
|
+
# </note>
|
4453
|
+
# @return [Array<String>]
|
4454
|
+
#
|
4455
|
+
# @!attribute [rw] log_stream_name_prefixes
|
4456
|
+
# If you specify this parameter, then only log events in the log
|
4457
|
+
# streams that have names that start with the prefixes that you
|
4458
|
+
# specify here are included in the Live Tail session.
|
4459
|
+
#
|
4460
|
+
# <note markdown="1"> You can specify this parameter only if you specify only one log
|
4461
|
+
# group in `logGroupIdentifiers`.
|
4462
|
+
#
|
4463
|
+
# </note>
|
4464
|
+
# @return [Array<String>]
|
4465
|
+
#
|
4466
|
+
# @!attribute [rw] log_event_filter_pattern
|
4467
|
+
# An optional pattern to use to filter the results to include only log
|
4468
|
+
# events that match the pattern. For example, a filter pattern of
|
4469
|
+
# `error 404` causes only log events that include both `error` and
|
4470
|
+
# `404` to be included in the Live Tail stream.
|
4471
|
+
#
|
4472
|
+
# Regular expression filter patterns are supported.
|
4473
|
+
#
|
4474
|
+
# For more information about filter pattern syntax, see [Filter and
|
4475
|
+
# Pattern Syntax][1].
|
4476
|
+
#
|
4477
|
+
#
|
4478
|
+
#
|
4479
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/FilterAndPatternSyntax.html
|
4480
|
+
# @return [String]
|
4481
|
+
#
|
4482
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/StartLiveTailRequest AWS API Documentation
|
4483
|
+
#
|
4484
|
+
class StartLiveTailRequest < Struct.new(
|
4485
|
+
:log_group_identifiers,
|
4486
|
+
:log_stream_names,
|
4487
|
+
:log_stream_name_prefixes,
|
4488
|
+
:log_event_filter_pattern)
|
4489
|
+
SENSITIVE = []
|
4490
|
+
include Aws::Structure
|
4491
|
+
end
|
4492
|
+
|
4493
|
+
# @!attribute [rw] response_stream
|
4494
|
+
# An object that includes the stream returned by your request. It can
|
4495
|
+
# include both log events and exceptions.
|
4496
|
+
# @return [Types::StartLiveTailResponseStream]
|
4497
|
+
#
|
4498
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/StartLiveTailResponse AWS API Documentation
|
4499
|
+
#
|
4500
|
+
class StartLiveTailResponse < Struct.new(
|
4501
|
+
:response_stream)
|
4502
|
+
SENSITIVE = []
|
4503
|
+
include Aws::Structure
|
4504
|
+
end
|
4505
|
+
|
4254
4506
|
# @!attribute [rw] log_group_name
|
4255
4507
|
# The log group on which to perform the query.
|
4256
4508
|
#
|
@@ -4693,5 +4945,30 @@ module Aws::CloudWatchLogs
|
|
4693
4945
|
#
|
4694
4946
|
class ValidationException < Aws::EmptyStructure; end
|
4695
4947
|
|
4948
|
+
# This object includes the stream returned by your [StartLiveTail][1]
|
4949
|
+
# request.
|
4950
|
+
#
|
4951
|
+
#
|
4952
|
+
#
|
4953
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_StartLiveTail.html
|
4954
|
+
#
|
4955
|
+
# EventStream is an Enumerator of Events.
|
4956
|
+
# #event_types #=> Array, returns all modeled event types in the stream
|
4957
|
+
#
|
4958
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/StartLiveTailResponseStream AWS API Documentation
|
4959
|
+
#
|
4960
|
+
class StartLiveTailResponseStream < Enumerator
|
4961
|
+
|
4962
|
+
def event_types
|
4963
|
+
[
|
4964
|
+
:session_start,
|
4965
|
+
:session_update,
|
4966
|
+
:session_timeout_exception,
|
4967
|
+
:session_streaming_exception
|
4968
|
+
]
|
4969
|
+
end
|
4970
|
+
|
4971
|
+
end
|
4972
|
+
|
4696
4973
|
end
|
4697
4974
|
end
|
@@ -21,6 +21,7 @@ require_relative 'aws-sdk-cloudwatchlogs/endpoint_parameters'
|
|
21
21
|
require_relative 'aws-sdk-cloudwatchlogs/endpoint_provider'
|
22
22
|
require_relative 'aws-sdk-cloudwatchlogs/endpoints'
|
23
23
|
require_relative 'aws-sdk-cloudwatchlogs/customizations'
|
24
|
+
require_relative 'aws-sdk-cloudwatchlogs/event_streams'
|
24
25
|
|
25
26
|
# This module provides support for Amazon CloudWatch Logs. This module is available in the
|
26
27
|
# `aws-sdk-cloudwatchlogs` gem.
|
@@ -52,6 +53,6 @@ require_relative 'aws-sdk-cloudwatchlogs/customizations'
|
|
52
53
|
# @!group service
|
53
54
|
module Aws::CloudWatchLogs
|
54
55
|
|
55
|
-
GEM_VERSION = '1.
|
56
|
+
GEM_VERSION = '1.76.0'
|
56
57
|
|
57
58
|
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.
|
4
|
+
version: 1.76.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-
|
11
|
+
date: 2023-12-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk-core
|
@@ -63,6 +63,7 @@ files:
|
|
63
63
|
- lib/aws-sdk-cloudwatchlogs/endpoint_provider.rb
|
64
64
|
- lib/aws-sdk-cloudwatchlogs/endpoints.rb
|
65
65
|
- lib/aws-sdk-cloudwatchlogs/errors.rb
|
66
|
+
- lib/aws-sdk-cloudwatchlogs/event_streams.rb
|
66
67
|
- lib/aws-sdk-cloudwatchlogs/plugins/endpoints.rb
|
67
68
|
- lib/aws-sdk-cloudwatchlogs/resource.rb
|
68
69
|
- lib/aws-sdk-cloudwatchlogs/types.rb
|