AzureBlobClient

class AzureBlobClient(serviceClient: BlobServiceClient, blobConfig: AzureBlobStorageClientConfiguration) : ObjectStorageClient<AzureBlob>

Constructors

Link copied to clipboard
constructor(serviceClient: BlobServiceClient, blobConfig: AzureBlobStorageClientConfiguration)

Functions

Link copied to clipboard
open suspend override fun delete(remoteObject: AzureBlob)

Delete a blob by remoteObject

open suspend override fun delete(key: String)

Delete a blob by key

open suspend override fun delete(keys: Set<String>)
Link copied to clipboard
open suspend override fun <U> get(key: String, block: (InputStream) -> U): U

Fetch the blob as an InputStream, pass it to block.

Link copied to clipboard
open suspend override fun getMetadata(key: String): Map<String, String>

Returns the user-defined metadata on the blob.

Link copied to clipboard
Link copied to clipboard
open suspend override fun list(prefix: String): Flow<AzureBlob>

List all blobs that start with prefix. We emit them as a Flow.

Link copied to clipboard
open suspend override fun move(remoteObject: AzureBlob, toKey: String): AzureBlob

Move is not a single operation in Azure; we have to do a copy + delete.

open suspend override fun move(key: String, toKey: String): AzureBlob
Link copied to clipboard
open suspend override fun put(key: String, bytes: ByteArray): AzureBlob

Upload a small byte array in a single shot.

Link copied to clipboard
open suspend override fun startStreamingUpload(key: String, metadata: Map<String, String>): StreamingUpload<AzureBlob>