@ThreadSafe public class AWSMarketplaceMeteringAsyncClient extends AWSMarketplaceMeteringClient implements AWSMarketplaceMeteringAsync
AsyncHandler can be used to receive
notification when an asynchronous operation completes.
This reference provides descriptions of the low-level AWS Marketplace Metering Service API.
AWS Marketplace sellers can use this API to submit usage data for custom usage dimensions.
Submitting Metering Records
MeterUsage- Submits the metering record for a Marketplace product.
configFactoryclient, clientConfiguration, endpoint, LOGGING_AWS_REQUEST_METRIC, requestHandler2s, timeOffsetENDPOINT_PREFIX| Constructor and Description |
|---|
AWSMarketplaceMeteringAsyncClient()
Constructs a new asynchronous client to invoke service methods on AWSMarketplace Metering.
|
AWSMarketplaceMeteringAsyncClient(AWSCredentials awsCredentials)
Constructs a new asynchronous client to invoke service methods on AWSMarketplace Metering using the specified AWS
account credentials.
|
AWSMarketplaceMeteringAsyncClient(AWSCredentials awsCredentials,
ClientConfiguration clientConfiguration,
ExecutorService executorService)
Constructs a new asynchronous client to invoke service methods on AWSMarketplace Metering using the specified AWS
account credentials, executor service, and client configuration options.
|
AWSMarketplaceMeteringAsyncClient(AWSCredentials awsCredentials,
ExecutorService executorService)
Constructs a new asynchronous client to invoke service methods on AWSMarketplace Metering using the specified AWS
account credentials and executor service.
|
AWSMarketplaceMeteringAsyncClient(AWSCredentialsProvider awsCredentialsProvider)
Constructs a new asynchronous client to invoke service methods on AWSMarketplace Metering using the specified AWS
account credentials provider.
|
AWSMarketplaceMeteringAsyncClient(AWSCredentialsProvider awsCredentialsProvider,
ClientConfiguration clientConfiguration)
Constructs a new asynchronous client to invoke service methods on AWSMarketplace Metering using the provided AWS
account credentials provider and client configuration options.
|
AWSMarketplaceMeteringAsyncClient(AWSCredentialsProvider awsCredentialsProvider,
ClientConfiguration clientConfiguration,
ExecutorService executorService)
Constructs a new asynchronous client to invoke service methods on AWSMarketplace Metering using the specified AWS
account credentials provider, executor service, and client configuration options.
|
AWSMarketplaceMeteringAsyncClient(AWSCredentialsProvider awsCredentialsProvider,
ExecutorService executorService)
Constructs a new asynchronous client to invoke service methods on AWSMarketplace Metering using the specified AWS
account credentials provider and executor service.
|
AWSMarketplaceMeteringAsyncClient(ClientConfiguration clientConfiguration)
Constructs a new asynchronous client to invoke service methods on AWSMarketplace Metering.
|
| Modifier and Type | Method and Description |
|---|---|
ExecutorService |
getExecutorService()
Returns the executor service used by this client to execute async requests.
|
Future<MeterUsageResult> |
meterUsageAsync(MeterUsageRequest request)
API to emit metering records.
|
Future<MeterUsageResult> |
meterUsageAsync(MeterUsageRequest request,
AsyncHandler<MeterUsageRequest,MeterUsageResult> asyncHandler)
API to emit metering records.
|
void |
shutdown()
Shuts down the client, releasing all managed resources.
|
getCachedResponseMetadata, meterUsageaddRequestHandler, addRequestHandler, beforeMarshalling, calculateCRC32FromCompressedData, checkMutability, configureRegion, createExecutionContext, createExecutionContext, createExecutionContext, createSignerProvider, endClientExecution, endClientExecution, getEndpointPrefix, getRequestMetricsCollector, getServiceAbbreviation, getServiceName, getServiceNameIntern, getSigner, getSignerByURI, getSignerRegionOverride, getTimeOffset, isProfilingEnabled, isRequestMetricsEnabled, makeImmutable, removeRequestHandler, removeRequestHandler, requestMetricCollector, setEndpoint, setEndpointPrefix, setRegion, setServiceNameIntern, setSignerRegionOverride, setTimeOffset, useStrictHostNameVerification, withEndpoint, withRegion, withRegion, withTimeOffsetclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetCachedResponseMetadata, meterUsage, setEndpoint, setRegionpublic AWSMarketplaceMeteringAsyncClient()
Asynchronous methods are delegated to a fixed-size thread pool containing 50 threads (to match the default maximum number of concurrent connections to the service).
public AWSMarketplaceMeteringAsyncClient(ClientConfiguration clientConfiguration)
Asynchronous methods are delegated to a fixed-size thread pool containing a number of threads equal to the
maximum number of concurrent connections configured via ClientConfiguration.getMaxConnections().
clientConfiguration - The client configuration options controlling how this client connects to AWSMarketplace Metering (ex:
proxy settings, retry counts, etc).DefaultAWSCredentialsProviderChain,
Executors.newFixedThreadPool(int)public AWSMarketplaceMeteringAsyncClient(AWSCredentials awsCredentials)
Asynchronous methods are delegated to a fixed-size thread pool containing 50 threads (to match the default maximum number of concurrent connections to the service).
awsCredentials - The AWS credentials (access key ID and secret key) to use when authenticating with AWS services.Executors.newFixedThreadPool(int)public AWSMarketplaceMeteringAsyncClient(AWSCredentials awsCredentials, ExecutorService executorService)
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 AWSMarketplaceMeteringAsyncClient(AWSCredentials awsCredentials, ClientConfiguration clientConfiguration, ExecutorService executorService)
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 AWSMarketplaceMeteringAsyncClient(AWSCredentialsProvider awsCredentialsProvider)
Asynchronous methods are delegated to a fixed-size thread pool containing 50 threads (to match the default maximum number of concurrent connections to the service).
awsCredentialsProvider - The AWS credentials provider which will provide credentials to authenticate requests with AWS services.Executors.newFixedThreadPool(int)public AWSMarketplaceMeteringAsyncClient(AWSCredentialsProvider awsCredentialsProvider, ClientConfiguration clientConfiguration)
Asynchronous methods are delegated to a fixed-size thread pool containing a number of threads equal to the
maximum number of concurrent connections configured via ClientConfiguration.getMaxConnections().
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).DefaultAWSCredentialsProviderChain,
Executors.newFixedThreadPool(int)public AWSMarketplaceMeteringAsyncClient(AWSCredentialsProvider awsCredentialsProvider, ExecutorService executorService)
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 AWSMarketplaceMeteringAsyncClient(AWSCredentialsProvider awsCredentialsProvider, ClientConfiguration clientConfiguration, ExecutorService executorService)
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 Future<MeterUsageResult> meterUsageAsync(MeterUsageRequest request)
AWSMarketplaceMeteringAsyncAPI to emit metering records. For identical requests, the API is idempotent. It simply returns the metering record ID.
meterUsageAsync in interface AWSMarketplaceMeteringAsyncpublic Future<MeterUsageResult> meterUsageAsync(MeterUsageRequest request, AsyncHandler<MeterUsageRequest,MeterUsageResult> asyncHandler)
AWSMarketplaceMeteringAsyncAPI to emit metering records. For identical requests, the API is idempotent. It simply returns the metering record ID.
meterUsageAsync in interface AWSMarketplaceMeteringAsyncasyncHandler - Asynchronous callback handler for events in the lifecycle of the request. Users can provide an
implementation of the callback methods in this interface to receive notification of successful or
unsuccessful completion of the operation.public void shutdown()
getExecutorService().shutdown() followed by getExecutorService().awaitTermination() prior to
calling this method.shutdown in interface AWSMarketplaceMeteringshutdown in class AmazonWebServiceClientCopyright © 2016. All rights reserved.