/* * Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions * and limitations under the License. */ package com.amazonaws.services.opensearchserverless; import org.w3c.dom.*; import java.net.*; import java.util.*; import javax.annotation.Generated; import org.apache.commons.logging.*; import com.amazonaws.*; import com.amazonaws.annotation.SdkInternalApi; import com.amazonaws.auth.*; import com.amazonaws.handlers.*; import com.amazonaws.http.*; import com.amazonaws.internal.*; import com.amazonaws.internal.auth.*; import com.amazonaws.metrics.*; import com.amazonaws.regions.*; import com.amazonaws.transform.*; import com.amazonaws.util.*; import com.amazonaws.protocol.json.*; import com.amazonaws.util.AWSRequestMetrics.Field; import com.amazonaws.annotation.ThreadSafe; import com.amazonaws.client.AwsSyncClientParams; import com.amazonaws.client.builder.AdvancedConfig; import com.amazonaws.services.opensearchserverless.AWSOpenSearchServerlessClientBuilder; import com.amazonaws.AmazonServiceException; import com.amazonaws.services.opensearchserverless.model.*; import com.amazonaws.services.opensearchserverless.model.transform.*; /** * Client for accessing OpenSearch Service Serverless. All service calls made using this client are blocking, and will * not return until the service call completes. *
*
* Use the Amazon OpenSearch Serverless API to create, configure, and manage OpenSearch Serverless collections and * security policies. *
** OpenSearch Serverless is an on-demand, pre-provisioned serverless configuration for Amazon OpenSearch Service. * OpenSearch Serverless removes the operational complexities of provisioning, configuring, and tuning your OpenSearch * clusters. It enables you to easily search and analyze petabytes of data without having to worry about the underlying * infrastructure and data management. *
** To learn more about OpenSearch Serverless, see What is Amazon * OpenSearch Serverless? *
*/ @ThreadSafe @Generated("com.amazonaws:aws-java-sdk-code-generator") public class AWSOpenSearchServerlessClient extends AmazonWebServiceClient implements AWSOpenSearchServerless { /** Provider for AWS credentials. */ private final AWSCredentialsProvider awsCredentialsProvider; private static final Log log = LogFactory.getLog(AWSOpenSearchServerless.class); /** Default signing name for the service. */ private static final String DEFAULT_SIGNING_NAME = "aoss"; /** Client configuration factory providing ClientConfigurations tailored to this client */ protected static final ClientConfigurationFactory configFactory = new ClientConfigurationFactory(); private final AdvancedConfig advancedConfig; private static final com.amazonaws.protocol.json.SdkJsonProtocolFactory protocolFactory = new com.amazonaws.protocol.json.SdkJsonProtocolFactory( new JsonClientMetadata() .withProtocolVersion("1.0") .withSupportsCbor(false) .withSupportsIon(false) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("ServiceQuotaExceededException").withExceptionUnmarshaller( com.amazonaws.services.opensearchserverless.model.transform.ServiceQuotaExceededExceptionUnmarshaller.getInstance())) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("InternalServerException").withExceptionUnmarshaller( com.amazonaws.services.opensearchserverless.model.transform.InternalServerExceptionUnmarshaller.getInstance())) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("ConflictException").withExceptionUnmarshaller( com.amazonaws.services.opensearchserverless.model.transform.ConflictExceptionUnmarshaller.getInstance())) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("ResourceNotFoundException").withExceptionUnmarshaller( com.amazonaws.services.opensearchserverless.model.transform.ResourceNotFoundExceptionUnmarshaller.getInstance())) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("ValidationException").withExceptionUnmarshaller( com.amazonaws.services.opensearchserverless.model.transform.ValidationExceptionUnmarshaller.getInstance())) .addErrorMetadata( new JsonErrorShapeMetadata().withErrorCode("OcuLimitExceededException").withExceptionUnmarshaller( com.amazonaws.services.opensearchserverless.model.transform.OcuLimitExceededExceptionUnmarshaller.getInstance())) .withBaseServiceExceptionClass(com.amazonaws.services.opensearchserverless.model.AWSOpenSearchServerlessException.class)); public static AWSOpenSearchServerlessClientBuilder builder() { return AWSOpenSearchServerlessClientBuilder.standard(); } /** * Constructs a new client to invoke service methods on OpenSearch Service Serverless using the specified * parameters. * ** All service calls made using this new client object are blocking, and will not return until the service call * completes. * * @param clientParams * Object providing client parameters. */ AWSOpenSearchServerlessClient(AwsSyncClientParams clientParams) { this(clientParams, false); } /** * Constructs a new client to invoke service methods on OpenSearch Service Serverless using the specified * parameters. * *
* All service calls made using this new client object are blocking, and will not return until the service call * completes. * * @param clientParams * Object providing client parameters. */ AWSOpenSearchServerlessClient(AwsSyncClientParams clientParams, boolean endpointDiscoveryEnabled) { super(clientParams); this.awsCredentialsProvider = clientParams.getCredentialsProvider(); this.advancedConfig = clientParams.getAdvancedConfig(); init(); } private void init() { setServiceNameIntern(DEFAULT_SIGNING_NAME); setEndpointPrefix(ENDPOINT_PREFIX); // calling this.setEndPoint(...) will also modify the signer accordingly setEndpoint("aoss.us-east-1.amazonaws.com"); HandlerChainFactory chainFactory = new HandlerChainFactory(); requestHandler2s.addAll(chainFactory.newRequestHandlerChain("/com/amazonaws/services/opensearchserverless/request.handlers")); requestHandler2s.addAll(chainFactory.newRequestHandler2Chain("/com/amazonaws/services/opensearchserverless/request.handler2s")); requestHandler2s.addAll(chainFactory.getGlobalHandlers()); } /** *
* Returns attributes for one or more collections, including the collection endpoint and the OpenSearch Dashboards * endpoint. For more information, see Creating and * managing Amazon OpenSearch Serverless collections. *
* * @param batchGetCollectionRequest * @return Result of the BatchGetCollection operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.BatchGetCollection * @see AWS API Documentation */ @Override public BatchGetCollectionResult batchGetCollection(BatchGetCollectionRequest request) { request = beforeClientExecution(request); return executeBatchGetCollection(request); } @SdkInternalApi final BatchGetCollectionResult executeBatchGetCollection(BatchGetCollectionRequest batchGetCollectionRequest) { ExecutionContext executionContext = createExecutionContext(batchGetCollectionRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Returns attributes for one or more VPC endpoints associated with the current account. For more information, see * Access Amazon * OpenSearch Serverless using an interface endpoint. *
* * @param batchGetVpcEndpointRequest * @return Result of the BatchGetVpcEndpoint operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.BatchGetVpcEndpoint * @see AWS API Documentation */ @Override public BatchGetVpcEndpointResult batchGetVpcEndpoint(BatchGetVpcEndpointRequest request) { request = beforeClientExecution(request); return executeBatchGetVpcEndpoint(request); } @SdkInternalApi final BatchGetVpcEndpointResult executeBatchGetVpcEndpoint(BatchGetVpcEndpointRequest batchGetVpcEndpointRequest) { ExecutionContext executionContext = createExecutionContext(batchGetVpcEndpointRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Creates a data access policy for OpenSearch Serverless. Access policies limit access to collections and the * resources within them, and allow a user to access that data irrespective of the access mechanism or network * source. For more information, see Data * access control for Amazon OpenSearch Serverless. *
* * @param createAccessPolicyRequest * @return Result of the CreateAccessPolicy operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @throws ServiceQuotaExceededException * Thrown when you attempt to create more resources than the service allows based on service quotas. * @sample AWSOpenSearchServerless.CreateAccessPolicy * @see AWS API Documentation */ @Override public CreateAccessPolicyResult createAccessPolicy(CreateAccessPolicyRequest request) { request = beforeClientExecution(request); return executeCreateAccessPolicy(request); } @SdkInternalApi final CreateAccessPolicyResult executeCreateAccessPolicy(CreateAccessPolicyRequest createAccessPolicyRequest) { ExecutionContext executionContext = createExecutionContext(createAccessPolicyRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Creates a new OpenSearch Serverless collection. For more information, see Creating and * managing Amazon OpenSearch Serverless collections. *
* * @param createCollectionRequest * @return Result of the CreateCollection operation returned by the service. * @throws OcuLimitExceededException * Thrown when the collection you're attempting to create results in a number of search or indexing OCUs * that exceeds the account limit. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @throws ServiceQuotaExceededException * Thrown when you attempt to create more resources than the service allows based on service quotas. * @sample AWSOpenSearchServerless.CreateCollection * @see AWS API Documentation */ @Override public CreateCollectionResult createCollection(CreateCollectionRequest request) { request = beforeClientExecution(request); return executeCreateCollection(request); } @SdkInternalApi final CreateCollectionResult executeCreateCollection(CreateCollectionRequest createCollectionRequest) { ExecutionContext executionContext = createExecutionContext(createCollectionRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Specifies a security configuration for OpenSearch Serverless. For more information, see SAML * authentication for Amazon OpenSearch Serverless. *
* * @param createSecurityConfigRequest * @return Result of the CreateSecurityConfig operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @throws ServiceQuotaExceededException * Thrown when you attempt to create more resources than the service allows based on service quotas. * @sample AWSOpenSearchServerless.CreateSecurityConfig * @see AWS API Documentation */ @Override public CreateSecurityConfigResult createSecurityConfig(CreateSecurityConfigRequest request) { request = beforeClientExecution(request); return executeCreateSecurityConfig(request); } @SdkInternalApi final CreateSecurityConfigResult executeCreateSecurityConfig(CreateSecurityConfigRequest createSecurityConfigRequest) { ExecutionContext executionContext = createExecutionContext(createSecurityConfigRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Creates a security policy to be used by one or more OpenSearch Serverless collections. Security policies provide * access to a collection and its OpenSearch Dashboards endpoint from public networks or specific VPC endpoints. * They also allow you to secure a collection with a KMS encryption key. For more information, see Network * access for Amazon OpenSearch Serverless and Encryption * at rest for Amazon OpenSearch Serverless. *
* * @param createSecurityPolicyRequest * @return Result of the CreateSecurityPolicy operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @throws ServiceQuotaExceededException * Thrown when you attempt to create more resources than the service allows based on service quotas. * @sample AWSOpenSearchServerless.CreateSecurityPolicy * @see AWS API Documentation */ @Override public CreateSecurityPolicyResult createSecurityPolicy(CreateSecurityPolicyRequest request) { request = beforeClientExecution(request); return executeCreateSecurityPolicy(request); } @SdkInternalApi final CreateSecurityPolicyResult executeCreateSecurityPolicy(CreateSecurityPolicyRequest createSecurityPolicyRequest) { ExecutionContext executionContext = createExecutionContext(createSecurityPolicyRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Creates an OpenSearch Serverless-managed interface VPC endpoint. For more information, see Access Amazon * OpenSearch Serverless using an interface endpoint. *
* * @param createVpcEndpointRequest * @return Result of the CreateVpcEndpoint operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @throws ServiceQuotaExceededException * Thrown when you attempt to create more resources than the service allows based on service quotas. * @sample AWSOpenSearchServerless.CreateVpcEndpoint * @see AWS API Documentation */ @Override public CreateVpcEndpointResult createVpcEndpoint(CreateVpcEndpointRequest request) { request = beforeClientExecution(request); return executeCreateVpcEndpoint(request); } @SdkInternalApi final CreateVpcEndpointResult executeCreateVpcEndpoint(CreateVpcEndpointRequest createVpcEndpointRequest) { ExecutionContext executionContext = createExecutionContext(createVpcEndpointRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Deletes an OpenSearch Serverless access policy. For more information, see Data * access control for Amazon OpenSearch Serverless. *
* * @param deleteAccessPolicyRequest * @return Result of the DeleteAccessPolicy operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.DeleteAccessPolicy * @see AWS API Documentation */ @Override public DeleteAccessPolicyResult deleteAccessPolicy(DeleteAccessPolicyRequest request) { request = beforeClientExecution(request); return executeDeleteAccessPolicy(request); } @SdkInternalApi final DeleteAccessPolicyResult executeDeleteAccessPolicy(DeleteAccessPolicyRequest deleteAccessPolicyRequest) { ExecutionContext executionContext = createExecutionContext(deleteAccessPolicyRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Deletes an OpenSearch Serverless collection. For more information, see Creating and * managing Amazon OpenSearch Serverless collections. *
* * @param deleteCollectionRequest * @return Result of the DeleteCollection operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.DeleteCollection * @see AWS API Documentation */ @Override public DeleteCollectionResult deleteCollection(DeleteCollectionRequest request) { request = beforeClientExecution(request); return executeDeleteCollection(request); } @SdkInternalApi final DeleteCollectionResult executeDeleteCollection(DeleteCollectionRequest deleteCollectionRequest) { ExecutionContext executionContext = createExecutionContext(deleteCollectionRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Deletes a security configuration for OpenSearch Serverless. For more information, see SAML * authentication for Amazon OpenSearch Serverless. *
* * @param deleteSecurityConfigRequest * @return Result of the DeleteSecurityConfig operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.DeleteSecurityConfig * @see AWS API Documentation */ @Override public DeleteSecurityConfigResult deleteSecurityConfig(DeleteSecurityConfigRequest request) { request = beforeClientExecution(request); return executeDeleteSecurityConfig(request); } @SdkInternalApi final DeleteSecurityConfigResult executeDeleteSecurityConfig(DeleteSecurityConfigRequest deleteSecurityConfigRequest) { ExecutionContext executionContext = createExecutionContext(deleteSecurityConfigRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Deletes an OpenSearch Serverless security policy. *
* * @param deleteSecurityPolicyRequest * @return Result of the DeleteSecurityPolicy operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.DeleteSecurityPolicy * @see AWS API Documentation */ @Override public DeleteSecurityPolicyResult deleteSecurityPolicy(DeleteSecurityPolicyRequest request) { request = beforeClientExecution(request); return executeDeleteSecurityPolicy(request); } @SdkInternalApi final DeleteSecurityPolicyResult executeDeleteSecurityPolicy(DeleteSecurityPolicyRequest deleteSecurityPolicyRequest) { ExecutionContext executionContext = createExecutionContext(deleteSecurityPolicyRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Deletes an OpenSearch Serverless-managed interface endpoint. For more information, see Access Amazon * OpenSearch Serverless using an interface endpoint. *
* * @param deleteVpcEndpointRequest * @return Result of the DeleteVpcEndpoint operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.DeleteVpcEndpoint * @see AWS API Documentation */ @Override public DeleteVpcEndpointResult deleteVpcEndpoint(DeleteVpcEndpointRequest request) { request = beforeClientExecution(request); return executeDeleteVpcEndpoint(request); } @SdkInternalApi final DeleteVpcEndpointResult executeDeleteVpcEndpoint(DeleteVpcEndpointRequest deleteVpcEndpointRequest) { ExecutionContext executionContext = createExecutionContext(deleteVpcEndpointRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Returns an OpenSearch Serverless access policy. For more information, see Data * access control for Amazon OpenSearch Serverless. *
* * @param getAccessPolicyRequest * @return Result of the GetAccessPolicy operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.GetAccessPolicy * @see AWS API Documentation */ @Override public GetAccessPolicyResult getAccessPolicy(GetAccessPolicyRequest request) { request = beforeClientExecution(request); return executeGetAccessPolicy(request); } @SdkInternalApi final GetAccessPolicyResult executeGetAccessPolicy(GetAccessPolicyRequest getAccessPolicyRequest) { ExecutionContext executionContext = createExecutionContext(getAccessPolicyRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Returns account-level settings related to OpenSearch Serverless. *
* * @param getAccountSettingsRequest * @return Result of the GetAccountSettings operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.GetAccountSettings * @see AWS API Documentation */ @Override public GetAccountSettingsResult getAccountSettings(GetAccountSettingsRequest request) { request = beforeClientExecution(request); return executeGetAccountSettings(request); } @SdkInternalApi final GetAccountSettingsResult executeGetAccountSettings(GetAccountSettingsRequest getAccountSettingsRequest) { ExecutionContext executionContext = createExecutionContext(getAccountSettingsRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Returns statistical information about your OpenSearch Serverless access policies, security configurations, and * security policies. *
* * @param getPoliciesStatsRequest * @return Result of the GetPoliciesStats operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @sample AWSOpenSearchServerless.GetPoliciesStats * @see AWS API Documentation */ @Override public GetPoliciesStatsResult getPoliciesStats(GetPoliciesStatsRequest request) { request = beforeClientExecution(request); return executeGetPoliciesStats(request); } @SdkInternalApi final GetPoliciesStatsResult executeGetPoliciesStats(GetPoliciesStatsRequest getPoliciesStatsRequest) { ExecutionContext executionContext = createExecutionContext(getPoliciesStatsRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Returns information about an OpenSearch Serverless security configuration. For more information, see SAML * authentication for Amazon OpenSearch Serverless. *
* * @param getSecurityConfigRequest * @return Result of the GetSecurityConfig operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.GetSecurityConfig * @see AWS API Documentation */ @Override public GetSecurityConfigResult getSecurityConfig(GetSecurityConfigRequest request) { request = beforeClientExecution(request); return executeGetSecurityConfig(request); } @SdkInternalApi final GetSecurityConfigResult executeGetSecurityConfig(GetSecurityConfigRequest getSecurityConfigRequest) { ExecutionContext executionContext = createExecutionContext(getSecurityConfigRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Returns information about a configured OpenSearch Serverless security policy. For more information, see Network * access for Amazon OpenSearch Serverless and Encryption * at rest for Amazon OpenSearch Serverless. *
* * @param getSecurityPolicyRequest * @return Result of the GetSecurityPolicy operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.GetSecurityPolicy * @see AWS API Documentation */ @Override public GetSecurityPolicyResult getSecurityPolicy(GetSecurityPolicyRequest request) { request = beforeClientExecution(request); return executeGetSecurityPolicy(request); } @SdkInternalApi final GetSecurityPolicyResult executeGetSecurityPolicy(GetSecurityPolicyRequest getSecurityPolicyRequest) { ExecutionContext executionContext = createExecutionContext(getSecurityPolicyRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Returns information about a list of OpenSearch Serverless access policies. *
* * @param listAccessPoliciesRequest * @return Result of the ListAccessPolicies operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.ListAccessPolicies * @see AWS API Documentation */ @Override public ListAccessPoliciesResult listAccessPolicies(ListAccessPoliciesRequest request) { request = beforeClientExecution(request); return executeListAccessPolicies(request); } @SdkInternalApi final ListAccessPoliciesResult executeListAccessPolicies(ListAccessPoliciesRequest listAccessPoliciesRequest) { ExecutionContext executionContext = createExecutionContext(listAccessPoliciesRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Lists all OpenSearch Serverless collections. For more information, see Creating and * managing Amazon OpenSearch Serverless collections. *
** Make sure to include an empty request body {} if you don't include any collection filters in the request. *
** Returns information about configured OpenSearch Serverless security configurations. For more information, see SAML * authentication for Amazon OpenSearch Serverless. *
* * @param listSecurityConfigsRequest * @return Result of the ListSecurityConfigs operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.ListSecurityConfigs * @see AWS API Documentation */ @Override public ListSecurityConfigsResult listSecurityConfigs(ListSecurityConfigsRequest request) { request = beforeClientExecution(request); return executeListSecurityConfigs(request); } @SdkInternalApi final ListSecurityConfigsResult executeListSecurityConfigs(ListSecurityConfigsRequest listSecurityConfigsRequest) { ExecutionContext executionContext = createExecutionContext(listSecurityConfigsRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Returns information about configured OpenSearch Serverless security policies. *
* * @param listSecurityPoliciesRequest * @return Result of the ListSecurityPolicies operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.ListSecurityPolicies * @see AWS API Documentation */ @Override public ListSecurityPoliciesResult listSecurityPolicies(ListSecurityPoliciesRequest request) { request = beforeClientExecution(request); return executeListSecurityPolicies(request); } @SdkInternalApi final ListSecurityPoliciesResult executeListSecurityPolicies(ListSecurityPoliciesRequest listSecurityPoliciesRequest) { ExecutionContext executionContext = createExecutionContext(listSecurityPoliciesRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Returns the tags for an OpenSearch Serverless resource. For more information, see Tagging Amazon * OpenSearch Serverless collections. *
* * @param listTagsForResourceRequest * @return Result of the ListTagsForResource operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.ListTagsForResource * @see AWS API Documentation */ @Override public ListTagsForResourceResult listTagsForResource(ListTagsForResourceRequest request) { request = beforeClientExecution(request); return executeListTagsForResource(request); } @SdkInternalApi final ListTagsForResourceResult executeListTagsForResource(ListTagsForResourceRequest listTagsForResourceRequest) { ExecutionContext executionContext = createExecutionContext(listTagsForResourceRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Returns the OpenSearch Serverless-managed interface VPC endpoints associated with the current account. For more * information, see Access Amazon * OpenSearch Serverless using an interface endpoint. *
* * @param listVpcEndpointsRequest * @return Result of the ListVpcEndpoints operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.ListVpcEndpoints * @see AWS API Documentation */ @Override public ListVpcEndpointsResult listVpcEndpoints(ListVpcEndpointsRequest request) { request = beforeClientExecution(request); return executeListVpcEndpoints(request); } @SdkInternalApi final ListVpcEndpointsResult executeListVpcEndpoints(ListVpcEndpointsRequest listVpcEndpointsRequest) { ExecutionContext executionContext = createExecutionContext(listVpcEndpointsRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Associates tags with an OpenSearch Serverless resource. For more information, see Tagging Amazon * OpenSearch Serverless collections. *
* * @param tagResourceRequest * @return Result of the TagResource operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @throws ServiceQuotaExceededException * Thrown when you attempt to create more resources than the service allows based on service quotas. * @sample AWSOpenSearchServerless.TagResource * @see AWS API Documentation */ @Override public TagResourceResult tagResource(TagResourceRequest request) { request = beforeClientExecution(request); return executeTagResource(request); } @SdkInternalApi final TagResourceResult executeTagResource(TagResourceRequest tagResourceRequest) { ExecutionContext executionContext = createExecutionContext(tagResourceRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Removes a tag or set of tags from an OpenSearch Serverless resource. For more information, see Tagging Amazon * OpenSearch Serverless collections. *
* * @param untagResourceRequest * @return Result of the UntagResource operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.UntagResource * @see AWS API Documentation */ @Override public UntagResourceResult untagResource(UntagResourceRequest request) { request = beforeClientExecution(request); return executeUntagResource(request); } @SdkInternalApi final UntagResourceResult executeUntagResource(UntagResourceRequest untagResourceRequest) { ExecutionContext executionContext = createExecutionContext(untagResourceRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Updates an OpenSearch Serverless access policy. For more information, see Data * access control for Amazon OpenSearch Serverless. *
* * @param updateAccessPolicyRequest * @return Result of the UpdateAccessPolicy operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.UpdateAccessPolicy * @see AWS API Documentation */ @Override public UpdateAccessPolicyResult updateAccessPolicy(UpdateAccessPolicyRequest request) { request = beforeClientExecution(request); return executeUpdateAccessPolicy(request); } @SdkInternalApi final UpdateAccessPolicyResult executeUpdateAccessPolicy(UpdateAccessPolicyRequest updateAccessPolicyRequest) { ExecutionContext executionContext = createExecutionContext(updateAccessPolicyRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Update the OpenSearch Serverless settings for the current Amazon Web Services account. For more information, see * Managing * capacity limits for Amazon OpenSearch Serverless. *
* * @param updateAccountSettingsRequest * @return Result of the UpdateAccountSettings operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.UpdateAccountSettings * @see AWS API Documentation */ @Override public UpdateAccountSettingsResult updateAccountSettings(UpdateAccountSettingsRequest request) { request = beforeClientExecution(request); return executeUpdateAccountSettings(request); } @SdkInternalApi final UpdateAccountSettingsResult executeUpdateAccountSettings(UpdateAccountSettingsRequest updateAccountSettingsRequest) { ExecutionContext executionContext = createExecutionContext(updateAccountSettingsRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Updates an OpenSearch Serverless collection. *
* * @param updateCollectionRequest * @return Result of the UpdateCollection operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.UpdateCollection * @see AWS API Documentation */ @Override public UpdateCollectionResult updateCollection(UpdateCollectionRequest request) { request = beforeClientExecution(request); return executeUpdateCollection(request); } @SdkInternalApi final UpdateCollectionResult executeUpdateCollection(UpdateCollectionRequest updateCollectionRequest) { ExecutionContext executionContext = createExecutionContext(updateCollectionRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Updates a security configuration for OpenSearch Serverless. For more information, see SAML * authentication for Amazon OpenSearch Serverless. *
* * @param updateSecurityConfigRequest * @return Result of the UpdateSecurityConfig operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.UpdateSecurityConfig * @see AWS API Documentation */ @Override public UpdateSecurityConfigResult updateSecurityConfig(UpdateSecurityConfigRequest request) { request = beforeClientExecution(request); return executeUpdateSecurityConfig(request); } @SdkInternalApi final UpdateSecurityConfigResult executeUpdateSecurityConfig(UpdateSecurityConfigRequest updateSecurityConfigRequest) { ExecutionContext executionContext = createExecutionContext(updateSecurityConfigRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Updates an OpenSearch Serverless security policy. For more information, see Network * access for Amazon OpenSearch Serverless and Encryption * at rest for Amazon OpenSearch Serverless. *
* * @param updateSecurityPolicyRequest * @return Result of the UpdateSecurityPolicy operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ResourceNotFoundException * Thrown when accessing or deleting a resource that does not exist. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @throws ServiceQuotaExceededException * Thrown when you attempt to create more resources than the service allows based on service quotas. * @sample AWSOpenSearchServerless.UpdateSecurityPolicy * @see AWS API Documentation */ @Override public UpdateSecurityPolicyResult updateSecurityPolicy(UpdateSecurityPolicyRequest request) { request = beforeClientExecution(request); return executeUpdateSecurityPolicy(request); } @SdkInternalApi final UpdateSecurityPolicyResult executeUpdateSecurityPolicy(UpdateSecurityPolicyRequest updateSecurityPolicyRequest) { ExecutionContext executionContext = createExecutionContext(updateSecurityPolicyRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request* Updates an OpenSearch Serverless-managed interface endpoint. For more information, see Access Amazon * OpenSearch Serverless using an interface endpoint. *
* * @param updateVpcEndpointRequest * @return Result of the UpdateVpcEndpoint operation returned by the service. * @throws InternalServerException * Thrown when an error internal to the service occurs while processing a request. * @throws ConflictException * When creating a resource, thrown when a resource with the same name already exists or is being created. * When deleting a resource, thrown when the resource is not in the ACTIVE or FAILED state. * @throws ValidationException * Thrown when the HTTP request contains invalid input or is missing required input. * @sample AWSOpenSearchServerless.UpdateVpcEndpoint * @see AWS API Documentation */ @Override public UpdateVpcEndpointResult updateVpcEndpoint(UpdateVpcEndpointRequest request) { request = beforeClientExecution(request); return executeUpdateVpcEndpoint(request); } @SdkInternalApi final UpdateVpcEndpointResult executeUpdateVpcEndpoint(UpdateVpcEndpointRequest updateVpcEndpointRequest) { ExecutionContext executionContext = createExecutionContext(updateVpcEndpointRequest); AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); awsRequestMetrics.startEvent(Field.ClientExecuteTime); Request
* Response metadata is only cached for a limited period of time, so if you need to access this extra diagnostic
* information for an executed request, you should use this method to retrieve it as soon as possible after
* executing the request.
*
* @param request
* The originally executed request
*
* @return The response metadata for the specified request, or null if none is available.
*/
public ResponseMetadata getCachedResponseMetadata(AmazonWebServiceRequest request) {
return client.getResponseMetadataForRequest(request);
}
/**
* Normal invoke with authentication. Credentials are required and may be overriden at the request level.
**/
private