/** * Builds a InstanceProfileExists waiter by using custom parameters waiterParameters and other parameters defined in * the waiters specification, and then polls until it determines whether the resource entered the desired state or * not, where polling criteria is bound by either default polling strategy or custom polling strategy. */ public Waiter<GetInstanceProfileRequest> instanceProfileExists() { return new WaiterBuilder<GetInstanceProfileRequest, GetInstanceProfileResult>().withSdkFunction(new GetInstanceProfileFunction(client)) .withAcceptors(new HttpSuccessStatusAcceptor(WaiterState.SUCCESS), new HttpFailureStatusAcceptor(404, WaiterState.RETRY)) .withDefaultPollingStrategy(new PollingStrategy(new MaxAttemptsRetryStrategy(40), new FixedDelayStrategy(1))) .withExecutorService(executorService).build(); }
/** * Builds a AppExists waiter by using custom parameters waiterParameters and other parameters defined in the waiters * specification, and then polls until it determines whether the resource entered the desired state or not, where * polling criteria is bound by either default polling strategy or custom polling strategy. */ public Waiter<DescribeAppsRequest> appExists() { return new WaiterBuilder<DescribeAppsRequest, DescribeAppsResult>().withSdkFunction(new DescribeAppsFunction(client)) .withAcceptors(new HttpSuccessStatusAcceptor(WaiterState.SUCCESS), new HttpFailureStatusAcceptor(400, WaiterState.FAILURE)) .withDefaultPollingStrategy(new PollingStrategy(new MaxAttemptsRetryStrategy(40), new FixedDelayStrategy(1))) .withExecutorService(executorService).build(); }
/** * Builds a BucketNotExists waiter by using custom parameters * waiterParameters and other parameters defined in the waiters * specification, and then polls until it determines whether the resource * entered the desired state or not, where polling criteria is bound by * either default polling strategy or custom polling strategy. */ public Waiter<HeadBucketRequest> bucketNotExists() { return new WaiterBuilder<HeadBucketRequest, HeadBucketResult>() .withSdkFunction(new HeadBucketFunction(client)) .withAcceptors( new HttpFailureStatusAcceptor<HeadBucketResult>(404, WaiterState.SUCCESS)) .withDefaultPollingStrategy( new PollingStrategy(new MaxAttemptsRetryStrategy(20), new FixedDelayStrategy(5))) .withExecutorService(executorService).build(); }
/** * Builds a BucketExists waiter by using custom parameters waiterParameters * and other parameters defined in the waiters specification, and then polls * until it determines whether the resource entered the desired state or * not, where polling criteria is bound by either default polling strategy * or custom polling strategy. */ public Waiter<HeadBucketRequest> bucketExists() { return new WaiterBuilder<HeadBucketRequest, HeadBucketResult>() .withSdkFunction(new HeadBucketFunction(client)) .withAcceptors( new HttpSuccessStatusAcceptor<HeadBucketResult>(WaiterState.SUCCESS), new HttpFailureStatusAcceptor<HeadBucketResult>(301, WaiterState.SUCCESS), new HttpFailureStatusAcceptor<HeadBucketResult>(403, WaiterState.SUCCESS), new HttpFailureStatusAcceptor<HeadBucketResult>(404, WaiterState.RETRY)) .withDefaultPollingStrategy( new PollingStrategy(new MaxAttemptsRetryStrategy(20), new FixedDelayStrategy(5))) .withExecutorService(executorService).build(); }
/** * Builds a ObjectNotExists waiter by using custom parameters * waiterParameters and other parameters defined in the waiters * specification, and then polls until it determines whether the resource * entered the desired state or not, where polling criteria is bound by * either default polling strategy or custom polling strategy. */ public Waiter<GetObjectMetadataRequest> objectNotExists() { return new WaiterBuilder<GetObjectMetadataRequest, ObjectMetadata>() .withSdkFunction(new HeadObjectFunction(client)) .withAcceptors( new HttpFailureStatusAcceptor<ObjectMetadata>(404, WaiterState.SUCCESS)) .withDefaultPollingStrategy( new PollingStrategy(new MaxAttemptsRetryStrategy(20), new FixedDelayStrategy(5))) .withExecutorService(executorService).build(); }
/** * Builds a ObjectExists waiter by using custom parameters waiterParameters * and other parameters defined in the waiters specification, and then polls * until it determines whether the resource entered the desired state or * not, where polling criteria is bound by either default polling strategy * or custom polling strategy. */ public Waiter<GetObjectMetadataRequest> objectExists() { return new WaiterBuilder<GetObjectMetadataRequest, ObjectMetadata>() .withSdkFunction(new HeadObjectFunction(client)) .withAcceptors( new HttpSuccessStatusAcceptor<ObjectMetadata>(WaiterState.SUCCESS), new HttpFailureStatusAcceptor<ObjectMetadata>(404, WaiterState.RETRY)) .withDefaultPollingStrategy( new PollingStrategy(new MaxAttemptsRetryStrategy(20), new FixedDelayStrategy(5))) .withExecutorService(executorService).build(); }
/** * Builds a AppExists waiter by using custom parameters waiterParameters and other parameters defined in the waiters * specification, and then polls until it determines whether the resource entered the desired state or not, where * polling criteria is bound by either default polling strategy or custom polling strategy. */ public Waiter<DescribeAppsRequest> appExists() { return new WaiterBuilder<DescribeAppsRequest, DescribeAppsResult>().withSdkFunction(new DescribeAppsFunction(client)) .withAcceptors(new HttpSuccessStatusAcceptor(WaiterState.SUCCESS), new HttpFailureStatusAcceptor(400, WaiterState.FAILURE)) .withDefaultPollingStrategy(new PollingStrategy(new MaxAttemptsRetryStrategy(40), new FixedDelayStrategy(1))) .withExecutorService(executorService).build(); }
/** * Builds a InstanceProfileExists waiter by using custom parameters waiterParameters and other parameters defined in * the waiters specification, and then polls until it determines whether the resource entered the desired state or * not, where polling criteria is bound by either default polling strategy or custom polling strategy. */ public Waiter<GetInstanceProfileRequest> instanceProfileExists() { return new WaiterBuilder<GetInstanceProfileRequest, GetInstanceProfileResult>().withSdkFunction(new GetInstanceProfileFunction(client)) .withAcceptors(new HttpSuccessStatusAcceptor(WaiterState.SUCCESS), new HttpFailureStatusAcceptor(404, WaiterState.RETRY)) .withDefaultPollingStrategy(new PollingStrategy(new MaxAttemptsRetryStrategy(40), new FixedDelayStrategy(1))) .withExecutorService(executorService).build(); }
/** * Builds a BucketNotExists waiter by using custom parameters * waiterParameters and other parameters defined in the waiters * specification, and then polls until it determines whether the resource * entered the desired state or not, where polling criteria is bound by * either default polling strategy or custom polling strategy. */ public Waiter bucketNotExists() { return new WaiterBuilder<HeadBucketRequest, HeadBucketResult>() .withSdkFunction(new HeadBucketFunction(client)) .withAcceptors( new HttpFailureStatusAcceptor(404, WaiterState.SUCCESS)) .withDefaultPollingStrategy( new PollingStrategy(new MaxAttemptsRetryStrategy(20), new FixedDelayStrategy(5))) .withExecutorService(executorService).build(); }
/** * Builds a ObjectNotExists waiter by using custom parameters * waiterParameters and other parameters defined in the waiters * specification, and then polls until it determines whether the resource * entered the desired state or not, where polling criteria is bound by * either default polling strategy or custom polling strategy. */ public Waiter objectNotExists() { return new WaiterBuilder<GetObjectMetadataRequest, ObjectMetadata>() .withSdkFunction(new HeadObjectFunction(client)) .withAcceptors( new HttpFailureStatusAcceptor(404, WaiterState.SUCCESS)) .withDefaultPollingStrategy( new PollingStrategy(new MaxAttemptsRetryStrategy(20), new FixedDelayStrategy(5))) .withExecutorService(executorService).build(); }
/** * Builds a BucketExists waiter by using custom parameters waiterParameters * and other parameters defined in the waiters specification, and then polls * until it determines whether the resource entered the desired state or * not, where polling criteria is bound by either default polling strategy * or custom polling strategy. */ public Waiter bucketExists() { return new WaiterBuilder<HeadBucketRequest, HeadBucketResult>() .withSdkFunction(new HeadBucketFunction(client)) .withAcceptors( new HttpSuccessStatusAcceptor(WaiterState.SUCCESS), new HttpFailureStatusAcceptor(301, WaiterState.SUCCESS), new HttpFailureStatusAcceptor(403, WaiterState.SUCCESS), new HttpFailureStatusAcceptor(404, WaiterState.RETRY)) .withDefaultPollingStrategy( new PollingStrategy(new MaxAttemptsRetryStrategy(20), new FixedDelayStrategy(5))) .withExecutorService(executorService).build(); }
/** * Builds a ObjectExists waiter by using custom parameters waiterParameters * and other parameters defined in the waiters specification, and then polls * until it determines whether the resource entered the desired state or * not, where polling criteria is bound by either default polling strategy * or custom polling strategy. */ public Waiter objectExists() { return new WaiterBuilder<GetObjectMetadataRequest, ObjectMetadata>() .withSdkFunction(new HeadObjectFunction(client)) .withAcceptors( new HttpSuccessStatusAcceptor(WaiterState.SUCCESS), new HttpFailureStatusAcceptor(404, WaiterState.RETRY)) .withDefaultPollingStrategy( new PollingStrategy(new MaxAttemptsRetryStrategy(20), new FixedDelayStrategy(5))) .withExecutorService(executorService).build(); }