aws-sdk-cloudwatchlogs 1.102.0 → 1.104.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +10 -0
- data/VERSION +1 -1
- data/lib/aws-sdk-cloudwatchlogs/client.rb +1331 -39
- data/lib/aws-sdk-cloudwatchlogs/client_api.rb +693 -0
- data/lib/aws-sdk-cloudwatchlogs/types.rb +2564 -73
- data/lib/aws-sdk-cloudwatchlogs.rb +1 -1
- data/sig/client.rbs +428 -7
- data/sig/types.rbs +495 -4
- metadata +2 -2
@@ -1109,9 +1109,10 @@ module Aws::CloudWatchLogs
|
|
1109
1109
|
req.send_request(options)
|
1110
1110
|
end
|
1111
1111
|
|
1112
|
-
# Deletes a CloudWatch Logs account policy. This stops the
|
1113
|
-
# applying to
|
1114
|
-
#
|
1112
|
+
# Deletes a CloudWatch Logs account policy. This stops the account-wide
|
1113
|
+
# policy from applying to log groups in the account. If you delete a
|
1114
|
+
# data protection policy or subscription filter policy, any log-group
|
1115
|
+
# level policies of those types remain in effect.
|
1115
1116
|
#
|
1116
1117
|
# To use this operation, you must be signed on with the correct
|
1117
1118
|
# permissions depending on the type of policy that you are deleting.
|
@@ -1124,6 +1125,16 @@ module Aws::CloudWatchLogs
|
|
1124
1125
|
# `logs:DeleteSubscriptionFilter` and `logs:DeleteAccountPolicy`
|
1125
1126
|
# permissions.
|
1126
1127
|
#
|
1128
|
+
# * To delete a transformer policy, you must have the
|
1129
|
+
# `logs:DeleteTransformer` and `logs:DeleteAccountPolicy` permissions.
|
1130
|
+
#
|
1131
|
+
# * To delete a field index policy, you must have the
|
1132
|
+
# `logs:DeleteIndexPolicy` and `logs:DeleteAccountPolicy` permissions.
|
1133
|
+
#
|
1134
|
+
# If you delete a field index policy, the indexing of the log events
|
1135
|
+
# that happened before you deleted the policy will still be used for up
|
1136
|
+
# to 30 days to improve CloudWatch Logs Insights queries.
|
1137
|
+
#
|
1127
1138
|
# @option params [required, String] :policy_name
|
1128
1139
|
# The name of the policy to delete.
|
1129
1140
|
#
|
@@ -1136,7 +1147,7 @@ module Aws::CloudWatchLogs
|
|
1136
1147
|
#
|
1137
1148
|
# resp = client.delete_account_policy({
|
1138
1149
|
# policy_name: "PolicyName", # required
|
1139
|
-
# policy_type: "DATA_PROTECTION_POLICY", # required, accepts DATA_PROTECTION_POLICY, SUBSCRIPTION_FILTER_POLICY
|
1150
|
+
# policy_type: "DATA_PROTECTION_POLICY", # required, accepts DATA_PROTECTION_POLICY, SUBSCRIPTION_FILTER_POLICY, FIELD_INDEX_POLICY, TRANSFORMER_POLICY
|
1140
1151
|
# })
|
1141
1152
|
#
|
1142
1153
|
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/DeleteAccountPolicy AWS API Documentation
|
@@ -1331,6 +1342,83 @@ module Aws::CloudWatchLogs
|
|
1331
1342
|
req.send_request(options)
|
1332
1343
|
end
|
1333
1344
|
|
1345
|
+
# Deletes a log-group level field index policy that was applied to a
|
1346
|
+
# single log group. The indexing of the log events that happened before
|
1347
|
+
# you delete the policy will still be used for as many as 30 days to
|
1348
|
+
# improve CloudWatch Logs Insights queries.
|
1349
|
+
#
|
1350
|
+
# You can't use this operation to delete an account-level index policy.
|
1351
|
+
# Instead, use [DeletAccountPolicy][1].
|
1352
|
+
#
|
1353
|
+
# If you delete a log-group level field index policy and there is an
|
1354
|
+
# account-level field index policy, in a few minutes the log group
|
1355
|
+
# begins using that account-wide policy to index new incoming log
|
1356
|
+
# events.
|
1357
|
+
#
|
1358
|
+
#
|
1359
|
+
#
|
1360
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_DeleteAccountPolicy.html
|
1361
|
+
#
|
1362
|
+
# @option params [required, String] :log_group_identifier
|
1363
|
+
# The log group to delete the index policy for. You can specify either
|
1364
|
+
# the name or the ARN of the log group.
|
1365
|
+
#
|
1366
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1367
|
+
#
|
1368
|
+
# @example Request syntax with placeholder values
|
1369
|
+
#
|
1370
|
+
# resp = client.delete_index_policy({
|
1371
|
+
# log_group_identifier: "LogGroupIdentifier", # required
|
1372
|
+
# })
|
1373
|
+
#
|
1374
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/DeleteIndexPolicy AWS API Documentation
|
1375
|
+
#
|
1376
|
+
# @overload delete_index_policy(params = {})
|
1377
|
+
# @param [Hash] params ({})
|
1378
|
+
def delete_index_policy(params = {}, options = {})
|
1379
|
+
req = build_request(:delete_index_policy, params)
|
1380
|
+
req.send_request(options)
|
1381
|
+
end
|
1382
|
+
|
1383
|
+
# Deletes the integration between CloudWatch Logs and OpenSearch
|
1384
|
+
# Service. If your integration has active vended logs dashboards, you
|
1385
|
+
# must specify `true` for the `force` parameter, otherwise the operation
|
1386
|
+
# will fail. If you delete the integration by setting `force` to `true`,
|
1387
|
+
# all your vended logs dashboards powered by OpenSearch Service will be
|
1388
|
+
# deleted and the data that was on them will no longer be accessible.
|
1389
|
+
#
|
1390
|
+
# @option params [required, String] :integration_name
|
1391
|
+
# The name of the integration to delete. To find the name of your
|
1392
|
+
# integration, use [ListIntegrations][1].
|
1393
|
+
#
|
1394
|
+
#
|
1395
|
+
#
|
1396
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListIntegrations.html
|
1397
|
+
#
|
1398
|
+
# @option params [Boolean] :force
|
1399
|
+
# Specify `true` to force the deletion of the integration even if vended
|
1400
|
+
# logs dashboards currently exist.
|
1401
|
+
#
|
1402
|
+
# The default is `false`.
|
1403
|
+
#
|
1404
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1405
|
+
#
|
1406
|
+
# @example Request syntax with placeholder values
|
1407
|
+
#
|
1408
|
+
# resp = client.delete_integration({
|
1409
|
+
# integration_name: "IntegrationName", # required
|
1410
|
+
# force: false,
|
1411
|
+
# })
|
1412
|
+
#
|
1413
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/DeleteIntegration AWS API Documentation
|
1414
|
+
#
|
1415
|
+
# @overload delete_integration(params = {})
|
1416
|
+
# @param [Hash] params ({})
|
1417
|
+
def delete_integration(params = {}, options = {})
|
1418
|
+
req = build_request(:delete_integration, params)
|
1419
|
+
req.send_request(options)
|
1420
|
+
end
|
1421
|
+
|
1334
1422
|
# Deletes the specified CloudWatch Logs anomaly detector.
|
1335
1423
|
#
|
1336
1424
|
# @option params [required, String] :anomaly_detector_arn
|
@@ -1551,6 +1639,39 @@ module Aws::CloudWatchLogs
|
|
1551
1639
|
req.send_request(options)
|
1552
1640
|
end
|
1553
1641
|
|
1642
|
+
# Deletes the log transformer for the specified log group. As soon as
|
1643
|
+
# you do this, the transformation of incoming log events according to
|
1644
|
+
# that transformer stops. If this account has an account-level
|
1645
|
+
# transformer that applies to this log group, the log group begins using
|
1646
|
+
# that account-level transformer when this log-group level transformer
|
1647
|
+
# is deleted.
|
1648
|
+
#
|
1649
|
+
# After you delete a transformer, be sure to edit any metric filters or
|
1650
|
+
# subscription filters that relied on the transformed versions of the
|
1651
|
+
# log events.
|
1652
|
+
#
|
1653
|
+
# @option params [required, String] :log_group_identifier
|
1654
|
+
# Specify either the name or ARN of the log group to delete the
|
1655
|
+
# transformer for. If the log group is in a source account and you are
|
1656
|
+
# using a monitoring account, you must use the log group ARN.
|
1657
|
+
#
|
1658
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
1659
|
+
#
|
1660
|
+
# @example Request syntax with placeholder values
|
1661
|
+
#
|
1662
|
+
# resp = client.delete_transformer({
|
1663
|
+
# log_group_identifier: "LogGroupIdentifier", # required
|
1664
|
+
# })
|
1665
|
+
#
|
1666
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/DeleteTransformer AWS API Documentation
|
1667
|
+
#
|
1668
|
+
# @overload delete_transformer(params = {})
|
1669
|
+
# @param [Hash] params ({})
|
1670
|
+
def delete_transformer(params = {}, options = {})
|
1671
|
+
req = build_request(:delete_transformer, params)
|
1672
|
+
req.send_request(options)
|
1673
|
+
end
|
1674
|
+
|
1554
1675
|
# Returns a list of all CloudWatch Logs account policies in the account.
|
1555
1676
|
#
|
1556
1677
|
# @option params [required, String] :policy_type
|
@@ -1571,16 +1692,22 @@ module Aws::CloudWatchLogs
|
|
1571
1692
|
# If you omit this parameter, only the policy in the current account is
|
1572
1693
|
# returned.
|
1573
1694
|
#
|
1695
|
+
# @option params [String] :next_token
|
1696
|
+
# The token for the next set of items to return. (You received this
|
1697
|
+
# token from a previous call.)
|
1698
|
+
#
|
1574
1699
|
# @return [Types::DescribeAccountPoliciesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
1575
1700
|
#
|
1576
1701
|
# * {Types::DescribeAccountPoliciesResponse#account_policies #account_policies} => Array<Types::AccountPolicy>
|
1702
|
+
# * {Types::DescribeAccountPoliciesResponse#next_token #next_token} => String
|
1577
1703
|
#
|
1578
1704
|
# @example Request syntax with placeholder values
|
1579
1705
|
#
|
1580
1706
|
# resp = client.describe_account_policies({
|
1581
|
-
# policy_type: "DATA_PROTECTION_POLICY", # required, accepts DATA_PROTECTION_POLICY, SUBSCRIPTION_FILTER_POLICY
|
1707
|
+
# policy_type: "DATA_PROTECTION_POLICY", # required, accepts DATA_PROTECTION_POLICY, SUBSCRIPTION_FILTER_POLICY, FIELD_INDEX_POLICY, TRANSFORMER_POLICY
|
1582
1708
|
# policy_name: "PolicyName",
|
1583
1709
|
# account_identifiers: ["AccountId"],
|
1710
|
+
# next_token: "NextToken",
|
1584
1711
|
# })
|
1585
1712
|
#
|
1586
1713
|
# @example Response structure
|
@@ -1589,10 +1716,11 @@ module Aws::CloudWatchLogs
|
|
1589
1716
|
# resp.account_policies[0].policy_name #=> String
|
1590
1717
|
# resp.account_policies[0].policy_document #=> String
|
1591
1718
|
# resp.account_policies[0].last_updated_time #=> Integer
|
1592
|
-
# resp.account_policies[0].policy_type #=> String, one of "DATA_PROTECTION_POLICY", "SUBSCRIPTION_FILTER_POLICY"
|
1719
|
+
# resp.account_policies[0].policy_type #=> String, one of "DATA_PROTECTION_POLICY", "SUBSCRIPTION_FILTER_POLICY", "FIELD_INDEX_POLICY", "TRANSFORMER_POLICY"
|
1593
1720
|
# resp.account_policies[0].scope #=> String, one of "ALL"
|
1594
1721
|
# resp.account_policies[0].selection_criteria #=> String
|
1595
1722
|
# resp.account_policies[0].account_id #=> String
|
1723
|
+
# resp.next_token #=> String
|
1596
1724
|
#
|
1597
1725
|
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/DescribeAccountPolicies AWS API Documentation
|
1598
1726
|
#
|
@@ -1958,6 +2086,110 @@ module Aws::CloudWatchLogs
|
|
1958
2086
|
req.send_request(options)
|
1959
2087
|
end
|
1960
2088
|
|
2089
|
+
# Returns a list of field indexes listed in the field index policies of
|
2090
|
+
# one or more log groups. For more information about field index
|
2091
|
+
# policies, see [PutIndexPolicy][1].
|
2092
|
+
#
|
2093
|
+
#
|
2094
|
+
#
|
2095
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutIndexPolicy.html
|
2096
|
+
#
|
2097
|
+
# @option params [required, Array<String>] :log_group_identifiers
|
2098
|
+
# An array containing the names or ARNs of the log groups that you want
|
2099
|
+
# to retrieve field indexes for.
|
2100
|
+
#
|
2101
|
+
# @option params [String] :next_token
|
2102
|
+
# The token for the next set of items to return. The token expires after
|
2103
|
+
# 24 hours.
|
2104
|
+
#
|
2105
|
+
# @return [Types::DescribeFieldIndexesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
2106
|
+
#
|
2107
|
+
# * {Types::DescribeFieldIndexesResponse#field_indexes #field_indexes} => Array<Types::FieldIndex>
|
2108
|
+
# * {Types::DescribeFieldIndexesResponse#next_token #next_token} => String
|
2109
|
+
#
|
2110
|
+
# @example Request syntax with placeholder values
|
2111
|
+
#
|
2112
|
+
# resp = client.describe_field_indexes({
|
2113
|
+
# log_group_identifiers: ["LogGroupIdentifier"], # required
|
2114
|
+
# next_token: "NextToken",
|
2115
|
+
# })
|
2116
|
+
#
|
2117
|
+
# @example Response structure
|
2118
|
+
#
|
2119
|
+
# resp.field_indexes #=> Array
|
2120
|
+
# resp.field_indexes[0].log_group_identifier #=> String
|
2121
|
+
# resp.field_indexes[0].field_index_name #=> String
|
2122
|
+
# resp.field_indexes[0].last_scan_time #=> Integer
|
2123
|
+
# resp.field_indexes[0].first_event_time #=> Integer
|
2124
|
+
# resp.field_indexes[0].last_event_time #=> Integer
|
2125
|
+
# resp.next_token #=> String
|
2126
|
+
#
|
2127
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/DescribeFieldIndexes AWS API Documentation
|
2128
|
+
#
|
2129
|
+
# @overload describe_field_indexes(params = {})
|
2130
|
+
# @param [Hash] params ({})
|
2131
|
+
def describe_field_indexes(params = {}, options = {})
|
2132
|
+
req = build_request(:describe_field_indexes, params)
|
2133
|
+
req.send_request(options)
|
2134
|
+
end
|
2135
|
+
|
2136
|
+
# Returns the field index policies of one or more log groups. For more
|
2137
|
+
# information about field index policies, see [PutIndexPolicy][1].
|
2138
|
+
#
|
2139
|
+
# If a specified log group has a log-group level index policy, that
|
2140
|
+
# policy is returned by this operation.
|
2141
|
+
#
|
2142
|
+
# If a specified log group doesn't have a log-group level index policy,
|
2143
|
+
# but an account-wide index policy applies to it, that account-wide
|
2144
|
+
# policy is returned by this operation.
|
2145
|
+
#
|
2146
|
+
# To find information about only account-level policies, use
|
2147
|
+
# [DescribeAccountPolicies][2] instead.
|
2148
|
+
#
|
2149
|
+
#
|
2150
|
+
#
|
2151
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutIndexPolicy.html
|
2152
|
+
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_DescribeAccountPolicies.html
|
2153
|
+
#
|
2154
|
+
# @option params [required, Array<String>] :log_group_identifiers
|
2155
|
+
# An array containing the name or ARN of the log group that you want to
|
2156
|
+
# retrieve field index policies for.
|
2157
|
+
#
|
2158
|
+
# @option params [String] :next_token
|
2159
|
+
# The token for the next set of items to return. The token expires after
|
2160
|
+
# 24 hours.
|
2161
|
+
#
|
2162
|
+
# @return [Types::DescribeIndexPoliciesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
2163
|
+
#
|
2164
|
+
# * {Types::DescribeIndexPoliciesResponse#index_policies #index_policies} => Array<Types::IndexPolicy>
|
2165
|
+
# * {Types::DescribeIndexPoliciesResponse#next_token #next_token} => String
|
2166
|
+
#
|
2167
|
+
# @example Request syntax with placeholder values
|
2168
|
+
#
|
2169
|
+
# resp = client.describe_index_policies({
|
2170
|
+
# log_group_identifiers: ["LogGroupIdentifier"], # required
|
2171
|
+
# next_token: "NextToken",
|
2172
|
+
# })
|
2173
|
+
#
|
2174
|
+
# @example Response structure
|
2175
|
+
#
|
2176
|
+
# resp.index_policies #=> Array
|
2177
|
+
# resp.index_policies[0].log_group_identifier #=> String
|
2178
|
+
# resp.index_policies[0].last_update_time #=> Integer
|
2179
|
+
# resp.index_policies[0].policy_document #=> String
|
2180
|
+
# resp.index_policies[0].policy_name #=> String
|
2181
|
+
# resp.index_policies[0].source #=> String, one of "ACCOUNT", "LOG_GROUP"
|
2182
|
+
# resp.next_token #=> String
|
2183
|
+
#
|
2184
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/DescribeIndexPolicies AWS API Documentation
|
2185
|
+
#
|
2186
|
+
# @overload describe_index_policies(params = {})
|
2187
|
+
# @param [Hash] params ({})
|
2188
|
+
def describe_index_policies(params = {}, options = {})
|
2189
|
+
req = build_request(:describe_index_policies, params)
|
2190
|
+
req.send_request(options)
|
2191
|
+
end
|
2192
|
+
|
1961
2193
|
# Lists the specified log groups. You can list all your log groups or
|
1962
2194
|
# filter the results by prefix. The results are ASCII-sorted by log
|
1963
2195
|
# group name.
|
@@ -2260,6 +2492,7 @@ module Aws::CloudWatchLogs
|
|
2260
2492
|
# resp.metric_filters[0].metric_transformations[0].unit #=> String, one of "Seconds", "Microseconds", "Milliseconds", "Bytes", "Kilobytes", "Megabytes", "Gigabytes", "Terabytes", "Bits", "Kilobits", "Megabits", "Gigabits", "Terabits", "Percent", "Count", "Bytes/Second", "Kilobytes/Second", "Megabytes/Second", "Gigabytes/Second", "Terabytes/Second", "Bits/Second", "Kilobits/Second", "Megabits/Second", "Gigabits/Second", "Terabits/Second", "Count/Second", "None"
|
2261
2493
|
# resp.metric_filters[0].creation_time #=> Integer
|
2262
2494
|
# resp.metric_filters[0].log_group_name #=> String
|
2495
|
+
# resp.metric_filters[0].apply_on_transformed_logs #=> Boolean
|
2263
2496
|
# resp.next_token #=> String
|
2264
2497
|
#
|
2265
2498
|
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/DescribeMetricFilters AWS API Documentation
|
@@ -2291,6 +2524,10 @@ module Aws::CloudWatchLogs
|
|
2291
2524
|
# The token for the next set of items to return. The token expires after
|
2292
2525
|
# 24 hours.
|
2293
2526
|
#
|
2527
|
+
# @option params [String] :query_language
|
2528
|
+
# Limits the returned queries to only the queries that use the specified
|
2529
|
+
# query language.
|
2530
|
+
#
|
2294
2531
|
# @return [Types::DescribeQueriesResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
2295
2532
|
#
|
2296
2533
|
# * {Types::DescribeQueriesResponse#queries #queries} => Array<Types::QueryInfo>
|
@@ -2303,11 +2540,13 @@ module Aws::CloudWatchLogs
|
|
2303
2540
|
# status: "Scheduled", # accepts Scheduled, Running, Complete, Failed, Cancelled, Timeout, Unknown
|
2304
2541
|
# max_results: 1,
|
2305
2542
|
# next_token: "NextToken",
|
2543
|
+
# query_language: "CWLI", # accepts CWLI, SQL, PPL
|
2306
2544
|
# })
|
2307
2545
|
#
|
2308
2546
|
# @example Response structure
|
2309
2547
|
#
|
2310
2548
|
# resp.queries #=> Array
|
2549
|
+
# resp.queries[0].query_language #=> String, one of "CWLI", "SQL", "PPL"
|
2311
2550
|
# resp.queries[0].query_id #=> String
|
2312
2551
|
# resp.queries[0].query_string #=> String
|
2313
2552
|
# resp.queries[0].status #=> String, one of "Scheduled", "Running", "Complete", "Failed", "Cancelled", "Timeout", "Unknown"
|
@@ -2333,6 +2572,15 @@ module Aws::CloudWatchLogs
|
|
2333
2572
|
# results to only the query definitions that have names that start with
|
2334
2573
|
# a certain string.
|
2335
2574
|
#
|
2575
|
+
# @option params [String] :query_language
|
2576
|
+
# The query language used for this query. For more information about the
|
2577
|
+
# query languages that CloudWatch Logs supports, see [Supported query
|
2578
|
+
# languages][1].
|
2579
|
+
#
|
2580
|
+
#
|
2581
|
+
#
|
2582
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CWL_AnalyzeLogData_Languages.html
|
2583
|
+
#
|
2336
2584
|
# @option params [String] :query_definition_name_prefix
|
2337
2585
|
# Use this parameter to filter your results to only the query
|
2338
2586
|
# definitions that have names that start with the prefix you specify.
|
@@ -2353,6 +2601,7 @@ module Aws::CloudWatchLogs
|
|
2353
2601
|
# @example Request syntax with placeholder values
|
2354
2602
|
#
|
2355
2603
|
# resp = client.describe_query_definitions({
|
2604
|
+
# query_language: "CWLI", # accepts CWLI, SQL, PPL
|
2356
2605
|
# query_definition_name_prefix: "QueryDefinitionName",
|
2357
2606
|
# max_results: 1,
|
2358
2607
|
# next_token: "NextToken",
|
@@ -2361,6 +2610,7 @@ module Aws::CloudWatchLogs
|
|
2361
2610
|
# @example Response structure
|
2362
2611
|
#
|
2363
2612
|
# resp.query_definitions #=> Array
|
2613
|
+
# resp.query_definitions[0].query_language #=> String, one of "CWLI", "SQL", "PPL"
|
2364
2614
|
# resp.query_definitions[0].query_definition_id #=> String
|
2365
2615
|
# resp.query_definitions[0].name #=> String
|
2366
2616
|
# resp.query_definitions[0].query_string #=> String
|
@@ -2461,6 +2711,7 @@ module Aws::CloudWatchLogs
|
|
2461
2711
|
# resp.subscription_filters[0].destination_arn #=> String
|
2462
2712
|
# resp.subscription_filters[0].role_arn #=> String
|
2463
2713
|
# resp.subscription_filters[0].distribution #=> String, one of "Random", "ByLogStream"
|
2714
|
+
# resp.subscription_filters[0].apply_on_transformed_logs #=> Boolean
|
2464
2715
|
# resp.subscription_filters[0].creation_time #=> Integer
|
2465
2716
|
# resp.next_token #=> String
|
2466
2717
|
#
|
@@ -2906,6 +3157,72 @@ module Aws::CloudWatchLogs
|
|
2906
3157
|
req.send_request(options)
|
2907
3158
|
end
|
2908
3159
|
|
3160
|
+
# Returns information about one integration between CloudWatch Logs and
|
3161
|
+
# OpenSearch Service.
|
3162
|
+
#
|
3163
|
+
# @option params [required, String] :integration_name
|
3164
|
+
# The name of the integration that you want to find information about.
|
3165
|
+
# To find the name of your integration, use [ListIntegrations][1]
|
3166
|
+
#
|
3167
|
+
#
|
3168
|
+
#
|
3169
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_ListIntegrations.html
|
3170
|
+
#
|
3171
|
+
# @return [Types::GetIntegrationResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
3172
|
+
#
|
3173
|
+
# * {Types::GetIntegrationResponse#integration_name #integration_name} => String
|
3174
|
+
# * {Types::GetIntegrationResponse#integration_type #integration_type} => String
|
3175
|
+
# * {Types::GetIntegrationResponse#integration_status #integration_status} => String
|
3176
|
+
# * {Types::GetIntegrationResponse#integration_details #integration_details} => Types::IntegrationDetails
|
3177
|
+
#
|
3178
|
+
# @example Request syntax with placeholder values
|
3179
|
+
#
|
3180
|
+
# resp = client.get_integration({
|
3181
|
+
# integration_name: "IntegrationName", # required
|
3182
|
+
# })
|
3183
|
+
#
|
3184
|
+
# @example Response structure
|
3185
|
+
#
|
3186
|
+
# resp.integration_name #=> String
|
3187
|
+
# resp.integration_type #=> String, one of "OPENSEARCH"
|
3188
|
+
# resp.integration_status #=> String, one of "PROVISIONING", "ACTIVE", "FAILED"
|
3189
|
+
# resp.integration_details.open_search_integration_details.data_source.data_source_name #=> String
|
3190
|
+
# resp.integration_details.open_search_integration_details.data_source.status.status #=> String, one of "ACTIVE", "NOT_FOUND", "ERROR"
|
3191
|
+
# resp.integration_details.open_search_integration_details.data_source.status.status_message #=> String
|
3192
|
+
# resp.integration_details.open_search_integration_details.application.application_endpoint #=> String
|
3193
|
+
# resp.integration_details.open_search_integration_details.application.application_arn #=> String
|
3194
|
+
# resp.integration_details.open_search_integration_details.application.application_id #=> String
|
3195
|
+
# resp.integration_details.open_search_integration_details.application.status.status #=> String, one of "ACTIVE", "NOT_FOUND", "ERROR"
|
3196
|
+
# resp.integration_details.open_search_integration_details.application.status.status_message #=> String
|
3197
|
+
# resp.integration_details.open_search_integration_details.collection.collection_endpoint #=> String
|
3198
|
+
# resp.integration_details.open_search_integration_details.collection.collection_arn #=> String
|
3199
|
+
# resp.integration_details.open_search_integration_details.collection.status.status #=> String, one of "ACTIVE", "NOT_FOUND", "ERROR"
|
3200
|
+
# resp.integration_details.open_search_integration_details.collection.status.status_message #=> String
|
3201
|
+
# resp.integration_details.open_search_integration_details.workspace.workspace_id #=> String
|
3202
|
+
# resp.integration_details.open_search_integration_details.workspace.status.status #=> String, one of "ACTIVE", "NOT_FOUND", "ERROR"
|
3203
|
+
# resp.integration_details.open_search_integration_details.workspace.status.status_message #=> String
|
3204
|
+
# resp.integration_details.open_search_integration_details.encryption_policy.policy_name #=> String
|
3205
|
+
# resp.integration_details.open_search_integration_details.encryption_policy.status.status #=> String, one of "ACTIVE", "NOT_FOUND", "ERROR"
|
3206
|
+
# resp.integration_details.open_search_integration_details.encryption_policy.status.status_message #=> String
|
3207
|
+
# resp.integration_details.open_search_integration_details.network_policy.policy_name #=> String
|
3208
|
+
# resp.integration_details.open_search_integration_details.network_policy.status.status #=> String, one of "ACTIVE", "NOT_FOUND", "ERROR"
|
3209
|
+
# resp.integration_details.open_search_integration_details.network_policy.status.status_message #=> String
|
3210
|
+
# resp.integration_details.open_search_integration_details.access_policy.policy_name #=> String
|
3211
|
+
# resp.integration_details.open_search_integration_details.access_policy.status.status #=> String, one of "ACTIVE", "NOT_FOUND", "ERROR"
|
3212
|
+
# resp.integration_details.open_search_integration_details.access_policy.status.status_message #=> String
|
3213
|
+
# resp.integration_details.open_search_integration_details.lifecycle_policy.policy_name #=> String
|
3214
|
+
# resp.integration_details.open_search_integration_details.lifecycle_policy.status.status #=> String, one of "ACTIVE", "NOT_FOUND", "ERROR"
|
3215
|
+
# resp.integration_details.open_search_integration_details.lifecycle_policy.status.status_message #=> String
|
3216
|
+
#
|
3217
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/GetIntegration AWS API Documentation
|
3218
|
+
#
|
3219
|
+
# @overload get_integration(params = {})
|
3220
|
+
# @param [Hash] params ({})
|
3221
|
+
def get_integration(params = {}, options = {})
|
3222
|
+
req = build_request(:get_integration, params)
|
3223
|
+
req.send_request(options)
|
3224
|
+
end
|
3225
|
+
|
2909
3226
|
# Retrieves information about the log anomaly detector that you specify.
|
2910
3227
|
#
|
2911
3228
|
# @option params [required, String] :anomaly_detector_arn
|
@@ -3236,6 +3553,7 @@ module Aws::CloudWatchLogs
|
|
3236
3553
|
#
|
3237
3554
|
# @return [Types::GetQueryResultsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
3238
3555
|
#
|
3556
|
+
# * {Types::GetQueryResultsResponse#query_language #query_language} => String
|
3239
3557
|
# * {Types::GetQueryResultsResponse#results #results} => Array<Array<Types::ResultField>>
|
3240
3558
|
# * {Types::GetQueryResultsResponse#statistics #statistics} => Types::QueryStatistics
|
3241
3559
|
# * {Types::GetQueryResultsResponse#status #status} => String
|
@@ -3249,13 +3567,17 @@ module Aws::CloudWatchLogs
|
|
3249
3567
|
#
|
3250
3568
|
# @example Response structure
|
3251
3569
|
#
|
3570
|
+
# resp.query_language #=> String, one of "CWLI", "SQL", "PPL"
|
3252
3571
|
# resp.results #=> Array
|
3253
3572
|
# resp.results[0] #=> Array
|
3254
3573
|
# resp.results[0][0].field #=> String
|
3255
3574
|
# resp.results[0][0].value #=> String
|
3256
3575
|
# resp.statistics.records_matched #=> Float
|
3257
3576
|
# resp.statistics.records_scanned #=> Float
|
3577
|
+
# resp.statistics.estimated_records_skipped #=> Float
|
3258
3578
|
# resp.statistics.bytes_scanned #=> Float
|
3579
|
+
# resp.statistics.estimated_bytes_skipped #=> Float
|
3580
|
+
# resp.statistics.log_groups_scanned #=> Float
|
3259
3581
|
# resp.status #=> String, one of "Scheduled", "Running", "Complete", "Failed", "Cancelled", "Timeout", "Unknown"
|
3260
3582
|
# resp.encryption_key #=> String
|
3261
3583
|
#
|
@@ -3268,6 +3590,120 @@ module Aws::CloudWatchLogs
|
|
3268
3590
|
req.send_request(options)
|
3269
3591
|
end
|
3270
3592
|
|
3593
|
+
# Returns the information about the log transformer associated with this
|
3594
|
+
# log group.
|
3595
|
+
#
|
3596
|
+
# This operation returns data only for transformers created at the log
|
3597
|
+
# group level. To get information for an account-level transformer, use
|
3598
|
+
# [DescribeAccountPolicies][1].
|
3599
|
+
#
|
3600
|
+
#
|
3601
|
+
#
|
3602
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_DescribeAccountPolicies.html
|
3603
|
+
#
|
3604
|
+
# @option params [required, String] :log_group_identifier
|
3605
|
+
# Specify either the name or ARN of the log group to return transformer
|
3606
|
+
# information for. If the log group is in a source account and you are
|
3607
|
+
# using a monitoring account, you must use the log group ARN.
|
3608
|
+
#
|
3609
|
+
# @return [Types::GetTransformerResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
3610
|
+
#
|
3611
|
+
# * {Types::GetTransformerResponse#log_group_identifier #log_group_identifier} => String
|
3612
|
+
# * {Types::GetTransformerResponse#creation_time #creation_time} => Integer
|
3613
|
+
# * {Types::GetTransformerResponse#last_modified_time #last_modified_time} => Integer
|
3614
|
+
# * {Types::GetTransformerResponse#transformer_config #transformer_config} => Array<Types::Processor>
|
3615
|
+
#
|
3616
|
+
# @example Request syntax with placeholder values
|
3617
|
+
#
|
3618
|
+
# resp = client.get_transformer({
|
3619
|
+
# log_group_identifier: "LogGroupIdentifier", # required
|
3620
|
+
# })
|
3621
|
+
#
|
3622
|
+
# @example Response structure
|
3623
|
+
#
|
3624
|
+
# resp.log_group_identifier #=> String
|
3625
|
+
# resp.creation_time #=> Integer
|
3626
|
+
# resp.last_modified_time #=> Integer
|
3627
|
+
# resp.transformer_config #=> Array
|
3628
|
+
# resp.transformer_config[0].add_keys.entries #=> Array
|
3629
|
+
# resp.transformer_config[0].add_keys.entries[0].key #=> String
|
3630
|
+
# resp.transformer_config[0].add_keys.entries[0].value #=> String
|
3631
|
+
# resp.transformer_config[0].add_keys.entries[0].overwrite_if_exists #=> Boolean
|
3632
|
+
# resp.transformer_config[0].copy_value.entries #=> Array
|
3633
|
+
# resp.transformer_config[0].copy_value.entries[0].source #=> String
|
3634
|
+
# resp.transformer_config[0].copy_value.entries[0].target #=> String
|
3635
|
+
# resp.transformer_config[0].copy_value.entries[0].overwrite_if_exists #=> Boolean
|
3636
|
+
# resp.transformer_config[0].csv.quote_character #=> String
|
3637
|
+
# resp.transformer_config[0].csv.delimiter #=> String
|
3638
|
+
# resp.transformer_config[0].csv.columns #=> Array
|
3639
|
+
# resp.transformer_config[0].csv.columns[0] #=> String
|
3640
|
+
# resp.transformer_config[0].csv.source #=> String
|
3641
|
+
# resp.transformer_config[0].date_time_converter.source #=> String
|
3642
|
+
# resp.transformer_config[0].date_time_converter.target #=> String
|
3643
|
+
# resp.transformer_config[0].date_time_converter.target_format #=> String
|
3644
|
+
# resp.transformer_config[0].date_time_converter.match_patterns #=> Array
|
3645
|
+
# resp.transformer_config[0].date_time_converter.match_patterns[0] #=> String
|
3646
|
+
# resp.transformer_config[0].date_time_converter.source_timezone #=> String
|
3647
|
+
# resp.transformer_config[0].date_time_converter.target_timezone #=> String
|
3648
|
+
# resp.transformer_config[0].date_time_converter.locale #=> String
|
3649
|
+
# resp.transformer_config[0].delete_keys.with_keys #=> Array
|
3650
|
+
# resp.transformer_config[0].delete_keys.with_keys[0] #=> String
|
3651
|
+
# resp.transformer_config[0].grok.source #=> String
|
3652
|
+
# resp.transformer_config[0].grok.match #=> String
|
3653
|
+
# resp.transformer_config[0].list_to_map.source #=> String
|
3654
|
+
# resp.transformer_config[0].list_to_map.key #=> String
|
3655
|
+
# resp.transformer_config[0].list_to_map.value_key #=> String
|
3656
|
+
# resp.transformer_config[0].list_to_map.target #=> String
|
3657
|
+
# resp.transformer_config[0].list_to_map.flatten #=> Boolean
|
3658
|
+
# resp.transformer_config[0].list_to_map.flattened_element #=> String, one of "first", "last"
|
3659
|
+
# resp.transformer_config[0].lower_case_string.with_keys #=> Array
|
3660
|
+
# resp.transformer_config[0].lower_case_string.with_keys[0] #=> String
|
3661
|
+
# resp.transformer_config[0].move_keys.entries #=> Array
|
3662
|
+
# resp.transformer_config[0].move_keys.entries[0].source #=> String
|
3663
|
+
# resp.transformer_config[0].move_keys.entries[0].target #=> String
|
3664
|
+
# resp.transformer_config[0].move_keys.entries[0].overwrite_if_exists #=> Boolean
|
3665
|
+
# resp.transformer_config[0].parse_cloudfront.source #=> String
|
3666
|
+
# resp.transformer_config[0].parse_json.source #=> String
|
3667
|
+
# resp.transformer_config[0].parse_json.destination #=> String
|
3668
|
+
# resp.transformer_config[0].parse_key_value.source #=> String
|
3669
|
+
# resp.transformer_config[0].parse_key_value.destination #=> String
|
3670
|
+
# resp.transformer_config[0].parse_key_value.field_delimiter #=> String
|
3671
|
+
# resp.transformer_config[0].parse_key_value.key_value_delimiter #=> String
|
3672
|
+
# resp.transformer_config[0].parse_key_value.key_prefix #=> String
|
3673
|
+
# resp.transformer_config[0].parse_key_value.non_match_value #=> String
|
3674
|
+
# resp.transformer_config[0].parse_key_value.overwrite_if_exists #=> Boolean
|
3675
|
+
# resp.transformer_config[0].parse_route_53.source #=> String
|
3676
|
+
# resp.transformer_config[0].parse_postgres.source #=> String
|
3677
|
+
# resp.transformer_config[0].parse_vpc.source #=> String
|
3678
|
+
# resp.transformer_config[0].parse_waf.source #=> String
|
3679
|
+
# resp.transformer_config[0].rename_keys.entries #=> Array
|
3680
|
+
# resp.transformer_config[0].rename_keys.entries[0].key #=> String
|
3681
|
+
# resp.transformer_config[0].rename_keys.entries[0].rename_to #=> String
|
3682
|
+
# resp.transformer_config[0].rename_keys.entries[0].overwrite_if_exists #=> Boolean
|
3683
|
+
# resp.transformer_config[0].split_string.entries #=> Array
|
3684
|
+
# resp.transformer_config[0].split_string.entries[0].source #=> String
|
3685
|
+
# resp.transformer_config[0].split_string.entries[0].delimiter #=> String
|
3686
|
+
# resp.transformer_config[0].substitute_string.entries #=> Array
|
3687
|
+
# resp.transformer_config[0].substitute_string.entries[0].source #=> String
|
3688
|
+
# resp.transformer_config[0].substitute_string.entries[0].from #=> String
|
3689
|
+
# resp.transformer_config[0].substitute_string.entries[0].to #=> String
|
3690
|
+
# resp.transformer_config[0].trim_string.with_keys #=> Array
|
3691
|
+
# resp.transformer_config[0].trim_string.with_keys[0] #=> String
|
3692
|
+
# resp.transformer_config[0].type_converter.entries #=> Array
|
3693
|
+
# resp.transformer_config[0].type_converter.entries[0].key #=> String
|
3694
|
+
# resp.transformer_config[0].type_converter.entries[0].type #=> String, one of "boolean", "integer", "double", "string"
|
3695
|
+
# resp.transformer_config[0].upper_case_string.with_keys #=> Array
|
3696
|
+
# resp.transformer_config[0].upper_case_string.with_keys[0] #=> String
|
3697
|
+
#
|
3698
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/GetTransformer AWS API Documentation
|
3699
|
+
#
|
3700
|
+
# @overload get_transformer(params = {})
|
3701
|
+
# @param [Hash] params ({})
|
3702
|
+
def get_transformer(params = {}, options = {})
|
3703
|
+
req = build_request(:get_transformer, params)
|
3704
|
+
req.send_request(options)
|
3705
|
+
end
|
3706
|
+
|
3271
3707
|
# Returns a list of anomalies that log anomaly detectors have found. For
|
3272
3708
|
# details about the structure format of each anomaly object that is
|
3273
3709
|
# returned, see the example in this section.
|
@@ -3347,6 +3783,51 @@ module Aws::CloudWatchLogs
|
|
3347
3783
|
req.send_request(options)
|
3348
3784
|
end
|
3349
3785
|
|
3786
|
+
# Returns a list of integrations between CloudWatch Logs and other
|
3787
|
+
# services in this account. Currently, only one integration can be
|
3788
|
+
# created in an account, and this integration must be with OpenSearch
|
3789
|
+
# Service.
|
3790
|
+
#
|
3791
|
+
# @option params [String] :integration_name_prefix
|
3792
|
+
# To limit the results to integrations that start with a certain name
|
3793
|
+
# prefix, specify that name prefix here.
|
3794
|
+
#
|
3795
|
+
# @option params [String] :integration_type
|
3796
|
+
# To limit the results to integrations of a certain type, specify that
|
3797
|
+
# type here.
|
3798
|
+
#
|
3799
|
+
# @option params [String] :integration_status
|
3800
|
+
# To limit the results to integrations with a certain status, specify
|
3801
|
+
# that status here.
|
3802
|
+
#
|
3803
|
+
# @return [Types::ListIntegrationsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
3804
|
+
#
|
3805
|
+
# * {Types::ListIntegrationsResponse#integration_summaries #integration_summaries} => Array<Types::IntegrationSummary>
|
3806
|
+
#
|
3807
|
+
# @example Request syntax with placeholder values
|
3808
|
+
#
|
3809
|
+
# resp = client.list_integrations({
|
3810
|
+
# integration_name_prefix: "IntegrationNamePrefix",
|
3811
|
+
# integration_type: "OPENSEARCH", # accepts OPENSEARCH
|
3812
|
+
# integration_status: "PROVISIONING", # accepts PROVISIONING, ACTIVE, FAILED
|
3813
|
+
# })
|
3814
|
+
#
|
3815
|
+
# @example Response structure
|
3816
|
+
#
|
3817
|
+
# resp.integration_summaries #=> Array
|
3818
|
+
# resp.integration_summaries[0].integration_name #=> String
|
3819
|
+
# resp.integration_summaries[0].integration_type #=> String, one of "OPENSEARCH"
|
3820
|
+
# resp.integration_summaries[0].integration_status #=> String, one of "PROVISIONING", "ACTIVE", "FAILED"
|
3821
|
+
#
|
3822
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/ListIntegrations AWS API Documentation
|
3823
|
+
#
|
3824
|
+
# @overload list_integrations(params = {})
|
3825
|
+
# @param [Hash] params ({})
|
3826
|
+
def list_integrations(params = {}, options = {})
|
3827
|
+
req = build_request(:list_integrations, params)
|
3828
|
+
req.send_request(options)
|
3829
|
+
end
|
3830
|
+
|
3350
3831
|
# Retrieves a list of the log anomaly detectors in the account.
|
3351
3832
|
#
|
3352
3833
|
# @option params [String] :filter_log_group_arn
|
@@ -3401,6 +3882,63 @@ module Aws::CloudWatchLogs
|
|
3401
3882
|
req.send_request(options)
|
3402
3883
|
end
|
3403
3884
|
|
3885
|
+
# Returns a list of the log groups that were analyzed during a single
|
3886
|
+
# CloudWatch Logs Insights query. This can be useful for queries that
|
3887
|
+
# use log group name prefixes or the `filterIndex` command, because the
|
3888
|
+
# log groups are dynamically selected in these cases.
|
3889
|
+
#
|
3890
|
+
# For more information about field indexes, see [Create field indexes to
|
3891
|
+
# improve query performance and reduce costs][1].
|
3892
|
+
#
|
3893
|
+
#
|
3894
|
+
#
|
3895
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatchLogs-Field-Indexing.html
|
3896
|
+
#
|
3897
|
+
# @option params [required, String] :query_id
|
3898
|
+
# The ID of the query to use. This query ID is from the response to your
|
3899
|
+
# [StartQuery][1] operation.
|
3900
|
+
#
|
3901
|
+
#
|
3902
|
+
#
|
3903
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_StartQuery.html
|
3904
|
+
#
|
3905
|
+
# @option params [String] :next_token
|
3906
|
+
# The token for the next set of items to return. The token expires after
|
3907
|
+
# 24 hours.
|
3908
|
+
#
|
3909
|
+
# @option params [Integer] :max_results
|
3910
|
+
# Limits the number of returned log groups to the specified number.
|
3911
|
+
#
|
3912
|
+
# @return [Types::ListLogGroupsForQueryResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
3913
|
+
#
|
3914
|
+
# * {Types::ListLogGroupsForQueryResponse#log_group_identifiers #log_group_identifiers} => Array<String>
|
3915
|
+
# * {Types::ListLogGroupsForQueryResponse#next_token #next_token} => String
|
3916
|
+
#
|
3917
|
+
# The returned {Seahorse::Client::Response response} is a pageable response and is Enumerable. For details on usage see {Aws::PageableResponse PageableResponse}.
|
3918
|
+
#
|
3919
|
+
# @example Request syntax with placeholder values
|
3920
|
+
#
|
3921
|
+
# resp = client.list_log_groups_for_query({
|
3922
|
+
# query_id: "QueryId", # required
|
3923
|
+
# next_token: "NextToken",
|
3924
|
+
# max_results: 1,
|
3925
|
+
# })
|
3926
|
+
#
|
3927
|
+
# @example Response structure
|
3928
|
+
#
|
3929
|
+
# resp.log_group_identifiers #=> Array
|
3930
|
+
# resp.log_group_identifiers[0] #=> String
|
3931
|
+
# resp.next_token #=> String
|
3932
|
+
#
|
3933
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/ListLogGroupsForQuery AWS API Documentation
|
3934
|
+
#
|
3935
|
+
# @overload list_log_groups_for_query(params = {})
|
3936
|
+
# @param [Hash] params ({})
|
3937
|
+
def list_log_groups_for_query(params = {}, options = {})
|
3938
|
+
req = build_request(:list_log_groups_for_query, params)
|
3939
|
+
req.send_request(options)
|
3940
|
+
end
|
3941
|
+
|
3404
3942
|
# Displays the tags associated with a CloudWatch Logs resource.
|
3405
3943
|
# Currently, log groups and destinations support tagging.
|
3406
3944
|
#
|
@@ -3480,9 +4018,9 @@ module Aws::CloudWatchLogs
|
|
3480
4018
|
req.send_request(options)
|
3481
4019
|
end
|
3482
4020
|
|
3483
|
-
# Creates an account-level data protection policy
|
3484
|
-
# policy that applies to all log groups or a
|
3485
|
-
# account.
|
4021
|
+
# Creates an account-level data protection policy, subscription filter
|
4022
|
+
# policy, or field index policy that applies to all log groups or a
|
4023
|
+
# subset of log groups in the account.
|
3486
4024
|
#
|
3487
4025
|
# **Data protection policy**
|
3488
4026
|
#
|
@@ -3555,6 +4093,102 @@ module Aws::CloudWatchLogs
|
|
3555
4093
|
# subscription filter operation for any destination except a Lambda
|
3556
4094
|
# function, you must also have the `iam:PassRole` permission.
|
3557
4095
|
#
|
4096
|
+
# **Transformer policy**
|
4097
|
+
#
|
4098
|
+
# Creates or updates a *log transformer policy* for your account. You
|
4099
|
+
# use log transformers to transform log events into a different format,
|
4100
|
+
# making them easier for you to process and analyze. You can also
|
4101
|
+
# transform logs from different sources into standardized formats that
|
4102
|
+
# contain relevant, source-specific information. After you have created
|
4103
|
+
# a transformer, CloudWatch Logs performs this transformation at the
|
4104
|
+
# time of log ingestion. You can then refer to the transformed versions
|
4105
|
+
# of the logs during operations such as querying with CloudWatch Logs
|
4106
|
+
# Insights or creating metric filters or subscription filters.
|
4107
|
+
#
|
4108
|
+
# You can also use a transformer to copy metadata from metadata keys
|
4109
|
+
# into the log events themselves. This metadata can include log group
|
4110
|
+
# name, log stream name, account ID and Region.
|
4111
|
+
#
|
4112
|
+
# A transformer for a log group is a series of processors, where each
|
4113
|
+
# processor applies one type of transformation to the log events
|
4114
|
+
# ingested into this log group. For more information about the available
|
4115
|
+
# processors to use in a transformer, see [ Processors that you can
|
4116
|
+
# use][6].
|
4117
|
+
#
|
4118
|
+
# Having log events in standardized format enables visibility across
|
4119
|
+
# your applications for your log analysis, reporting, and alarming
|
4120
|
+
# needs. CloudWatch Logs provides transformation for common log types
|
4121
|
+
# with out-of-the-box transformation templates for major Amazon Web
|
4122
|
+
# Services log sources such as VPC flow logs, Lambda, and Amazon RDS.
|
4123
|
+
# You can use pre-built transformation templates or create custom
|
4124
|
+
# transformation policies.
|
4125
|
+
#
|
4126
|
+
# You can create transformers only for the log groups in the Standard
|
4127
|
+
# log class.
|
4128
|
+
#
|
4129
|
+
# You can have one account-level transformer policy that applies to all
|
4130
|
+
# log groups in the account. Or you can create as many as 20
|
4131
|
+
# account-level transformer policies that are each scoped to a subset of
|
4132
|
+
# log groups with the `selectionCriteria` parameter. If you have
|
4133
|
+
# multiple account-level transformer policies with selection criteria,
|
4134
|
+
# no two of them can use the same or overlapping log group name
|
4135
|
+
# prefixes. For example, if you have one policy filtered to log groups
|
4136
|
+
# that start with `my-log`, you can't have another field index policy
|
4137
|
+
# filtered to `my-logpprod` or `my-logging`.
|
4138
|
+
#
|
4139
|
+
# You can also set up a transformer at the log-group level. For more
|
4140
|
+
# information, see [PutTransformer][7]. If there is both a log-group
|
4141
|
+
# level transformer created with `PutTransformer` and an account-level
|
4142
|
+
# transformer that could apply to the same log group, the log group uses
|
4143
|
+
# only the log-group level transformer. It ignores the account-level
|
4144
|
+
# transformer.
|
4145
|
+
#
|
4146
|
+
# **Field index policy**
|
4147
|
+
#
|
4148
|
+
# You can use field index policies to create indexes on fields found in
|
4149
|
+
# log events in the log group. Creating field indexes can help lower the
|
4150
|
+
# scan volume for CloudWatch Logs Insights queries that reference those
|
4151
|
+
# fields, because these queries attempt to skip the processing of log
|
4152
|
+
# events that are known to not match the indexed field. Good fields to
|
4153
|
+
# index are fields that you often need to query for and fields or values
|
4154
|
+
# that match only a small fraction of the total log events. Common
|
4155
|
+
# examples of indexes include request ID, session ID, user IDs, or
|
4156
|
+
# instance IDs. For more information, see [Create field indexes to
|
4157
|
+
# improve query performance and reduce costs][8]
|
4158
|
+
#
|
4159
|
+
# To find the fields that are in your log group events, use the
|
4160
|
+
# [GetLogGroupFields][9] operation.
|
4161
|
+
#
|
4162
|
+
# For example, suppose you have created a field index for `requestId`.
|
4163
|
+
# Then, any CloudWatch Logs Insights query on that log group that
|
4164
|
+
# includes `requestId = value ` or `requestId in [value, value, ...]`
|
4165
|
+
# will attempt to process only the log events where the indexed field
|
4166
|
+
# matches the specified value.
|
4167
|
+
#
|
4168
|
+
# Matches of log events to the names of indexed fields are
|
4169
|
+
# case-sensitive. For example, an indexed field of `RequestId` won't
|
4170
|
+
# match a log event containing `requestId`.
|
4171
|
+
#
|
4172
|
+
# You can have one account-level field index policy that applies to all
|
4173
|
+
# log groups in the account. Or you can create as many as 20
|
4174
|
+
# account-level field index policies that are each scoped to a subset of
|
4175
|
+
# log groups with the `selectionCriteria` parameter. If you have
|
4176
|
+
# multiple account-level index policies with selection criteria, no two
|
4177
|
+
# of them can use the same or overlapping log group name prefixes. For
|
4178
|
+
# example, if you have one policy filtered to log groups that start with
|
4179
|
+
# `my-log`, you can't have another field index policy filtered to
|
4180
|
+
# `my-logpprod` or `my-logging`.
|
4181
|
+
#
|
4182
|
+
# If you create an account-level field index policy in a monitoring
|
4183
|
+
# account in cross-account observability, the policy is applied only to
|
4184
|
+
# the monitoring account and not to any source accounts.
|
4185
|
+
#
|
4186
|
+
# If you want to create a field index policy for a single log group, you
|
4187
|
+
# can use [PutIndexPolicy][10] instead of `PutAccountPolicy`. If you do
|
4188
|
+
# so, that log group will use only that log-group level policy, and will
|
4189
|
+
# ignore the account-level policy that you create with
|
4190
|
+
# [PutAccountPolicy][11].
|
4191
|
+
#
|
3558
4192
|
#
|
3559
4193
|
#
|
3560
4194
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_GetLogEvents.html
|
@@ -3562,6 +4196,12 @@ module Aws::CloudWatchLogs
|
|
3562
4196
|
# [3]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/mask-sensitive-log-data.html
|
3563
4197
|
# [4]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDataProtectionPolicy.html
|
3564
4198
|
# [5]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDestination.html
|
4199
|
+
# [6]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatch-Logs-Transformation.html#CloudWatch-Logs-Transformation-Processors
|
4200
|
+
# [7]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutTransformer.html
|
4201
|
+
# [8]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatchLogs-Field-Indexing.html
|
4202
|
+
# [9]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_GetLogGroupFields.html
|
4203
|
+
# [10]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutIndexPolicy.html
|
4204
|
+
# [11]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutAccountPolicy.html
|
3565
4205
|
#
|
3566
4206
|
# @option params [required, String] :policy_name
|
3567
4207
|
# A name for the policy. This must be unique within the account.
|
@@ -3643,10 +4283,34 @@ module Aws::CloudWatchLogs
|
|
3643
4283
|
# property is only applicable when the destination is an Kinesis Data
|
3644
4284
|
# Streams data stream.
|
3645
4285
|
#
|
4286
|
+
# **Transformer policy**
|
4287
|
+
#
|
4288
|
+
# A transformer policy must include one JSON block with the array of
|
4289
|
+
# processors and their configurations. For more information about
|
4290
|
+
# available processors, see [ Processors that you can use][3].
|
4291
|
+
#
|
4292
|
+
# **Field index policy**
|
4293
|
+
#
|
4294
|
+
# A field index filter policy can include the following attribute in a
|
4295
|
+
# JSON block:
|
4296
|
+
#
|
4297
|
+
# * **Fields** The array of field indexes to create.
|
4298
|
+
#
|
4299
|
+
# ^
|
4300
|
+
#
|
4301
|
+
# It must contain at least one field index.
|
4302
|
+
#
|
4303
|
+
# The following is an example of an index policy document that creates
|
4304
|
+
# two indexes, `RequestId` and `TransactionId`.
|
4305
|
+
#
|
4306
|
+
# `"policyDocument": "{ "Fields": [ "RequestId", "TransactionId" ]
|
4307
|
+
# }"`
|
4308
|
+
#
|
3646
4309
|
#
|
3647
4310
|
#
|
3648
4311
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/mask-sensitive-log-data-types.html
|
3649
4312
|
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutDestination.html
|
4313
|
+
# [3]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatch-Logs-Transformation.html#CloudWatch-Logs-Transformation-Processors
|
3650
4314
|
#
|
3651
4315
|
# @option params [required, String] :policy_type
|
3652
4316
|
# The type of policy that you're creating or updating.
|
@@ -3657,17 +4321,25 @@ module Aws::CloudWatchLogs
|
|
3657
4321
|
# the account. If you omit this parameter, the default of `ALL` is used.
|
3658
4322
|
#
|
3659
4323
|
# @option params [String] :selection_criteria
|
3660
|
-
# Use this parameter to apply the
|
3661
|
-
#
|
3662
|
-
# `LogGroupName NOT IN []`. The `selectionCriteria` string can be up to
|
3663
|
-
# 25KB in length. The length is determined by using its UTF-8 bytes.
|
4324
|
+
# Use this parameter to apply the new policy to a subset of log groups
|
4325
|
+
# in the account.
|
3664
4326
|
#
|
3665
|
-
#
|
3666
|
-
#
|
3667
|
-
#
|
4327
|
+
# Specifing `selectionCriteria` is valid only when you specify
|
4328
|
+
# `SUBSCRIPTION_FILTER_POLICY`, `FIELD_INDEX_POLICY` or
|
4329
|
+
# `TRANSFORMER_POLICY`for `policyType`.
|
3668
4330
|
#
|
3669
|
-
#
|
3670
|
-
#
|
4331
|
+
# If `policyType` is `SUBSCRIPTION_FILTER_POLICY`, the only supported
|
4332
|
+
# `selectionCriteria` filter is `LogGroupName NOT IN []`
|
4333
|
+
#
|
4334
|
+
# If `policyType` is `FIELD_INDEX_POLICY` or `TRANSFORMER_POLICY`, the
|
4335
|
+
# only supported `selectionCriteria` filter is `LogGroupNamePrefix`
|
4336
|
+
#
|
4337
|
+
# The `selectionCriteria` string can be up to 25KB in length. The length
|
4338
|
+
# is determined by using its UTF-8 bytes.
|
4339
|
+
#
|
4340
|
+
# Using the `selectionCriteria` parameter with
|
4341
|
+
# `SUBSCRIPTION_FILTER_POLICY` is useful to help prevent infinite loops.
|
4342
|
+
# For more information, see [Log recursion prevention][1].
|
3671
4343
|
#
|
3672
4344
|
#
|
3673
4345
|
#
|
@@ -3682,7 +4354,7 @@ module Aws::CloudWatchLogs
|
|
3682
4354
|
# resp = client.put_account_policy({
|
3683
4355
|
# policy_name: "PolicyName", # required
|
3684
4356
|
# policy_document: "AccountPolicyDocument", # required
|
3685
|
-
# policy_type: "DATA_PROTECTION_POLICY", # required, accepts DATA_PROTECTION_POLICY, SUBSCRIPTION_FILTER_POLICY
|
4357
|
+
# policy_type: "DATA_PROTECTION_POLICY", # required, accepts DATA_PROTECTION_POLICY, SUBSCRIPTION_FILTER_POLICY, FIELD_INDEX_POLICY, TRANSFORMER_POLICY
|
3686
4358
|
# scope: "ALL", # accepts ALL
|
3687
4359
|
# selection_criteria: "SelectionCriteria",
|
3688
4360
|
# })
|
@@ -3692,7 +4364,7 @@ module Aws::CloudWatchLogs
|
|
3692
4364
|
# resp.account_policy.policy_name #=> String
|
3693
4365
|
# resp.account_policy.policy_document #=> String
|
3694
4366
|
# resp.account_policy.last_updated_time #=> Integer
|
3695
|
-
# resp.account_policy.policy_type #=> String, one of "DATA_PROTECTION_POLICY", "SUBSCRIPTION_FILTER_POLICY"
|
4367
|
+
# resp.account_policy.policy_type #=> String, one of "DATA_PROTECTION_POLICY", "SUBSCRIPTION_FILTER_POLICY", "FIELD_INDEX_POLICY", "TRANSFORMER_POLICY"
|
3696
4368
|
# resp.account_policy.scope #=> String, one of "ALL"
|
3697
4369
|
# resp.account_policy.selection_criteria #=> String
|
3698
4370
|
# resp.account_policy.account_id #=> String
|
@@ -4230,6 +4902,167 @@ module Aws::CloudWatchLogs
|
|
4230
4902
|
req.send_request(options)
|
4231
4903
|
end
|
4232
4904
|
|
4905
|
+
# Creates or updates a *field index policy* for the specified log group.
|
4906
|
+
# Only log groups in the Standard log class support field index
|
4907
|
+
# policies. For more information about log classes, see [Log
|
4908
|
+
# classes][1].
|
4909
|
+
#
|
4910
|
+
# You can use field index policies to create *field indexes* on fields
|
4911
|
+
# found in log events in the log group. Creating field indexes speeds up
|
4912
|
+
# and lowers the costs for CloudWatch Logs Insights queries that
|
4913
|
+
# reference those field indexes, because these queries attempt to skip
|
4914
|
+
# the processing of log events that are known to not match the indexed
|
4915
|
+
# field. Good fields to index are fields that you often need to query
|
4916
|
+
# for and fields or values that match only a small fraction of the total
|
4917
|
+
# log events. Common examples of indexes include request ID, session ID,
|
4918
|
+
# userID, and instance IDs. For more information, see [Create field
|
4919
|
+
# indexes to improve query performance and reduce costs][2].
|
4920
|
+
#
|
4921
|
+
# To find the fields that are in your log group events, use the
|
4922
|
+
# [GetLogGroupFields][3] operation.
|
4923
|
+
#
|
4924
|
+
# For example, suppose you have created a field index for `requestId`.
|
4925
|
+
# Then, any CloudWatch Logs Insights query on that log group that
|
4926
|
+
# includes `requestId = value ` or `requestId IN [value, value, ...]`
|
4927
|
+
# will process fewer log events to reduce costs, and have improved
|
4928
|
+
# performance.
|
4929
|
+
#
|
4930
|
+
# Each index policy has the following quotas and restrictions:
|
4931
|
+
#
|
4932
|
+
# * As many as 20 fields can be included in the policy.
|
4933
|
+
#
|
4934
|
+
# * Each field name can include as many as 100 characters.
|
4935
|
+
#
|
4936
|
+
# Matches of log events to the names of indexed fields are
|
4937
|
+
# case-sensitive. For example, a field index of `RequestId` won't match
|
4938
|
+
# a log event containing `requestId`.
|
4939
|
+
#
|
4940
|
+
# Log group-level field index policies created with `PutIndexPolicy`
|
4941
|
+
# override account-level field index policies created with
|
4942
|
+
# [PutAccountPolicy][4]. If you use `PutIndexPolicy` to create a field
|
4943
|
+
# index policy for a log group, that log group uses only that policy.
|
4944
|
+
# The log group ignores any account-wide field index policy that you
|
4945
|
+
# might have created.
|
4946
|
+
#
|
4947
|
+
#
|
4948
|
+
#
|
4949
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatch_Logs_Log_Classes.html
|
4950
|
+
# [2]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatchLogs-Field-Indexing.html
|
4951
|
+
# [3]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_GetLogGroupFields.html
|
4952
|
+
# [4]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutAccountPolicy.html
|
4953
|
+
#
|
4954
|
+
# @option params [required, String] :log_group_identifier
|
4955
|
+
# Specify either the log group name or log group ARN to apply this field
|
4956
|
+
# index policy to. If you specify an ARN, use the format
|
4957
|
+
# arn:aws:logs:*region*:*account-id*:log-group:*log\_group\_name* Don't
|
4958
|
+
# include an * at the end.
|
4959
|
+
#
|
4960
|
+
# @option params [required, String] :policy_document
|
4961
|
+
# The index policy document, in JSON format. The following is an example
|
4962
|
+
# of an index policy document that creates two indexes, `RequestId` and
|
4963
|
+
# `TransactionId`.
|
4964
|
+
#
|
4965
|
+
# `"policyDocument": "{ "Fields": [ "RequestId", "TransactionId" ] }"`
|
4966
|
+
#
|
4967
|
+
# The policy document must include at least one field index. For more
|
4968
|
+
# information about the fields that can be included and other
|
4969
|
+
# restrictions, see [Field index syntax and quotas][1].
|
4970
|
+
#
|
4971
|
+
#
|
4972
|
+
#
|
4973
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatchLogs-Field-Indexing-Syntax.html
|
4974
|
+
#
|
4975
|
+
# @return [Types::PutIndexPolicyResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
4976
|
+
#
|
4977
|
+
# * {Types::PutIndexPolicyResponse#index_policy #index_policy} => Types::IndexPolicy
|
4978
|
+
#
|
4979
|
+
# @example Request syntax with placeholder values
|
4980
|
+
#
|
4981
|
+
# resp = client.put_index_policy({
|
4982
|
+
# log_group_identifier: "LogGroupIdentifier", # required
|
4983
|
+
# policy_document: "PolicyDocument", # required
|
4984
|
+
# })
|
4985
|
+
#
|
4986
|
+
# @example Response structure
|
4987
|
+
#
|
4988
|
+
# resp.index_policy.log_group_identifier #=> String
|
4989
|
+
# resp.index_policy.last_update_time #=> Integer
|
4990
|
+
# resp.index_policy.policy_document #=> String
|
4991
|
+
# resp.index_policy.policy_name #=> String
|
4992
|
+
# resp.index_policy.source #=> String, one of "ACCOUNT", "LOG_GROUP"
|
4993
|
+
#
|
4994
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/PutIndexPolicy AWS API Documentation
|
4995
|
+
#
|
4996
|
+
# @overload put_index_policy(params = {})
|
4997
|
+
# @param [Hash] params ({})
|
4998
|
+
def put_index_policy(params = {}, options = {})
|
4999
|
+
req = build_request(:put_index_policy, params)
|
5000
|
+
req.send_request(options)
|
5001
|
+
end
|
5002
|
+
|
5003
|
+
# Creates an integration between CloudWatch Logs and another service in
|
5004
|
+
# this account. Currently, only integrations with OpenSearch Service are
|
5005
|
+
# supported, and currently you can have only one integration in your
|
5006
|
+
# account.
|
5007
|
+
#
|
5008
|
+
# Integrating with OpenSearch Service makes it possible for you to
|
5009
|
+
# create curated vended logs dashboards, powered by OpenSearch Service
|
5010
|
+
# analytics. For more information, see [Vended log dashboards powered by
|
5011
|
+
# Amazon OpenSearch Service][1].
|
5012
|
+
#
|
5013
|
+
# You can use this operation only to create a new integration. You
|
5014
|
+
# can't modify an existing integration.
|
5015
|
+
#
|
5016
|
+
#
|
5017
|
+
#
|
5018
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatchLogs-OpenSearch-Dashboards.html
|
5019
|
+
#
|
5020
|
+
# @option params [required, String] :integration_name
|
5021
|
+
# A name for the integration.
|
5022
|
+
#
|
5023
|
+
# @option params [required, Types::ResourceConfig] :resource_config
|
5024
|
+
# A structure that contains configuration information for the
|
5025
|
+
# integration that you are creating.
|
5026
|
+
#
|
5027
|
+
# @option params [required, String] :integration_type
|
5028
|
+
# The type of integration. Currently, the only supported type is
|
5029
|
+
# `OPENSEARCH`.
|
5030
|
+
#
|
5031
|
+
# @return [Types::PutIntegrationResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
5032
|
+
#
|
5033
|
+
# * {Types::PutIntegrationResponse#integration_name #integration_name} => String
|
5034
|
+
# * {Types::PutIntegrationResponse#integration_status #integration_status} => String
|
5035
|
+
#
|
5036
|
+
# @example Request syntax with placeholder values
|
5037
|
+
#
|
5038
|
+
# resp = client.put_integration({
|
5039
|
+
# integration_name: "IntegrationName", # required
|
5040
|
+
# resource_config: { # required
|
5041
|
+
# open_search_resource_config: {
|
5042
|
+
# kms_key_arn: "Arn",
|
5043
|
+
# data_source_role_arn: "Arn", # required
|
5044
|
+
# dashboard_viewer_principals: ["Arn"], # required
|
5045
|
+
# application_arn: "Arn",
|
5046
|
+
# retention_days: 1, # required
|
5047
|
+
# },
|
5048
|
+
# },
|
5049
|
+
# integration_type: "OPENSEARCH", # required, accepts OPENSEARCH
|
5050
|
+
# })
|
5051
|
+
#
|
5052
|
+
# @example Response structure
|
5053
|
+
#
|
5054
|
+
# resp.integration_name #=> String
|
5055
|
+
# resp.integration_status #=> String, one of "PROVISIONING", "ACTIVE", "FAILED"
|
5056
|
+
#
|
5057
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/PutIntegration AWS API Documentation
|
5058
|
+
#
|
5059
|
+
# @overload put_integration(params = {})
|
5060
|
+
# @param [Hash] params ({})
|
5061
|
+
def put_integration(params = {}, options = {})
|
5062
|
+
req = build_request(:put_integration, params)
|
5063
|
+
req.send_request(options)
|
5064
|
+
end
|
5065
|
+
|
4233
5066
|
# Uploads a batch of log events to the specified log stream.
|
4234
5067
|
#
|
4235
5068
|
# The sequence token is now ignored in `PutLogEvents` actions.
|
@@ -4293,7 +5126,7 @@ module Aws::CloudWatchLogs
|
|
4293
5126
|
# if the sequence token is not valid.
|
4294
5127
|
#
|
4295
5128
|
# @option params [Types::Entity] :entity
|
4296
|
-
#
|
5129
|
+
# The entity associated with the log events.
|
4297
5130
|
#
|
4298
5131
|
# @return [Types::PutLogEventsResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
4299
5132
|
#
|
@@ -4349,12 +5182,12 @@ module Aws::CloudWatchLogs
|
|
4349
5182
|
# group is 100.
|
4350
5183
|
#
|
4351
5184
|
# Using regular expressions to create metric filters is supported. For
|
4352
|
-
# these filters, there is a
|
4353
|
-
#
|
4354
|
-
#
|
4355
|
-
#
|
4356
|
-
#
|
4357
|
-
#
|
5185
|
+
# these filters, there is a quota of two regular expression patterns
|
5186
|
+
# within a single filter pattern. There is also a quota of five regular
|
5187
|
+
# expression patterns per log group. For more information about using
|
5188
|
+
# regular expressions in metric filters, see [ Filter pattern syntax for
|
5189
|
+
# metric filters, subscription filters, filter log events, and Live
|
5190
|
+
# Tail][2].
|
4358
5191
|
#
|
4359
5192
|
# When you create a metric filter, you can also optionally assign a unit
|
4360
5193
|
# and dimensions to the metric that is created.
|
@@ -4392,6 +5225,20 @@ module Aws::CloudWatchLogs
|
|
4392
5225
|
# @option params [required, Array<Types::MetricTransformation>] :metric_transformations
|
4393
5226
|
# A collection of information that defines how metric data gets emitted.
|
4394
5227
|
#
|
5228
|
+
# @option params [Boolean] :apply_on_transformed_logs
|
5229
|
+
# This parameter is valid only for log groups that have an active log
|
5230
|
+
# transformer. For more information about log transformers, see
|
5231
|
+
# [PutTransformer][1].
|
5232
|
+
#
|
5233
|
+
# If the log group uses either a log-group level or account-level
|
5234
|
+
# transformer, and you specify `true`, the metric filter will be applied
|
5235
|
+
# on the transformed version of the log events instead of the original
|
5236
|
+
# ingested log events.
|
5237
|
+
#
|
5238
|
+
#
|
5239
|
+
#
|
5240
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutTransformer.html
|
5241
|
+
#
|
4395
5242
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
4396
5243
|
#
|
4397
5244
|
# @example Request syntax with placeholder values
|
@@ -4412,6 +5259,7 @@ module Aws::CloudWatchLogs
|
|
4412
5259
|
# unit: "Seconds", # accepts Seconds, Microseconds, Milliseconds, Bytes, Kilobytes, Megabytes, Gigabytes, Terabytes, Bits, Kilobits, Megabits, Gigabits, Terabits, Percent, Count, Bytes/Second, Kilobytes/Second, Megabytes/Second, Gigabytes/Second, Terabytes/Second, Bits/Second, Kilobits/Second, Megabits/Second, Gigabits/Second, Terabits/Second, Count/Second, None
|
4413
5260
|
# },
|
4414
5261
|
# ],
|
5262
|
+
# apply_on_transformed_logs: false,
|
4415
5263
|
# })
|
4416
5264
|
#
|
4417
5265
|
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/PutMetricFilter AWS API Documentation
|
@@ -4443,6 +5291,16 @@ module Aws::CloudWatchLogs
|
|
4443
5291
|
#
|
4444
5292
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/AnalyzingLogData.html
|
4445
5293
|
#
|
5294
|
+
# @option params [String] :query_language
|
5295
|
+
# Specify the query language to use for this query. The options are Logs
|
5296
|
+
# Insights QL, OpenSearch PPL, and OpenSearch SQL. For more information
|
5297
|
+
# about the query languages that CloudWatch Logs supports, see
|
5298
|
+
# [Supported query languages][1].
|
5299
|
+
#
|
5300
|
+
#
|
5301
|
+
#
|
5302
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CWL_AnalyzeLogData_Languages.html
|
5303
|
+
#
|
4446
5304
|
# @option params [required, String] :name
|
4447
5305
|
# A name for the query definition. If you are saving numerous query
|
4448
5306
|
# definitions, we recommend that you name them. This way, you can find
|
@@ -4470,10 +5328,13 @@ module Aws::CloudWatchLogs
|
|
4470
5328
|
#
|
4471
5329
|
# @option params [Array<String>] :log_group_names
|
4472
5330
|
# Use this parameter to include specific log groups as part of your
|
4473
|
-
# query definition.
|
5331
|
+
# query definition. If your query uses the OpenSearch Service query
|
5332
|
+
# language, you specify the log group names inside the `querystring`
|
5333
|
+
# instead of here.
|
4474
5334
|
#
|
4475
|
-
# If you are updating
|
4476
|
-
#
|
5335
|
+
# If you are updating an existing query definition for the Logs Insights
|
5336
|
+
# QL or OpenSearch Service PPL and you omit this parameter, then the
|
5337
|
+
# updated definition will contain no log groups.
|
4477
5338
|
#
|
4478
5339
|
# @option params [required, String] :query_string
|
4479
5340
|
# The query string to use for this definition. For more information, see
|
@@ -4497,6 +5358,7 @@ module Aws::CloudWatchLogs
|
|
4497
5358
|
# @example Request syntax with placeholder values
|
4498
5359
|
#
|
4499
5360
|
# resp = client.put_query_definition({
|
5361
|
+
# query_language: "CWLI", # accepts CWLI, SQL, PPL
|
4500
5362
|
# name: "QueryDefinitionName", # required
|
4501
5363
|
# query_definition_id: "QueryId",
|
4502
5364
|
# log_group_names: ["LogGroupName"],
|
@@ -4740,6 +5602,20 @@ module Aws::CloudWatchLogs
|
|
4740
5602
|
# random for a more even distribution. This property is only applicable
|
4741
5603
|
# when the destination is an Amazon Kinesis data stream.
|
4742
5604
|
#
|
5605
|
+
# @option params [Boolean] :apply_on_transformed_logs
|
5606
|
+
# This parameter is valid only for log groups that have an active log
|
5607
|
+
# transformer. For more information about log transformers, see
|
5608
|
+
# [PutTransformer][1].
|
5609
|
+
#
|
5610
|
+
# If the log group uses either a log-group level or account-level
|
5611
|
+
# transformer, and you specify `true`, the subscription filter will be
|
5612
|
+
# applied on the transformed version of the log events instead of the
|
5613
|
+
# original ingested log events.
|
5614
|
+
#
|
5615
|
+
#
|
5616
|
+
#
|
5617
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutTransformer.html
|
5618
|
+
#
|
4743
5619
|
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
4744
5620
|
#
|
4745
5621
|
# @example Request syntax with placeholder values
|
@@ -4751,6 +5627,7 @@ module Aws::CloudWatchLogs
|
|
4751
5627
|
# destination_arn: "DestinationArn", # required
|
4752
5628
|
# role_arn: "RoleArn",
|
4753
5629
|
# distribution: "Random", # accepts Random, ByLogStream
|
5630
|
+
# apply_on_transformed_logs: false,
|
4754
5631
|
# })
|
4755
5632
|
#
|
4756
5633
|
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/PutSubscriptionFilter AWS API Documentation
|
@@ -4762,6 +5639,211 @@ module Aws::CloudWatchLogs
|
|
4762
5639
|
req.send_request(options)
|
4763
5640
|
end
|
4764
5641
|
|
5642
|
+
# Creates or updates a *log transformer* for a single log group. You use
|
5643
|
+
# log transformers to transform log events into a different format,
|
5644
|
+
# making them easier for you to process and analyze. You can also
|
5645
|
+
# transform logs from different sources into standardized formats that
|
5646
|
+
# contains relevant, source-specific information.
|
5647
|
+
#
|
5648
|
+
# After you have created a transformer, CloudWatch Logs performs the
|
5649
|
+
# transformations at the time of log ingestion. You can then refer to
|
5650
|
+
# the transformed versions of the logs during operations such as
|
5651
|
+
# querying with CloudWatch Logs Insights or creating metric filters or
|
5652
|
+
# subscription filers.
|
5653
|
+
#
|
5654
|
+
# You can also use a transformer to copy metadata from metadata keys
|
5655
|
+
# into the log events themselves. This metadata can include log group
|
5656
|
+
# name, log stream name, account ID and Region.
|
5657
|
+
#
|
5658
|
+
# A transformer for a log group is a series of processors, where each
|
5659
|
+
# processor applies one type of transformation to the log events
|
5660
|
+
# ingested into this log group. The processors work one after another,
|
5661
|
+
# in the order that you list them, like a pipeline. For more information
|
5662
|
+
# about the available processors to use in a transformer, see [
|
5663
|
+
# Processors that you can use][1].
|
5664
|
+
#
|
5665
|
+
# Having log events in standardized format enables visibility across
|
5666
|
+
# your applications for your log analysis, reporting, and alarming
|
5667
|
+
# needs. CloudWatch Logs provides transformation for common log types
|
5668
|
+
# with out-of-the-box transformation templates for major Amazon Web
|
5669
|
+
# Services log sources such as VPC flow logs, Lambda, and Amazon RDS.
|
5670
|
+
# You can use pre-built transformation templates or create custom
|
5671
|
+
# transformation policies.
|
5672
|
+
#
|
5673
|
+
# You can create transformers only for the log groups in the Standard
|
5674
|
+
# log class.
|
5675
|
+
#
|
5676
|
+
# You can also set up a transformer at the account level. For more
|
5677
|
+
# information, see [PutAccountPolicy][2]. If there is both a log-group
|
5678
|
+
# level transformer created with `PutTransformer` and an account-level
|
5679
|
+
# transformer that could apply to the same log group, the log group uses
|
5680
|
+
# only the log-group level transformer. It ignores the account-level
|
5681
|
+
# transformer.
|
5682
|
+
#
|
5683
|
+
#
|
5684
|
+
#
|
5685
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CloudWatch-Logs-Transformation.html#CloudWatch-Logs-Transformation-Processors
|
5686
|
+
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_PutAccountPolicy.html
|
5687
|
+
#
|
5688
|
+
# @option params [required, String] :log_group_identifier
|
5689
|
+
# Specify either the name or ARN of the log group to create the
|
5690
|
+
# transformer for.
|
5691
|
+
#
|
5692
|
+
# @option params [required, Array<Types::Processor>] :transformer_config
|
5693
|
+
# This structure contains the configuration of this log transformer. A
|
5694
|
+
# log transformer is an array of processors, where each processor
|
5695
|
+
# applies one type of transformation to the log events that are
|
5696
|
+
# ingested.
|
5697
|
+
#
|
5698
|
+
# @return [Struct] Returns an empty {Seahorse::Client::Response response}.
|
5699
|
+
#
|
5700
|
+
# @example Request syntax with placeholder values
|
5701
|
+
#
|
5702
|
+
# resp = client.put_transformer({
|
5703
|
+
# log_group_identifier: "LogGroupIdentifier", # required
|
5704
|
+
# transformer_config: [ # required
|
5705
|
+
# {
|
5706
|
+
# add_keys: {
|
5707
|
+
# entries: [ # required
|
5708
|
+
# {
|
5709
|
+
# key: "Key", # required
|
5710
|
+
# value: "AddKeyValue", # required
|
5711
|
+
# overwrite_if_exists: false,
|
5712
|
+
# },
|
5713
|
+
# ],
|
5714
|
+
# },
|
5715
|
+
# copy_value: {
|
5716
|
+
# entries: [ # required
|
5717
|
+
# {
|
5718
|
+
# source: "Source", # required
|
5719
|
+
# target: "Target", # required
|
5720
|
+
# overwrite_if_exists: false,
|
5721
|
+
# },
|
5722
|
+
# ],
|
5723
|
+
# },
|
5724
|
+
# csv: {
|
5725
|
+
# quote_character: "QuoteCharacter",
|
5726
|
+
# delimiter: "Delimiter",
|
5727
|
+
# columns: ["Column"],
|
5728
|
+
# source: "Source",
|
5729
|
+
# },
|
5730
|
+
# date_time_converter: {
|
5731
|
+
# source: "Source", # required
|
5732
|
+
# target: "Target", # required
|
5733
|
+
# target_format: "TargetFormat",
|
5734
|
+
# match_patterns: ["MatchPattern"], # required
|
5735
|
+
# source_timezone: "SourceTimezone",
|
5736
|
+
# target_timezone: "TargetTimezone",
|
5737
|
+
# locale: "Locale",
|
5738
|
+
# },
|
5739
|
+
# delete_keys: {
|
5740
|
+
# with_keys: ["WithKey"], # required
|
5741
|
+
# },
|
5742
|
+
# grok: {
|
5743
|
+
# source: "Source",
|
5744
|
+
# match: "GrokMatch", # required
|
5745
|
+
# },
|
5746
|
+
# list_to_map: {
|
5747
|
+
# source: "Source", # required
|
5748
|
+
# key: "Key", # required
|
5749
|
+
# value_key: "ValueKey",
|
5750
|
+
# target: "Target",
|
5751
|
+
# flatten: false,
|
5752
|
+
# flattened_element: "first", # accepts first, last
|
5753
|
+
# },
|
5754
|
+
# lower_case_string: {
|
5755
|
+
# with_keys: ["WithKey"], # required
|
5756
|
+
# },
|
5757
|
+
# move_keys: {
|
5758
|
+
# entries: [ # required
|
5759
|
+
# {
|
5760
|
+
# source: "Source", # required
|
5761
|
+
# target: "Target", # required
|
5762
|
+
# overwrite_if_exists: false,
|
5763
|
+
# },
|
5764
|
+
# ],
|
5765
|
+
# },
|
5766
|
+
# parse_cloudfront: {
|
5767
|
+
# source: "Source",
|
5768
|
+
# },
|
5769
|
+
# parse_json: {
|
5770
|
+
# source: "Source",
|
5771
|
+
# destination: "DestinationField",
|
5772
|
+
# },
|
5773
|
+
# parse_key_value: {
|
5774
|
+
# source: "Source",
|
5775
|
+
# destination: "DestinationField",
|
5776
|
+
# field_delimiter: "ParserFieldDelimiter",
|
5777
|
+
# key_value_delimiter: "KeyValueDelimiter",
|
5778
|
+
# key_prefix: "KeyPrefix",
|
5779
|
+
# non_match_value: "NonMatchValue",
|
5780
|
+
# overwrite_if_exists: false,
|
5781
|
+
# },
|
5782
|
+
# parse_route_53: {
|
5783
|
+
# source: "Source",
|
5784
|
+
# },
|
5785
|
+
# parse_postgres: {
|
5786
|
+
# source: "Source",
|
5787
|
+
# },
|
5788
|
+
# parse_vpc: {
|
5789
|
+
# source: "Source",
|
5790
|
+
# },
|
5791
|
+
# parse_waf: {
|
5792
|
+
# source: "Source",
|
5793
|
+
# },
|
5794
|
+
# rename_keys: {
|
5795
|
+
# entries: [ # required
|
5796
|
+
# {
|
5797
|
+
# key: "Key", # required
|
5798
|
+
# rename_to: "RenameTo", # required
|
5799
|
+
# overwrite_if_exists: false,
|
5800
|
+
# },
|
5801
|
+
# ],
|
5802
|
+
# },
|
5803
|
+
# split_string: {
|
5804
|
+
# entries: [ # required
|
5805
|
+
# {
|
5806
|
+
# source: "Source", # required
|
5807
|
+
# delimiter: "Delimiter", # required
|
5808
|
+
# },
|
5809
|
+
# ],
|
5810
|
+
# },
|
5811
|
+
# substitute_string: {
|
5812
|
+
# entries: [ # required
|
5813
|
+
# {
|
5814
|
+
# source: "Source", # required
|
5815
|
+
# from: "FromKey", # required
|
5816
|
+
# to: "ToKey", # required
|
5817
|
+
# },
|
5818
|
+
# ],
|
5819
|
+
# },
|
5820
|
+
# trim_string: {
|
5821
|
+
# with_keys: ["WithKey"], # required
|
5822
|
+
# },
|
5823
|
+
# type_converter: {
|
5824
|
+
# entries: [ # required
|
5825
|
+
# {
|
5826
|
+
# key: "Key", # required
|
5827
|
+
# type: "boolean", # required, accepts boolean, integer, double, string
|
5828
|
+
# },
|
5829
|
+
# ],
|
5830
|
+
# },
|
5831
|
+
# upper_case_string: {
|
5832
|
+
# with_keys: ["WithKey"], # required
|
5833
|
+
# },
|
5834
|
+
# },
|
5835
|
+
# ],
|
5836
|
+
# })
|
5837
|
+
#
|
5838
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/PutTransformer AWS API Documentation
|
5839
|
+
#
|
5840
|
+
# @overload put_transformer(params = {})
|
5841
|
+
# @param [Hash] params ({})
|
5842
|
+
def put_transformer(params = {}, options = {})
|
5843
|
+
req = build_request(:put_transformer, params)
|
5844
|
+
req.send_request(options)
|
5845
|
+
end
|
5846
|
+
|
4765
5847
|
# Starts a Live Tail streaming session for one or more log groups. A
|
4766
5848
|
# Live Tail session returns a stream of log events that have been
|
4767
5849
|
# recently ingested in the log groups. For more information, see [Use
|
@@ -5049,9 +6131,9 @@ module Aws::CloudWatchLogs
|
|
5049
6131
|
req.send_request(options)
|
5050
6132
|
end
|
5051
6133
|
|
5052
|
-
#
|
5053
|
-
# specify the log
|
5054
|
-
# use.
|
6134
|
+
# Starts a query of one or more log groups using CloudWatch Logs
|
6135
|
+
# Insights. You specify the log groups and time range to query and the
|
6136
|
+
# query string to use.
|
5055
6137
|
#
|
5056
6138
|
# For more information, see [CloudWatch Logs Insights Query Syntax][1].
|
5057
6139
|
#
|
@@ -5059,8 +6141,22 @@ module Aws::CloudWatchLogs
|
|
5059
6141
|
# by CloudWatch Logs. You can use [GetQueryResults][2] to retrieve the
|
5060
6142
|
# results of a query, using the `queryId` that `StartQuery` returns.
|
5061
6143
|
#
|
6144
|
+
# <note markdown="1"> To specify the log groups to query, a `StartQuery` operation must
|
6145
|
+
# include one of the following:
|
6146
|
+
#
|
6147
|
+
# * Either exactly one of the following parameters: `logGroupName`,
|
6148
|
+
# `logGroupNames`, or `logGroupIdentifiers`
|
6149
|
+
#
|
6150
|
+
# * Or the `queryString` must include a `SOURCE` command to select log
|
6151
|
+
# groups for the query. The `SOURCE` command can select log groups
|
6152
|
+
# based on log group name prefix, account ID, and log class.
|
6153
|
+
#
|
6154
|
+
# For more information about the `SOURCE` command, see [SOURCE][3].
|
6155
|
+
#
|
6156
|
+
# </note>
|
6157
|
+
#
|
5062
6158
|
# If you have associated a KMS key with the query results in this
|
5063
|
-
# account, then [StartQuery][
|
6159
|
+
# account, then [StartQuery][4] uses that key to encrypt the results
|
5064
6160
|
# when it stores them. If no key is associated with query results, the
|
5065
6161
|
# query results are encrypted with the default CloudWatch Logs
|
5066
6162
|
# encryption method.
|
@@ -5072,7 +6168,7 @@ module Aws::CloudWatchLogs
|
|
5072
6168
|
# If you are using CloudWatch cross-account observability, you can use
|
5073
6169
|
# this operation in a monitoring account to start a query in a linked
|
5074
6170
|
# source account. For more information, see [CloudWatch cross-account
|
5075
|
-
# observability][
|
6171
|
+
# observability][5]. For a cross-account `StartQuery` operation, the
|
5076
6172
|
# query definition must be defined in the monitoring account.
|
5077
6173
|
#
|
5078
6174
|
# You can have up to 30 concurrent CloudWatch Logs insights queries,
|
@@ -5082,14 +6178,28 @@ module Aws::CloudWatchLogs
|
|
5082
6178
|
#
|
5083
6179
|
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CWL_QuerySyntax.html
|
5084
6180
|
# [2]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_GetQueryResults.html
|
5085
|
-
# [3]: https://docs.aws.amazon.com/
|
5086
|
-
# [4]: https://docs.aws.amazon.com/
|
6181
|
+
# [3]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CWL_QuerySyntax-Source.html
|
6182
|
+
# [4]: https://docs.aws.amazon.com/AmazonCloudWatchLogs/latest/APIReference/API_StartQuery.html
|
6183
|
+
# [5]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-Unified-Cross-Account.html
|
6184
|
+
#
|
6185
|
+
# @option params [String] :query_language
|
6186
|
+
# Specify the query language to use for this query. The options are Logs
|
6187
|
+
# Insights QL, OpenSearch PPL, and OpenSearch SQL. For more information
|
6188
|
+
# about the query languages that CloudWatch Logs supports, see
|
6189
|
+
# [Supported query languages][1].
|
6190
|
+
#
|
6191
|
+
#
|
6192
|
+
#
|
6193
|
+
# [1]: https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CWL_AnalyzeLogData_Languages.html
|
5087
6194
|
#
|
5088
6195
|
# @option params [String] :log_group_name
|
5089
6196
|
# The log group on which to perform the query.
|
5090
6197
|
#
|
5091
6198
|
# <note markdown="1"> A `StartQuery` operation must include exactly one of the following
|
5092
6199
|
# parameters: `logGroupName`, `logGroupNames`, or `logGroupIdentifiers`.
|
6200
|
+
# The exception is queries using the OpenSearch Service SQL query
|
6201
|
+
# language, where you specify the log group names inside the
|
6202
|
+
# `querystring` instead of here.
|
5093
6203
|
#
|
5094
6204
|
# </note>
|
5095
6205
|
#
|
@@ -5099,6 +6209,9 @@ module Aws::CloudWatchLogs
|
|
5099
6209
|
#
|
5100
6210
|
# <note markdown="1"> A `StartQuery` operation must include exactly one of the following
|
5101
6211
|
# parameters: `logGroupName`, `logGroupNames`, or `logGroupIdentifiers`.
|
6212
|
+
# The exception is queries using the OpenSearch Service SQL query
|
6213
|
+
# language, where you specify the log group names inside the
|
6214
|
+
# `querystring` instead of here.
|
5102
6215
|
#
|
5103
6216
|
# </note>
|
5104
6217
|
#
|
@@ -5110,10 +6223,15 @@ module Aws::CloudWatchLogs
|
|
5110
6223
|
# account, you must specify the ARN of the log group here. The query
|
5111
6224
|
# definition must also be defined in the monitoring account.
|
5112
6225
|
#
|
5113
|
-
# If you specify an ARN, the
|
6226
|
+
# If you specify an ARN, use the format
|
6227
|
+
# arn:aws:logs:*region*:*account-id*:log-group:*log\_group\_name* Don't
|
6228
|
+
# include an * at the end.
|
5114
6229
|
#
|
5115
6230
|
# A `StartQuery` operation must include exactly one of the following
|
5116
6231
|
# parameters: `logGroupName`, `logGroupNames`, or `logGroupIdentifiers`.
|
6232
|
+
# The exception is queries using the OpenSearch Service SQL query
|
6233
|
+
# language, where you specify the log group names inside the
|
6234
|
+
# `querystring` instead of here.
|
5117
6235
|
#
|
5118
6236
|
# @option params [required, Integer] :start_time
|
5119
6237
|
# The beginning of the time range to query. The range is inclusive, so
|
@@ -5145,6 +6263,7 @@ module Aws::CloudWatchLogs
|
|
5145
6263
|
# @example Request syntax with placeholder values
|
5146
6264
|
#
|
5147
6265
|
# resp = client.start_query({
|
6266
|
+
# query_language: "CWLI", # accepts CWLI, SQL, PPL
|
5148
6267
|
# log_group_name: "LogGroupName",
|
5149
6268
|
# log_group_names: ["LogGroupName"],
|
5150
6269
|
# log_group_identifiers: ["LogGroupIdentifier"],
|
@@ -5348,6 +6467,179 @@ module Aws::CloudWatchLogs
|
|
5348
6467
|
req.send_request(options)
|
5349
6468
|
end
|
5350
6469
|
|
6470
|
+
# Use this operation to test a log transformer. You enter the
|
6471
|
+
# transformer configuration and a set of log events to test with. The
|
6472
|
+
# operation responds with an array that includes the original log events
|
6473
|
+
# and the transformed versions.
|
6474
|
+
#
|
6475
|
+
# @option params [required, Array<Types::Processor>] :transformer_config
|
6476
|
+
# This structure contains the configuration of this log transformer that
|
6477
|
+
# you want to test. A log transformer is an array of processors, where
|
6478
|
+
# each processor applies one type of transformation to the log events
|
6479
|
+
# that are ingested.
|
6480
|
+
#
|
6481
|
+
# @option params [required, Array<String>] :log_event_messages
|
6482
|
+
# An array of the raw log events that you want to use to test this
|
6483
|
+
# transformer.
|
6484
|
+
#
|
6485
|
+
# @return [Types::TestTransformerResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
|
6486
|
+
#
|
6487
|
+
# * {Types::TestTransformerResponse#transformed_logs #transformed_logs} => Array<Types::TransformedLogRecord>
|
6488
|
+
#
|
6489
|
+
# @example Request syntax with placeholder values
|
6490
|
+
#
|
6491
|
+
# resp = client.test_transformer({
|
6492
|
+
# transformer_config: [ # required
|
6493
|
+
# {
|
6494
|
+
# add_keys: {
|
6495
|
+
# entries: [ # required
|
6496
|
+
# {
|
6497
|
+
# key: "Key", # required
|
6498
|
+
# value: "AddKeyValue", # required
|
6499
|
+
# overwrite_if_exists: false,
|
6500
|
+
# },
|
6501
|
+
# ],
|
6502
|
+
# },
|
6503
|
+
# copy_value: {
|
6504
|
+
# entries: [ # required
|
6505
|
+
# {
|
6506
|
+
# source: "Source", # required
|
6507
|
+
# target: "Target", # required
|
6508
|
+
# overwrite_if_exists: false,
|
6509
|
+
# },
|
6510
|
+
# ],
|
6511
|
+
# },
|
6512
|
+
# csv: {
|
6513
|
+
# quote_character: "QuoteCharacter",
|
6514
|
+
# delimiter: "Delimiter",
|
6515
|
+
# columns: ["Column"],
|
6516
|
+
# source: "Source",
|
6517
|
+
# },
|
6518
|
+
# date_time_converter: {
|
6519
|
+
# source: "Source", # required
|
6520
|
+
# target: "Target", # required
|
6521
|
+
# target_format: "TargetFormat",
|
6522
|
+
# match_patterns: ["MatchPattern"], # required
|
6523
|
+
# source_timezone: "SourceTimezone",
|
6524
|
+
# target_timezone: "TargetTimezone",
|
6525
|
+
# locale: "Locale",
|
6526
|
+
# },
|
6527
|
+
# delete_keys: {
|
6528
|
+
# with_keys: ["WithKey"], # required
|
6529
|
+
# },
|
6530
|
+
# grok: {
|
6531
|
+
# source: "Source",
|
6532
|
+
# match: "GrokMatch", # required
|
6533
|
+
# },
|
6534
|
+
# list_to_map: {
|
6535
|
+
# source: "Source", # required
|
6536
|
+
# key: "Key", # required
|
6537
|
+
# value_key: "ValueKey",
|
6538
|
+
# target: "Target",
|
6539
|
+
# flatten: false,
|
6540
|
+
# flattened_element: "first", # accepts first, last
|
6541
|
+
# },
|
6542
|
+
# lower_case_string: {
|
6543
|
+
# with_keys: ["WithKey"], # required
|
6544
|
+
# },
|
6545
|
+
# move_keys: {
|
6546
|
+
# entries: [ # required
|
6547
|
+
# {
|
6548
|
+
# source: "Source", # required
|
6549
|
+
# target: "Target", # required
|
6550
|
+
# overwrite_if_exists: false,
|
6551
|
+
# },
|
6552
|
+
# ],
|
6553
|
+
# },
|
6554
|
+
# parse_cloudfront: {
|
6555
|
+
# source: "Source",
|
6556
|
+
# },
|
6557
|
+
# parse_json: {
|
6558
|
+
# source: "Source",
|
6559
|
+
# destination: "DestinationField",
|
6560
|
+
# },
|
6561
|
+
# parse_key_value: {
|
6562
|
+
# source: "Source",
|
6563
|
+
# destination: "DestinationField",
|
6564
|
+
# field_delimiter: "ParserFieldDelimiter",
|
6565
|
+
# key_value_delimiter: "KeyValueDelimiter",
|
6566
|
+
# key_prefix: "KeyPrefix",
|
6567
|
+
# non_match_value: "NonMatchValue",
|
6568
|
+
# overwrite_if_exists: false,
|
6569
|
+
# },
|
6570
|
+
# parse_route_53: {
|
6571
|
+
# source: "Source",
|
6572
|
+
# },
|
6573
|
+
# parse_postgres: {
|
6574
|
+
# source: "Source",
|
6575
|
+
# },
|
6576
|
+
# parse_vpc: {
|
6577
|
+
# source: "Source",
|
6578
|
+
# },
|
6579
|
+
# parse_waf: {
|
6580
|
+
# source: "Source",
|
6581
|
+
# },
|
6582
|
+
# rename_keys: {
|
6583
|
+
# entries: [ # required
|
6584
|
+
# {
|
6585
|
+
# key: "Key", # required
|
6586
|
+
# rename_to: "RenameTo", # required
|
6587
|
+
# overwrite_if_exists: false,
|
6588
|
+
# },
|
6589
|
+
# ],
|
6590
|
+
# },
|
6591
|
+
# split_string: {
|
6592
|
+
# entries: [ # required
|
6593
|
+
# {
|
6594
|
+
# source: "Source", # required
|
6595
|
+
# delimiter: "Delimiter", # required
|
6596
|
+
# },
|
6597
|
+
# ],
|
6598
|
+
# },
|
6599
|
+
# substitute_string: {
|
6600
|
+
# entries: [ # required
|
6601
|
+
# {
|
6602
|
+
# source: "Source", # required
|
6603
|
+
# from: "FromKey", # required
|
6604
|
+
# to: "ToKey", # required
|
6605
|
+
# },
|
6606
|
+
# ],
|
6607
|
+
# },
|
6608
|
+
# trim_string: {
|
6609
|
+
# with_keys: ["WithKey"], # required
|
6610
|
+
# },
|
6611
|
+
# type_converter: {
|
6612
|
+
# entries: [ # required
|
6613
|
+
# {
|
6614
|
+
# key: "Key", # required
|
6615
|
+
# type: "boolean", # required, accepts boolean, integer, double, string
|
6616
|
+
# },
|
6617
|
+
# ],
|
6618
|
+
# },
|
6619
|
+
# upper_case_string: {
|
6620
|
+
# with_keys: ["WithKey"], # required
|
6621
|
+
# },
|
6622
|
+
# },
|
6623
|
+
# ],
|
6624
|
+
# log_event_messages: ["EventMessage"], # required
|
6625
|
+
# })
|
6626
|
+
#
|
6627
|
+
# @example Response structure
|
6628
|
+
#
|
6629
|
+
# resp.transformed_logs #=> Array
|
6630
|
+
# resp.transformed_logs[0].event_number #=> Integer
|
6631
|
+
# resp.transformed_logs[0].event_message #=> String
|
6632
|
+
# resp.transformed_logs[0].transformed_event_message #=> String
|
6633
|
+
#
|
6634
|
+
# @see http://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/TestTransformer AWS API Documentation
|
6635
|
+
#
|
6636
|
+
# @overload test_transformer(params = {})
|
6637
|
+
# @param [Hash] params ({})
|
6638
|
+
def test_transformer(params = {}, options = {})
|
6639
|
+
req = build_request(:test_transformer, params)
|
6640
|
+
req.send_request(options)
|
6641
|
+
end
|
6642
|
+
|
5351
6643
|
# The UntagLogGroup operation is on the path to deprecation. We
|
5352
6644
|
# recommend that you use [UntagResource][1] instead.
|
5353
6645
|
#
|
@@ -5626,7 +6918,7 @@ module Aws::CloudWatchLogs
|
|
5626
6918
|
tracer: tracer
|
5627
6919
|
)
|
5628
6920
|
context[:gem_name] = 'aws-sdk-cloudwatchlogs'
|
5629
|
-
context[:gem_version] = '1.
|
6921
|
+
context[:gem_version] = '1.104.0'
|
5630
6922
|
Seahorse::Client::Request.new(handlers, context)
|
5631
6923
|
end
|
5632
6924
|
|