Azure Storage Blob Service
Store and retrieve blobs from Azure Storage Blob Service.
What’s inside
-
Azure Storage Blob Service component, URI syntax:
azure-storage-blob:accountName/containerName
Please refer to the above links for usage and configuration details.
Maven coordinates
<dependency>
<groupId>org.apache.camel.springboot</groupId>
<artifactId>camel-azure-storage-blob-starter</artifactId>
</dependency> Spring Boot Auto-Configuration
The starter supports 52 options, which are listed below.
| Name | Description | Default | Type |
|---|---|---|---|
camel.component.azure-storage-blob.access-key | Access key for the associated azure account name to be used for authentication with azure blob services | String | |
camel.component.azure-storage-blob.autowired-enabled | Whether autowiring is enabled. This is used for automatic autowiring options (the option must be marked as autowired) by looking up in the registry to find if there is a single instance of matching type, which then gets configured on the component. This can be used for automatic configuring JDBC data sources, JMS connection factories, AWS Clients, etc. | true | Boolean |
camel.component.azure-storage-blob.azure-client-id | Azure Client ID for authentication with Azure Identity | String | |
camel.component.azure-storage-blob.azure-client-secret | Azure Client Secret for authentication with Azure Identity | String | |
camel.component.azure-storage-blob.azure-tenant-id | Azure Tenant ID for authentication with Azure Identity | String | |
camel.component.azure-storage-blob.blob-name | The blob name, to consume specific blob from a container. However, on producer it is only required for the operations on the blob level | String | |
camel.component.azure-storage-blob.blob-offset | Set the blob offset for the upload or download operations, default is 0 | 0 | Long |
camel.component.azure-storage-blob.blob-sequence-number | A user-controlled value that you can use to track requests. The value of the sequence number must be between 0 and 263 - 1.The default value is 0. | 0 | Long |
camel.component.azure-storage-blob.blob-type | The blob type in order to initiate the appropriate settings for each blob type | blockblob | BlobType |
camel.component.azure-storage-blob.block-list-type | Specifies which type of blocks to return. | committed | BlockListType |
camel.component.azure-storage-blob.block-size | The block size in bytes to use for chunked uploads with uploadBlockBlobChunked operation. Default is 4MB (4194304). Maximum is 4000MB. Must be greater than 0. | Long | |
camel.component.azure-storage-blob.bridge-error-handler | Allows for bridging the consumer to the Camel routing Error Handler, which mean any exceptions (if possible) occurred while the Camel consumer is trying to pickup incoming messages, or the likes, will now be processed as a message and handled by the routing Error Handler. Important: This is only possible if the 3rd party component allows Camel to be alerted if an exception was thrown. Some components handle this internally only, and therefore bridgeErrorHandler is not possible. In other situations we may improve the Camel component to hook into the 3rd party component and make this possible for future releases. By default the consumer will use the org.apache.camel.spi.ExceptionHandler to deal with exceptions, that will be logged at WARN or ERROR level and ignored. | false | Boolean |
camel.component.azure-storage-blob.change-feed-context | When using getChangeFeed producer operation, this gives additional context that is passed through the Http pipeline during the service call. The option is a com.azure.core.util.Context type. | Context | |
camel.component.azure-storage-blob.change-feed-end-time | When using getChangeFeed producer operation, this filters the results to return events approximately before the end time. Note: A few events belonging to the next hour can also be returned. A few events belonging to this hour can be missing; to ensure all events from the hour are returned, round the end time up by an hour. | OffsetDateTime | |
camel.component.azure-storage-blob.change-feed-start-time | When using getChangeFeed producer operation, this filters the results to return events approximately after the start time. Note: A few events belonging to the previous hour can also be returned. A few events belonging to this hour can be missing; to ensure all events from the hour are returned, round the start time down by an hour. | OffsetDateTime | |
camel.component.azure-storage-blob.close-stream-after-read | Close the stream after read or keep it open, default is true | true | Boolean |
camel.component.azure-storage-blob.close-stream-after-write | Close the stream after write or keep it open, default is true | true | Boolean |
camel.component.azure-storage-blob.commit-block-list-later | When is set to true, the staged blocks will not be committed directly. | true | Boolean |
camel.component.azure-storage-blob.configuration | The component configurations. The option is a org.apache.camel.component.azure.storage.blob.BlobConfiguration type. | BlobConfiguration | |
camel.component.azure-storage-blob.create-append-blob | When is set to true, the append blocks will be created when committing append blocks. | true | Boolean |
camel.component.azure-storage-blob.create-page-blob | When is set to true, the page blob will be created when uploading page blob. | true | Boolean |
camel.component.azure-storage-blob.credential-type | Determines the credential strategy to adopt | azure-identity | CredentialType |
camel.component.azure-storage-blob.credentials | StorageSharedKeyCredential can be injected to create the azure client, this holds the important authentication information. The option is a com.azure.storage.common.StorageSharedKeyCredential type. | StorageSharedKeyCredential | |
camel.component.azure-storage-blob.data-count | How many bytes to include in the range. Must be greater than or equal to 0 if specified. | Long | |
camel.component.azure-storage-blob.delete-after-read | Delete blobs from Azure after they have been retrieved. The delete is only performed if the Exchange is committed. If a rollback occurs, the blob is not deleted. If this option is false, then the same blobs will be retrieved over and over again in the polls. Therefore, you need to use the Idempotent Consumer EIP in the route to filter out duplicates. You can filter using the BlobConstants#BLOB_NAME header, or only the blob name. | false | Boolean |
camel.component.azure-storage-blob.destination-blob-prefix | Define the destination blob prefix to use when a blob must be moved, and moveAfterRead is set to true. | String | |
camel.component.azure-storage-blob.destination-blob-suffix | Define the destination blob suffix to use when a blob must be moved, and moveAfterRead is set to true. | String | |
camel.component.azure-storage-blob.destination-container | Define the destination container where a blob must be moved when moveAfterRead is set to true. | String | |
camel.component.azure-storage-blob.download-link-expiration | Override the default expiration (millis) of URL download link. | Long | |
camel.component.azure-storage-blob.enabled | Whether to enable auto configuration of the azure-storage-blob component. This is enabled by default. | Boolean | |
camel.component.azure-storage-blob.file-dir | The file directory where the downloaded blobs will be saved to, this can be used in both, producer and consumer | String | |
camel.component.azure-storage-blob.health-check-consumer-enabled | Used for enabling or disabling all consumer based health checks from this component | true | Boolean |
camel.component.azure-storage-blob.health-check-producer-enabled | Used for enabling or disabling all producer based health checks from this component. Notice: Camel has by default disabled all producer based health-checks. You can turn on producer checks globally by setting camel.health.producersEnabled=true. | true | Boolean |
camel.component.azure-storage-blob.lazy-start-producer | Whether the producer should be started lazy (on the first message). By starting lazy you can use this to allow CamelContext and routes to startup in situations where a producer may otherwise fail during starting and cause the route to fail being started. By deferring this startup to be lazy then the startup failure can be handled during routing messages via Camel’s routing error handlers. Beware that when the first message is processed then creating and starting the producer may take a little time and prolong the total processing time of the processing. | false | Boolean |
camel.component.azure-storage-blob.lease-blob | Sets whether a lease should be acquired when accessing the blob. When set to true, the component will acquire a lease before performing blob operations that require exclusive access. | false | Boolean |
camel.component.azure-storage-blob.lease-duration-in-seconds | Sets the lease duration in seconds. Use -1 for infinite or a value between 15 and 60 for fixed leases. | 60 | Integer |
camel.component.azure-storage-blob.max-concurrency | The maximum number of parallel requests to use during upload with uploadBlockBlobChunked operation. Default is determined by the Azure SDK based on available processors. | Integer | |
camel.component.azure-storage-blob.max-results-per-page | Specifies the maximum number of blobs to return, including all BlobPrefix elements. If the request does not specify maxResultsPerPage or specifies a value greater than 5,000, the server will return up to 5,000 items. | Integer | |
camel.component.azure-storage-blob.max-retry-requests | Specifies the maximum number of additional HTTP Get requests that will be made while reading the data from a response body. | 0 | Integer |
camel.component.azure-storage-blob.max-single-upload-size | The maximum size in bytes for a single upload request with uploadBlockBlobChunked operation. Files smaller than this will be uploaded in a single request. Files larger will use chunked upload with blocks of size blockSize. Default is 256MB. | Long | |
camel.component.azure-storage-blob.move-after-read | Move blobs from the container to a different container after they have been retrieved. To accomplish the operation, the destinationContainer option must be set. The copy blob operation is only performed if the Exchange is committed. If a rollback occurs, the blob is not moved. | false | Boolean |
camel.component.azure-storage-blob.operation | The blob operation that can be used with this component on the producer | listblobcontainers | BlobOperationsDefinition |
camel.component.azure-storage-blob.page-blob-size | Specifies the maximum size for the page blob, up to 8 TB. The page blob size must be aligned to a 512-byte boundary. | 512 | Long |
camel.component.azure-storage-blob.prefix | Filters the results to return only blobs whose names begin with the specified prefix. May be null to return all blobs. | String | |
camel.component.azure-storage-blob.regex | Filters the results to return only blobs whose names match the specified regular expression. May be null to return all if both prefix and regex are set, regex takes the priority and prefix is ignored. | String | |
camel.component.azure-storage-blob.remove-prefix-on-move | Remove the contents of the prefix configuration string from the new blob name before moving. For example, if prefix is set to 'notify/' and the destinationBlobPrefix is set to 'archive/', a blob with a name of 'notify/example.txt' will be moved to 'archive/example.txt', rather than the default behavior where the new name is 'archive/notify/example.txt'. Only applicable when moveAfterRead is true. | false | Boolean |
camel.component.azure-storage-blob.sas-token | In case of usage of Shared Access Signature we’ll need to set a SAS Token | String | |
camel.component.azure-storage-blob.service-client | Client to a storage account. This client does not hold any state about a particular storage account but is instead a convenient way of sending off appropriate requests to the resource on the service. It may also be used to construct URLs to blobs and containers. This client contains operations on a service account. Operations on a container are available on BlobContainerClient through BlobServiceClient#getBlobContainerClient(String), and operations on a blob are available on BlobClient through BlobContainerClient#getBlobClient(String). The option is a com.azure.storage.blob.BlobServiceClient type. | BlobServiceClient | |
camel.component.azure-storage-blob.snapshot-id | The snapshot identifier used to target a specific blob snapshot on read operations (getBlob, downloadBlobToFile, downloadLink). When set, the read targets the snapshot scoped client instead of the live blob. Can also be provided per-exchange via the CamelAzureStorageBlobSnapshotId header. | String | |
camel.component.azure-storage-blob.source-blob-access-key | Source Blob Access Key: for copyblob operation, sadly, we need to have an accessKey for the source blob we want to copy Passing an accessKey as header, it’s unsafe so we could set as key. | String | |
camel.component.azure-storage-blob.timeout | An optional timeout value beyond which a RuntimeException will be raised. | Duration | |
camel.component.azure-storage-blob.version-id | The blob version identifier used to target a specific blob version on read operations (getBlob, downloadBlobToFile, downloadLink). Requires blob versioning to be enabled on the storage account. When set, the read targets the version scoped client instead of the live blob. Can also be provided per-exchange via the CamelAzureStorageBlobVersionId header. | String |