This repository contains the following behaviors:
- UploadBlobRequestBehavior: used to upload the MediatR request to the specified blob container
- UploadBlobResponseBehavior: used to upload the MediatR response to the specified blob container
- DeleteBlobRequestBehavior: used to delete the MediatR request from the specified blob container
- DeleteBlobResponseBehavior: used to delete the MediatR response from the specified blob container
- DownloadBlobRequestBehavior: used to download the MediatR request from the specified blob container
- DownloadBlobResponseBehavior: used to download the MediatR response from the specified blob container
This repository contains the following processors:
- UploadBlobRequestProcessor: used to upload the MediatR request to the specified blob container
- UploadBlobResponseProcessor: used to upload the MediatR response to the specified blob container
- DeleteBlobRequestProcessor: used to delete the MediatR request from the specified blob container
- DeleteBlobResponseProcessor: used to delete the MediatR response from the specified blob container
- DownloadBlobRequestProcessor: used to download the MediatR request from the specified blob container
- DownloadBlobResponseProcessor: used to download the MediatR response from the specified blob container
Blob extensions depend on blob commands, which represent the actual extension implementation:
- UploadBlobCommand<TMessage>: used to upload a blob to the specified blob container
- DeleteBlobCommand<TMessage>: used to delete a blob from the specified blob container
- DownloadBlobCommand<TMessage>: used to download a blob from the specified blob container
Blob commands are controlled using BlobOptions<TMessage>.
The same option can have different requirements within the scope of different commands. Options requirements are as follows:
- Required: the value is required and an exception will be thrown if one is not supplied
- Default: the value is required and a default will be provided if one is not supplied
- Optional: the value is optional and will be used if one is supplied, ignored otherwise
- Ignored: the value is not used by the command and supplying one will have no effect
Options and their requirements are described in the following table:
Option | Description | Upload | Delete | Download |
---|---|---|---|---|
IsEnabled | true to enable execution of the extension, false to disable it |
Default 1 | Default 1 | Default 1 |
BlobClient | The blob client against which the operation is executed | Required | Required | Required |
BlobContent | The System.BinaryData containing the content to upload | Default 2 | Ignored | Ignored |
BlobHeaders | The standard HTTP header system properties to set for the blob | Default 2 | Ignored | Ignored |
Metadata | Custom metadata to set for the blob | Optional | Ignored | Ignored |
Downloaded | The event that is raised after the blob is downloaded | Ignored | Ignored | Optional |