Class AwsS3ReactiveBucketOperations

java.lang.Object
io.micronaut.objectstorage.aws.AwsS3ReactiveBucketOperations
All Implemented Interfaces:
ReactiveBucketOperations<software.amazon.awssdk.services.s3.model.HeadBucketResponse>

@EachBean(AwsS3Configuration.class) @Requires(beans=AwsS3Configuration.class) @Requires(beans=software.amazon.awssdk.services.s3.S3AsyncClient.class) public class AwsS3ReactiveBucketOperations extends Object implements ReactiveBucketOperations<software.amazon.awssdk.services.s3.model.HeadBucketResponse>
Reactive AWS bucket operations.
Since:
3.0.0
Author:
Álvaro Sánchez-Mariscal
  • Constructor Details

    • AwsS3ReactiveBucketOperations

      public AwsS3ReactiveBucketOperations(software.amazon.awssdk.services.s3.S3AsyncClient s3AsyncClient)
  • Method Details

    • create

      public @NonNull org.reactivestreams.Publisher<Void> create(@NonNull String name)
      Description copied from interface: ReactiveBucketOperations
      Create a new bucket/container with the given name.
      Specified by:
      create in interface ReactiveBucketOperations<software.amazon.awssdk.services.s3.model.HeadBucketResponse>
      Parameters:
      name - The bucket/container name.
      Returns:
      a completion-only publisher.
    • retrieve

      public @NonNull org.reactivestreams.Publisher<Optional<BucketEntry<software.amazon.awssdk.services.s3.model.HeadBucketResponse>>> retrieve(@NonNull String name)
      Description copied from interface: ReactiveBucketOperations
      Retrieve an existing bucket/container.
      Specified by:
      retrieve in interface ReactiveBucketOperations<software.amazon.awssdk.services.s3.model.HeadBucketResponse>
      Parameters:
      name - The bucket/container name.
      Returns:
      a publisher that emits the provider-native bucket/container data if it exists.
    • delete

      public @NonNull org.reactivestreams.Publisher<Void> delete(@NonNull String name)
      Description copied from interface: ReactiveBucketOperations
      Delete a bucket/container with the given name.
      Specified by:
      delete in interface ReactiveBucketOperations<software.amazon.awssdk.services.s3.model.HeadBucketResponse>
      Parameters:
      name - The bucket/container name.
      Returns:
      a completion-only publisher.
    • exists

      public @NonNull org.reactivestreams.Publisher<Boolean> exists(@NonNull String name)
      Description copied from interface: ReactiveBucketOperations
      Checks whether a bucket/container exists.
      Specified by:
      exists in interface ReactiveBucketOperations<software.amazon.awssdk.services.s3.model.HeadBucketResponse>
      Parameters:
      name - The bucket/container name.
      Returns:
      a publisher that emits true if the bucket/container exists.