public class AWSLogsAsyncClient extends AWSLogsClient implements AWSLogsAsync
This is the Amazon CloudWatch Logs API Reference . Amazon CloudWatch Logs is a managed service for real time monitoring and archival of application logs. This guide provides detailed information about Amazon CloudWatch Logs actions, data types, parameters, and errors. For detailed information about Amazon CloudWatch Logs features and their associated API calls, go to the Amazon CloudWatch Logs Developer Guide .
Use the following links to get started using the Amazon CloudWatch Logs API Reference :
In addition to using the Amazon CloudWatch Logs API, you can also use the following SDKs and third-party libraries to access Amazon CloudWatch Logs programmatically.
Developers in the AWS developer community also provide their own libraries, which you can find at the following AWS developer centers:
jsonErrorUnmarshallers
client, clientConfiguration, endpoint, LOGGING_AWS_REQUEST_METRIC, requestHandler2s, timeOffset
Constructor and Description |
---|
AWSLogsAsyncClient()
Constructs a new asynchronous client to invoke service methods on
AWSLogs.
|
AWSLogsAsyncClient(AWSCredentials awsCredentials)
Constructs a new asynchronous client to invoke service methods on
AWSLogs using the specified AWS account credentials.
|
AWSLogsAsyncClient(AWSCredentials awsCredentials,
ClientConfiguration clientConfiguration,
ExecutorService executorService)
Constructs a new asynchronous client to invoke service methods on
AWSLogs using the specified AWS account credentials,
executor service, and client configuration options.
|
AWSLogsAsyncClient(AWSCredentials awsCredentials,
ExecutorService executorService)
Constructs a new asynchronous client to invoke service methods on
AWSLogs using the specified AWS account credentials
and executor service.
|
AWSLogsAsyncClient(AWSCredentialsProvider awsCredentialsProvider)
Constructs a new asynchronous client to invoke service methods on
AWSLogs using the specified AWS account credentials provider.
|
AWSLogsAsyncClient(AWSCredentialsProvider awsCredentialsProvider,
ClientConfiguration clientConfiguration)
Constructs a new asynchronous client to invoke service methods on
AWSLogs using the specified AWS account credentials
provider and client configuration options.
|
AWSLogsAsyncClient(AWSCredentialsProvider awsCredentialsProvider,
ClientConfiguration clientConfiguration,
ExecutorService executorService)
Constructs a new asynchronous client to invoke service methods on
AWSLogs using the specified AWS account credentials
provider, executor service, and client configuration options.
|
AWSLogsAsyncClient(AWSCredentialsProvider awsCredentialsProvider,
ExecutorService executorService)
Constructs a new asynchronous client to invoke service methods on
AWSLogs using the specified AWS account credentials provider
and executor service.
|
AWSLogsAsyncClient(ClientConfiguration clientConfiguration)
Constructs a new asynchronous client to invoke service methods on
AWSLogs.
|
Modifier and Type | Method and Description |
---|---|
Future<Void> |
createLogGroupAsync(CreateLogGroupRequest createLogGroupRequest)
Creates a new log group with the specified name.
|
Future<Void> |
createLogGroupAsync(CreateLogGroupRequest createLogGroupRequest,
AsyncHandler<CreateLogGroupRequest,Void> asyncHandler)
Creates a new log group with the specified name.
|
Future<Void> |
createLogStreamAsync(CreateLogStreamRequest createLogStreamRequest)
Creates a new log stream in the specified log group.
|
Future<Void> |
createLogStreamAsync(CreateLogStreamRequest createLogStreamRequest,
AsyncHandler<CreateLogStreamRequest,Void> asyncHandler)
Creates a new log stream in the specified log group.
|
Future<Void> |
deleteLogGroupAsync(DeleteLogGroupRequest deleteLogGroupRequest)
Deletes the log group with the specified name and permanently deletes
all the archived log events associated with it.
|
Future<Void> |
deleteLogGroupAsync(DeleteLogGroupRequest deleteLogGroupRequest,
AsyncHandler<DeleteLogGroupRequest,Void> asyncHandler)
Deletes the log group with the specified name and permanently deletes
all the archived log events associated with it.
|
Future<Void> |
deleteLogStreamAsync(DeleteLogStreamRequest deleteLogStreamRequest)
Deletes a log stream and permanently deletes all the archived log
events associated with it.
|
Future<Void> |
deleteLogStreamAsync(DeleteLogStreamRequest deleteLogStreamRequest,
AsyncHandler<DeleteLogStreamRequest,Void> asyncHandler)
Deletes a log stream and permanently deletes all the archived log
events associated with it.
|
Future<Void> |
deleteMetricFilterAsync(DeleteMetricFilterRequest deleteMetricFilterRequest)
Deletes a metric filter associated with the specified log group.
|
Future<Void> |
deleteMetricFilterAsync(DeleteMetricFilterRequest deleteMetricFilterRequest,
AsyncHandler<DeleteMetricFilterRequest,Void> asyncHandler)
Deletes a metric filter associated with the specified log group.
|
Future<Void> |
deleteRetentionPolicyAsync(DeleteRetentionPolicyRequest deleteRetentionPolicyRequest)
Deletes the retention policy of the specified log group.
|
Future<Void> |
deleteRetentionPolicyAsync(DeleteRetentionPolicyRequest deleteRetentionPolicyRequest,
AsyncHandler<DeleteRetentionPolicyRequest,Void> asyncHandler)
Deletes the retention policy of the specified log group.
|
Future<DescribeLogGroupsResult> |
describeLogGroupsAsync(DescribeLogGroupsRequest describeLogGroupsRequest)
Returns all the log groups that are associated with the AWS account
making the request.
|
Future<DescribeLogGroupsResult> |
describeLogGroupsAsync(DescribeLogGroupsRequest describeLogGroupsRequest,
AsyncHandler<DescribeLogGroupsRequest,DescribeLogGroupsResult> asyncHandler)
Returns all the log groups that are associated with the AWS account
making the request.
|
Future<DescribeLogStreamsResult> |
describeLogStreamsAsync(DescribeLogStreamsRequest describeLogStreamsRequest)
Returns all the log streams that are associated with the specified
log group.
|
Future<DescribeLogStreamsResult> |
describeLogStreamsAsync(DescribeLogStreamsRequest describeLogStreamsRequest,
AsyncHandler<DescribeLogStreamsRequest,DescribeLogStreamsResult> asyncHandler)
Returns all the log streams that are associated with the specified
log group.
|
Future<DescribeMetricFiltersResult> |
describeMetricFiltersAsync(DescribeMetricFiltersRequest describeMetricFiltersRequest)
Returns all the metrics filters associated with the specified log
group.
|
Future<DescribeMetricFiltersResult> |
describeMetricFiltersAsync(DescribeMetricFiltersRequest describeMetricFiltersRequest,
AsyncHandler<DescribeMetricFiltersRequest,DescribeMetricFiltersResult> asyncHandler)
Returns all the metrics filters associated with the specified log
group.
|
ExecutorService |
getExecutorService()
Returns the executor service used by this async client to execute
requests.
|
Future<GetLogEventsResult> |
getLogEventsAsync(GetLogEventsRequest getLogEventsRequest)
Retrieves log events from the specified log stream.
|
Future<GetLogEventsResult> |
getLogEventsAsync(GetLogEventsRequest getLogEventsRequest,
AsyncHandler<GetLogEventsRequest,GetLogEventsResult> asyncHandler)
Retrieves log events from the specified log stream.
|
Future<PutLogEventsResult> |
putLogEventsAsync(PutLogEventsRequest putLogEventsRequest)
Uploads a batch of log events to the specified log stream.
|
Future<PutLogEventsResult> |
putLogEventsAsync(PutLogEventsRequest putLogEventsRequest,
AsyncHandler<PutLogEventsRequest,PutLogEventsResult> asyncHandler)
Uploads a batch of log events to the specified log stream.
|
Future<Void> |
putMetricFilterAsync(PutMetricFilterRequest putMetricFilterRequest)
Creates or updates a metric filter and associates it with the
specified log group.
|
Future<Void> |
putMetricFilterAsync(PutMetricFilterRequest putMetricFilterRequest,
AsyncHandler<PutMetricFilterRequest,Void> asyncHandler)
Creates or updates a metric filter and associates it with the
specified log group.
|
Future<Void> |
putRetentionPolicyAsync(PutRetentionPolicyRequest putRetentionPolicyRequest)
Sets the retention of the specified log group.
|
Future<Void> |
putRetentionPolicyAsync(PutRetentionPolicyRequest putRetentionPolicyRequest,
AsyncHandler<PutRetentionPolicyRequest,Void> asyncHandler)
Sets the retention of the specified log group.
|
void |
shutdown()
Shuts down the client, releasing all managed resources.
|
Future<TestMetricFilterResult> |
testMetricFilterAsync(TestMetricFilterRequest testMetricFilterRequest)
Tests the filter pattern of a metric filter against a sample of log
event messages.
|
Future<TestMetricFilterResult> |
testMetricFilterAsync(TestMetricFilterRequest testMetricFilterRequest,
AsyncHandler<TestMetricFilterRequest,TestMetricFilterResult> asyncHandler)
Tests the filter pattern of a metric filter against a sample of log
event messages.
|
createLogGroup, createLogStream, deleteLogGroup, deleteLogStream, deleteMetricFilter, deleteRetentionPolicy, describeLogGroups, describeLogGroups, describeLogStreams, describeMetricFilters, getCachedResponseMetadata, getLogEvents, putLogEvents, putMetricFilter, putRetentionPolicy, setEndpoint, setEndpoint, testMetricFilter
addRequestHandler, addRequestHandler, configSigner, configSigner, convertToHttpRequest, createExecutionContext, createExecutionContext, createExecutionContext, endClientExecution, endClientExecution, findRequestMetricCollector, getRequestMetricsCollector, getServiceAbbreviation, getServiceName, getServiceNameIntern, getSigner, getSignerByURI, getSignerRegionOverride, getTimeOffset, isProfilingEnabled, isRequestMetricsEnabled, removeRequestHandler, removeRequestHandler, requestMetricCollector, setConfiguration, setRegion, setServiceNameIntern, setSignerRegionOverride, setTimeOffset, withTimeOffset
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createLogGroup, createLogStream, deleteLogGroup, deleteLogStream, deleteMetricFilter, deleteRetentionPolicy, describeLogGroups, describeLogGroups, describeLogStreams, describeMetricFilters, getCachedResponseMetadata, getLogEvents, putLogEvents, putMetricFilter, putRetentionPolicy, setEndpoint, setRegion, testMetricFilter
public AWSLogsAsyncClient()
All service calls made using this new client object are blocking, and will not return until the service call completes.
DefaultAWSCredentialsProviderChain
public AWSLogsAsyncClient(ClientConfiguration clientConfiguration)
All service calls made using this new client object are blocking, and will not return until the service call completes.
clientConfiguration
- The client configuration options controlling how this
client connects to AWSLogs
(ex: proxy settings, retry counts, etc.).DefaultAWSCredentialsProviderChain
public AWSLogsAsyncClient(AWSCredentials awsCredentials)
All calls made using this new client object are non-blocking, and will immediately return a Java Future object that the caller can later check to see if the service call has actually completed.
awsCredentials
- The AWS credentials (access key ID and secret key) to use
when authenticating with AWS services.public AWSLogsAsyncClient(AWSCredentials awsCredentials, ExecutorService executorService)
All calls made using this new client object are non-blocking, and will immediately return a Java Future object that the caller can later check to see if the service call has actually completed.
awsCredentials
- The AWS credentials (access key ID and secret key) to use
when authenticating with AWS services.executorService
- The executor service by which all asynchronous requests will
be executed.public AWSLogsAsyncClient(AWSCredentials awsCredentials, ClientConfiguration clientConfiguration, ExecutorService executorService)
All calls made using this new client object are non-blocking, and will immediately return a Java Future object that the caller can later check to see if the service call has actually completed.
awsCredentials
- The AWS credentials (access key ID and secret key) to use
when authenticating with AWS services.clientConfiguration
- Client configuration options (ex: max retry limit, proxy
settings, etc).executorService
- The executor service by which all asynchronous requests will
be executed.public AWSLogsAsyncClient(AWSCredentialsProvider awsCredentialsProvider)
All calls made using this new client object are non-blocking, and will immediately return a Java Future object that the caller can later check to see if the service call has actually completed.
awsCredentialsProvider
- The AWS credentials provider which will provide credentials
to authenticate requests with AWS services.public AWSLogsAsyncClient(AWSCredentialsProvider awsCredentialsProvider, ExecutorService executorService)
All calls made using this new client object are non-blocking, and will immediately return a Java Future object that the caller can later check to see if the service call has actually completed.
awsCredentialsProvider
- The AWS credentials provider which will provide credentials
to authenticate requests with AWS services.executorService
- The executor service by which all asynchronous requests will
be executed.public AWSLogsAsyncClient(AWSCredentialsProvider awsCredentialsProvider, ClientConfiguration clientConfiguration)
All calls made using this new client object are non-blocking, and will immediately return a Java Future object that the caller can later check to see if the service call has actually completed.
awsCredentialsProvider
- The AWS credentials provider which will provide credentials
to authenticate requests with AWS services.clientConfiguration
- Client configuration options (ex: max retry limit, proxy
settings, etc).public AWSLogsAsyncClient(AWSCredentialsProvider awsCredentialsProvider, ClientConfiguration clientConfiguration, ExecutorService executorService)
All calls made using this new client object are non-blocking, and will immediately return a Java Future object that the caller can later check to see if the service call has actually completed.
awsCredentialsProvider
- The AWS credentials provider which will provide credentials
to authenticate requests with AWS services.clientConfiguration
- Client configuration options (ex: max retry limit, proxy
settings, etc).executorService
- The executor service by which all asynchronous requests will
be executed.public ExecutorService getExecutorService()
public void shutdown()
shutdown
in interface AWSLogs
shutdown
in class AmazonWebServiceClient
public Future<Void> putRetentionPolicyAsync(PutRetentionPolicyRequest putRetentionPolicyRequest) throws AmazonServiceException, AmazonClientException
Sets the retention of the specified log group. A retention policy allows you to configure the number of days you want to retain log events in the specified log group.
putRetentionPolicyAsync
in interface AWSLogsAsync
putRetentionPolicyRequest
- Container for the necessary
parameters to execute the PutRetentionPolicy operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> putRetentionPolicyAsync(PutRetentionPolicyRequest putRetentionPolicyRequest, AsyncHandler<PutRetentionPolicyRequest,Void> asyncHandler) throws AmazonServiceException, AmazonClientException
Sets the retention of the specified log group. A retention policy allows you to configure the number of days you want to retain log events in the specified log group.
putRetentionPolicyAsync
in interface AWSLogsAsync
putRetentionPolicyRequest
- Container for the necessary
parameters to execute the PutRetentionPolicy operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<DescribeMetricFiltersResult> describeMetricFiltersAsync(DescribeMetricFiltersRequest describeMetricFiltersRequest) throws AmazonServiceException, AmazonClientException
Returns all the metrics filters associated with the specified log group. The list returned in the response is ASCII-sorted by filter name.
By default, this operation returns up to 50 metric filters. If there
are more metric filters to list, the response would contain a
nextToken
value in the response body. You can also limit
the number of metric filters returned in the response by specifying
the limit
parameter in the request.
describeMetricFiltersAsync
in interface AWSLogsAsync
describeMetricFiltersRequest
- Container for the necessary
parameters to execute the DescribeMetricFilters operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<DescribeMetricFiltersResult> describeMetricFiltersAsync(DescribeMetricFiltersRequest describeMetricFiltersRequest, AsyncHandler<DescribeMetricFiltersRequest,DescribeMetricFiltersResult> asyncHandler) throws AmazonServiceException, AmazonClientException
Returns all the metrics filters associated with the specified log group. The list returned in the response is ASCII-sorted by filter name.
By default, this operation returns up to 50 metric filters. If there
are more metric filters to list, the response would contain a
nextToken
value in the response body. You can also limit
the number of metric filters returned in the response by specifying
the limit
parameter in the request.
describeMetricFiltersAsync
in interface AWSLogsAsync
describeMetricFiltersRequest
- Container for the necessary
parameters to execute the DescribeMetricFilters operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<DescribeLogStreamsResult> describeLogStreamsAsync(DescribeLogStreamsRequest describeLogStreamsRequest) throws AmazonServiceException, AmazonClientException
Returns all the log streams that are associated with the specified log group. The list returned in the response is ASCII-sorted by log stream name.
By default, this operation returns up to 50 log streams. If there are
more log streams to list, the response would contain a
nextToken
value in the response body. You can also limit
the number of log streams returned in the response by specifying the
limit
parameter in the request.
describeLogStreamsAsync
in interface AWSLogsAsync
describeLogStreamsRequest
- Container for the necessary
parameters to execute the DescribeLogStreams operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<DescribeLogStreamsResult> describeLogStreamsAsync(DescribeLogStreamsRequest describeLogStreamsRequest, AsyncHandler<DescribeLogStreamsRequest,DescribeLogStreamsResult> asyncHandler) throws AmazonServiceException, AmazonClientException
Returns all the log streams that are associated with the specified log group. The list returned in the response is ASCII-sorted by log stream name.
By default, this operation returns up to 50 log streams. If there are
more log streams to list, the response would contain a
nextToken
value in the response body. You can also limit
the number of log streams returned in the response by specifying the
limit
parameter in the request.
describeLogStreamsAsync
in interface AWSLogsAsync
describeLogStreamsRequest
- Container for the necessary
parameters to execute the DescribeLogStreams operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> deleteLogGroupAsync(DeleteLogGroupRequest deleteLogGroupRequest) throws AmazonServiceException, AmazonClientException
Deletes the log group with the specified name and permanently deletes all the archived log events associated with it.
deleteLogGroupAsync
in interface AWSLogsAsync
deleteLogGroupRequest
- Container for the necessary parameters to
execute the DeleteLogGroup operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> deleteLogGroupAsync(DeleteLogGroupRequest deleteLogGroupRequest, AsyncHandler<DeleteLogGroupRequest,Void> asyncHandler) throws AmazonServiceException, AmazonClientException
Deletes the log group with the specified name and permanently deletes all the archived log events associated with it.
deleteLogGroupAsync
in interface AWSLogsAsync
deleteLogGroupRequest
- Container for the necessary parameters to
execute the DeleteLogGroup operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> createLogGroupAsync(CreateLogGroupRequest createLogGroupRequest) throws AmazonServiceException, AmazonClientException
Creates a new log group with the specified name. The name of the log group must be unique within a region for an AWS account. You can create up to 500 log groups per account.
You must use the following guidelines when naming a log group:
createLogGroupAsync
in interface AWSLogsAsync
createLogGroupRequest
- Container for the necessary parameters to
execute the CreateLogGroup operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> createLogGroupAsync(CreateLogGroupRequest createLogGroupRequest, AsyncHandler<CreateLogGroupRequest,Void> asyncHandler) throws AmazonServiceException, AmazonClientException
Creates a new log group with the specified name. The name of the log group must be unique within a region for an AWS account. You can create up to 500 log groups per account.
You must use the following guidelines when naming a log group:
createLogGroupAsync
in interface AWSLogsAsync
createLogGroupRequest
- Container for the necessary parameters to
execute the CreateLogGroup operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> putMetricFilterAsync(PutMetricFilterRequest putMetricFilterRequest) throws AmazonServiceException, AmazonClientException
Creates or updates a metric filter and associates it with the
specified log group. Metric filters allow you to configure rules to
extract metric data from log events ingested through
PutLogEvents
requests.
putMetricFilterAsync
in interface AWSLogsAsync
putMetricFilterRequest
- Container for the necessary parameters
to execute the PutMetricFilter operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> putMetricFilterAsync(PutMetricFilterRequest putMetricFilterRequest, AsyncHandler<PutMetricFilterRequest,Void> asyncHandler) throws AmazonServiceException, AmazonClientException
Creates or updates a metric filter and associates it with the
specified log group. Metric filters allow you to configure rules to
extract metric data from log events ingested through
PutLogEvents
requests.
putMetricFilterAsync
in interface AWSLogsAsync
putMetricFilterRequest
- Container for the necessary parameters
to execute the PutMetricFilter operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> deleteMetricFilterAsync(DeleteMetricFilterRequest deleteMetricFilterRequest) throws AmazonServiceException, AmazonClientException
Deletes a metric filter associated with the specified log group.
deleteMetricFilterAsync
in interface AWSLogsAsync
deleteMetricFilterRequest
- Container for the necessary
parameters to execute the DeleteMetricFilter operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> deleteMetricFilterAsync(DeleteMetricFilterRequest deleteMetricFilterRequest, AsyncHandler<DeleteMetricFilterRequest,Void> asyncHandler) throws AmazonServiceException, AmazonClientException
Deletes a metric filter associated with the specified log group.
deleteMetricFilterAsync
in interface AWSLogsAsync
deleteMetricFilterRequest
- Container for the necessary
parameters to execute the DeleteMetricFilter operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<TestMetricFilterResult> testMetricFilterAsync(TestMetricFilterRequest testMetricFilterRequest) throws AmazonServiceException, AmazonClientException
Tests the filter pattern of a metric filter against a sample of log event messages. You can use this operation to validate the correctness of a metric filter pattern.
testMetricFilterAsync
in interface AWSLogsAsync
testMetricFilterRequest
- Container for the necessary parameters
to execute the TestMetricFilter operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<TestMetricFilterResult> testMetricFilterAsync(TestMetricFilterRequest testMetricFilterRequest, AsyncHandler<TestMetricFilterRequest,TestMetricFilterResult> asyncHandler) throws AmazonServiceException, AmazonClientException
Tests the filter pattern of a metric filter against a sample of log event messages. You can use this operation to validate the correctness of a metric filter pattern.
testMetricFilterAsync
in interface AWSLogsAsync
testMetricFilterRequest
- Container for the necessary parameters
to execute the TestMetricFilter operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<PutLogEventsResult> putLogEventsAsync(PutLogEventsRequest putLogEventsRequest) throws AmazonServiceException, AmazonClientException
Uploads a batch of log events to the specified log stream.
Every PutLogEvents request must include the
sequenceToken
obtained from the response of the previous
request. An upload in a newly created log stream does not require a
sequenceToken
.
The batch of events must satisfy the following constraints:
timestamp
.putLogEventsAsync
in interface AWSLogsAsync
putLogEventsRequest
- Container for the necessary parameters to
execute the PutLogEvents operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<PutLogEventsResult> putLogEventsAsync(PutLogEventsRequest putLogEventsRequest, AsyncHandler<PutLogEventsRequest,PutLogEventsResult> asyncHandler) throws AmazonServiceException, AmazonClientException
Uploads a batch of log events to the specified log stream.
Every PutLogEvents request must include the
sequenceToken
obtained from the response of the previous
request. An upload in a newly created log stream does not require a
sequenceToken
.
The batch of events must satisfy the following constraints:
timestamp
.putLogEventsAsync
in interface AWSLogsAsync
putLogEventsRequest
- Container for the necessary parameters to
execute the PutLogEvents operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> deleteRetentionPolicyAsync(DeleteRetentionPolicyRequest deleteRetentionPolicyRequest) throws AmazonServiceException, AmazonClientException
Deletes the retention policy of the specified log group. Log events would not expire if they belong to log groups without a retention policy.
deleteRetentionPolicyAsync
in interface AWSLogsAsync
deleteRetentionPolicyRequest
- Container for the necessary
parameters to execute the DeleteRetentionPolicy operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> deleteRetentionPolicyAsync(DeleteRetentionPolicyRequest deleteRetentionPolicyRequest, AsyncHandler<DeleteRetentionPolicyRequest,Void> asyncHandler) throws AmazonServiceException, AmazonClientException
Deletes the retention policy of the specified log group. Log events would not expire if they belong to log groups without a retention policy.
deleteRetentionPolicyAsync
in interface AWSLogsAsync
deleteRetentionPolicyRequest
- Container for the necessary
parameters to execute the DeleteRetentionPolicy operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<GetLogEventsResult> getLogEventsAsync(GetLogEventsRequest getLogEventsRequest) throws AmazonServiceException, AmazonClientException
Retrieves log events from the specified log stream. You can provide
an optional time range to filter the results on the event
timestamp
.
By default, this operation returns as much log events as can fit in a
response size of 1MB, up to 10,000 log events. The response will
always include a nextForwardToken
and a
nextBackwardToken
in the response body. You can use any
of these tokens in subsequent GetLogEvents
requests to
paginate through events in either forward or backward direction. You
can also limit the number of log events returned in the response by
specifying the limit
parameter in the request.
getLogEventsAsync
in interface AWSLogsAsync
getLogEventsRequest
- Container for the necessary parameters to
execute the GetLogEvents operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<GetLogEventsResult> getLogEventsAsync(GetLogEventsRequest getLogEventsRequest, AsyncHandler<GetLogEventsRequest,GetLogEventsResult> asyncHandler) throws AmazonServiceException, AmazonClientException
Retrieves log events from the specified log stream. You can provide
an optional time range to filter the results on the event
timestamp
.
By default, this operation returns as much log events as can fit in a
response size of 1MB, up to 10,000 log events. The response will
always include a nextForwardToken
and a
nextBackwardToken
in the response body. You can use any
of these tokens in subsequent GetLogEvents
requests to
paginate through events in either forward or backward direction. You
can also limit the number of log events returned in the response by
specifying the limit
parameter in the request.
getLogEventsAsync
in interface AWSLogsAsync
getLogEventsRequest
- Container for the necessary parameters to
execute the GetLogEvents operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> createLogStreamAsync(CreateLogStreamRequest createLogStreamRequest) throws AmazonServiceException, AmazonClientException
Creates a new log stream in the specified log group. The name of the log stream must be unique within the log group. There is no limit on the number of log streams that can exist in a log group.
You must use the following guidelines when naming a log stream:
createLogStreamAsync
in interface AWSLogsAsync
createLogStreamRequest
- Container for the necessary parameters
to execute the CreateLogStream operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> createLogStreamAsync(CreateLogStreamRequest createLogStreamRequest, AsyncHandler<CreateLogStreamRequest,Void> asyncHandler) throws AmazonServiceException, AmazonClientException
Creates a new log stream in the specified log group. The name of the log stream must be unique within the log group. There is no limit on the number of log streams that can exist in a log group.
You must use the following guidelines when naming a log stream:
createLogStreamAsync
in interface AWSLogsAsync
createLogStreamRequest
- Container for the necessary parameters
to execute the CreateLogStream operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> deleteLogStreamAsync(DeleteLogStreamRequest deleteLogStreamRequest) throws AmazonServiceException, AmazonClientException
Deletes a log stream and permanently deletes all the archived log events associated with it.
deleteLogStreamAsync
in interface AWSLogsAsync
deleteLogStreamRequest
- Container for the necessary parameters
to execute the DeleteLogStream operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<Void> deleteLogStreamAsync(DeleteLogStreamRequest deleteLogStreamRequest, AsyncHandler<DeleteLogStreamRequest,Void> asyncHandler) throws AmazonServiceException, AmazonClientException
Deletes a log stream and permanently deletes all the archived log events associated with it.
deleteLogStreamAsync
in interface AWSLogsAsync
deleteLogStreamRequest
- Container for the necessary parameters
to execute the DeleteLogStream operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<DescribeLogGroupsResult> describeLogGroupsAsync(DescribeLogGroupsRequest describeLogGroupsRequest) throws AmazonServiceException, AmazonClientException
Returns all the log groups that are associated with the AWS account making the request. The list returned in the response is ASCII-sorted by log group name.
By default, this operation returns up to 50 log groups. If there are
more log groups to list, the response would contain a
nextToken
value in the response body. You can also limit
the number of log groups returned in the response by specifying the
limit
parameter in the request.
describeLogGroupsAsync
in interface AWSLogsAsync
describeLogGroupsRequest
- Container for the necessary parameters
to execute the DescribeLogGroups operation on AWSLogs.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.public Future<DescribeLogGroupsResult> describeLogGroupsAsync(DescribeLogGroupsRequest describeLogGroupsRequest, AsyncHandler<DescribeLogGroupsRequest,DescribeLogGroupsResult> asyncHandler) throws AmazonServiceException, AmazonClientException
Returns all the log groups that are associated with the AWS account making the request. The list returned in the response is ASCII-sorted by log group name.
By default, this operation returns up to 50 log groups. If there are
more log groups to list, the response would contain a
nextToken
value in the response body. You can also limit
the number of log groups returned in the response by specifying the
limit
parameter in the request.
describeLogGroupsAsync
in interface AWSLogsAsync
describeLogGroupsRequest
- Container for the necessary parameters
to execute the DescribeLogGroups operation on AWSLogs.asyncHandler
- Asynchronous callback handler for events in the
life-cycle of the request. Users could provide the implementation of
the four callback methods in this interface to process the operation
result or handle the exception.AmazonClientException
- If any internal errors are encountered inside the client while
attempting to make the request or handle the response. For example
if a network connection is not available.AmazonServiceException
- If an error response is returned by AWSLogs indicating
either a problem with the data in the request, or a server side issue.Copyright © 2014. All rights reserved.