Azure Storage Data Lake Service
Sends and receives files to/from Azure Data Lake Storage.
What’s inside
-
Azure Storage Data Lake Service component, URI syntax:
azure-storage-datalake:accountName/fileSystemName
Please refer to the above links for usage and configuration details.
Maven coordinates
<dependency>
<groupId>org.apache.camel.springboot</groupId>
<artifactId>camel-azure-storage-datalake-starter</artifactId>
</dependency> Spring Boot Auto-Configuration
The starter supports 40 options, which are listed below.
| Name | Description | Default | Type |
|---|---|---|---|
camel.component.azure-storage-datalake.account-key | The account key of the storage account, which authenticates the client together with accountName when credentialType is SHARED_KEY_CREDENTIAL. Setting it does not change credentialType, which must be set. Not used when sharedKeyCredential or serviceClient is set. | String | |
camel.component.azure-storage-datalake.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-datalake.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-datalake.client-id | The client ID of the Microsoft Entra ID application, which authenticates the client together with clientSecret and tenantId when credentialType is CLIENT_SECRET. Not used when clientSecretCredential or serviceClient is set. | String | |
camel.component.azure-storage-datalake.client-secret | The client secret of the Microsoft Entra ID application, which authenticates the client together with clientId and tenantId when credentialType is CLIENT_SECRET. Not used when clientSecretCredential or serviceClient is set. | String | |
camel.component.azure-storage-datalake.client-secret-credential | To use a com.azure.identity.ClientSecretCredential, which authenticates with a client secret of a Microsoft Entra ID application, when credentialType is CLIENT_SECRET. When it is set, the clientId, clientSecret and tenantId options are not used. Not used when serviceClient is set. The option is a com.azure.identity.ClientSecretCredential type. | ClientSecretCredential | |
camel.component.azure-storage-datalake.close | Whether the file changed event that flushToFile raises, when Azure Storage events are enabled, tells that the file is complete (true) or that it was modified (false). The CamelAzureStorageDataLakeClose header replaces this option. | false | Boolean |
camel.component.azure-storage-datalake.close-stream-after-read | Whether getFile closes the OutputStream body that it writes the file into, once the download is done. If false, the route must close it. | true | Boolean |
camel.component.azure-storage-datalake.configuration | The configuration that each endpoint of this component starts from, before the options of the endpoint are applied. The option is a org.apache.camel.component.azure.storage.datalake.DataLakeConfiguration type. | DataLakeConfiguration | |
camel.component.azure-storage-datalake.credential-type | How the client authenticates. CLIENT_SECRET uses clientSecretCredential, or clientId, clientSecret and tenantId. SHARED_KEY_CREDENTIAL uses sharedKeyCredential, or accountName and accountKey. AZURE_IDENTITY uses the default Azure credential, which tries environment variables, workload identity, managed identity, the Azure CLI and other sources, in the tenant of tenantId if set. AZURE_SAS uses sasCredential or sasSignature. SERVICE_CLIENT_INSTANCE uses serviceClient. If not set, it follows the credential object that is set: sharedKeyCredential, sasCredential or clientSecretCredential, in this order, and otherwise CLIENT_SECRET. Not used when serviceClient is set. | client-secret | CredentialType |
camel.component.azure-storage-datalake.data-count | The number of bytes to read from fileOffset, for the consumer, getFile and downloadToFile. Only used when fileOffset is set too; otherwise the whole file is read. The CamelAzureStorageDataLakeFileRange header replaces both options for the producer. | Long | |
camel.component.azure-storage-datalake.delete-after-read | Delete a file from the file system once its exchange has completed. When the exchange fails, the file is not deleted, so it is consumed again at the next poll. | false | Boolean |
camel.component.azure-storage-datalake.directory-name | The path of a directory in the file system, which createFile creates the file in and deleteDirectory deletes. The CamelAzureStorageDataLakeDirectoryName header replaces this option. The other operations and the consumer do not use it: for them, fileName is the whole path of the file. | String | |
camel.component.azure-storage-datalake.download-link-expiration | How long, in milliseconds, the link that downloadLink generates stays valid. It is rounded down to whole seconds. If not set, the link is valid for 1 hour. The link holds a service SAS with read permission, which the client can only sign with a shared key (SHARED_KEY_CREDENTIAL). The CamelAzureStorageDataLakeDownloadLinkExpiration header replaces this option. | Long | |
camel.component.azure-storage-datalake.enabled | Whether to enable auto configuration of the azure-storage-datalake component. This is enabled by default. | Boolean | |
camel.component.azure-storage-datalake.expression | The query expression of openQueryInputStream, in the SQL-like syntax of query acceleration, for example SELECT * from BlobStorage. Required for openQueryInputStream unless the CamelAzureStorageDataLakeQueryOptions header is set. The CamelAzureStorageDataLakeExpression header replaces this option. | String | |
camel.component.azure-storage-datalake.file-dir | The local directory to download files into. When it is set, the consumer downloads each file into this directory, and the body is that java.io.File instead of a stream, with the properties of the file in headers. downloadToFile requires it, and the CamelAzureStorageDataLakeFileDir header replaces it. The local file is named after the last segment of the path of the file, and a local file that already exists is replaced. | String | |
camel.component.azure-storage-datalake.file-name | The path of the file in the file system, such as dir/file.txt. With it, the consumer reads only this file, at each poll, and without it the consumer reads the files that the path option lists. The producer requires it for the operations on a file, and for createFile it is the name of the file to create in directoryName. The CamelAzureStorageDataLakeFileName header replaces this option for the producer. | String | |
camel.component.azure-storage-datalake.file-offset | A position in bytes in the file. For appendToFile, the position at which the appended data starts; if not set, the current committed length of the file, and the CamelAzureStorageDataLakeFileOffset header replaces it. Together with dataCount, the position of the first byte to read, for the consumer, getFile and downloadToFile. | Long | |
camel.component.azure-storage-datalake.health-check-consumer-enabled | Used for enabling or disabling all consumer based health checks from this component | true | Boolean |
camel.component.azure-storage-datalake.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-datalake.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-datalake.max-results | The number of paths per page, at most 5000, that the service returns when the consumer or listPaths list paths. The consumer and listPaths still get the paths of all pages. If not set, the value is 1000. The CamelAzureStorageDataLakeMaxResults header replaces this option for the producer. | Integer | |
camel.component.azure-storage-datalake.max-retry-requests | How many more times the Azure SDK requests the rest of the file, from where it stopped, when reading the content of a download fails: for getFile with an OutputStream body, downloadToFile and the consumer with fileDir. The default 0 turns these retries off, rather than the 5 retries of the SDK. Must be 0 or more. | Integer | |
camel.component.azure-storage-datalake.open-options | The java.nio.file.OpenOption set that opens or creates the local file that downloadToFile and the consumer with fileDir write into. If not set, CREATE_NEW, READ and WRITE. The CamelAzureStorageDataLakeOpenOptions header replaces this option for the producer. | OpenOption> | |
camel.component.azure-storage-datalake.operation | The operation that the producer performs. The CamelAzureStorageDataLakeOperation header replaces this option. | listfilesystem | DataLakeOperationsDefinition |
camel.component.azure-storage-datalake.path | The path of the directory whose paths the consumer and listPaths list, relative to the root of the file system. The listing fails if the path does not exist. For uploadFromFile, it is instead the path of the local file to upload. The CamelAzureStorageDataLakePath header replaces this option for the producer. | String | |
camel.component.azure-storage-datalake.permission | The POSIX access permissions of the file that createFile and upload create, for the owner, the owning group and others, in symbolic (rwxr-x---) or 4-digit octal (0750) notation. Only for an account with a hierarchical namespace. The CamelAzureStorageDataLakePermission header replaces this option. | String | |
camel.component.azure-storage-datalake.position | The length in bytes of the file once flushToFile has committed the appended data, including the data committed before. If not set, the current committed length of the file, which commits no newly appended data. The CamelAzureStorageDataLakePosition header replaces this option. | Long | |
camel.component.azure-storage-datalake.recursive | Whether the consumer and listPaths also list the paths in the subdirectories of path, at all levels. If false, they list only the direct children of path. For deleteDirectory, whether to delete the directory with all its content: if false, the directory must be empty. The CamelAzureStorageDataLakeRecursive header replaces this option for the producer. | false | Boolean |
camel.component.azure-storage-datalake.regex | A Java regular expression that the whole path of a listed file or directory must match, for example .*\.csv, for the consumer to read it or for listPaths to return it. The paths are filtered after they are listed. The CamelAzureStorageDataLakeRegex header replaces this option for the producer. | String | |
camel.component.azure-storage-datalake.retain-uncommited-data | Whether flushToFile keeps the appended data beyond position that it does not commit. If false, the service deletes that uncommitted data. The CamelAzureStorageDataLakeRetainCommitedData header replaces this option. | false | Boolean |
camel.component.azure-storage-datalake.sas-credential | To use a com.azure.core.credential.AzureSasCredential, which holds a shared access signature (SAS) token, when credentialType is AZURE_SAS. When it is set and credentialType is not, credentialType becomes AZURE_SAS, unless sharedKeyCredential is set. When it is set, sasSignature is not used. Not used when serviceClient is set. The option is a com.azure.core.credential.AzureSasCredential type. | AzureSasCredential | |
camel.component.azure-storage-datalake.sas-signature | The shared access signature (SAS) token that authenticates the client when credentialType is AZURE_SAS. Setting it does not change credentialType, which must be set. Not used when sasCredential or serviceClient is set. | String | |
camel.component.azure-storage-datalake.service-client | To use a custom com.azure.storage.file.datalake.DataLakeServiceClient for the requests to the Data Lake Storage service. When this option is set or autowired, the client brings the address and the authentication, and credentialType and the other credential options are not used. The option is a com.azure.storage.file.datalake.DataLakeServiceClient type. | DataLakeServiceClient | |
camel.component.azure-storage-datalake.shared-key-credential | To use a com.azure.storage.common.StorageSharedKeyCredential, which holds the account name and an account key of the storage account, when credentialType is SHARED_KEY_CREDENTIAL. When it is set and credentialType is not, credentialType becomes SHARED_KEY_CREDENTIAL. Its account name gives the address of the service, and accountKey is not used. Not used when serviceClient is set. The option is a com.azure.storage.common.StorageSharedKeyCredential type. | StorageSharedKeyCredential | |
camel.component.azure-storage-datalake.tenant-id | The ID of the Microsoft Entra ID tenant: of the application of clientId and clientSecret when credentialType is CLIENT_SECRET, and the tenant that the default Azure credential authenticates in when credentialType is AZURE_IDENTITY. For CLIENT_SECRET, not used when clientSecretCredential is set. Not used when serviceClient is set. | String | |
camel.component.azure-storage-datalake.timeout | The time, for example PT30S or 30s, within which each call to the service must complete, or it fails with an exception. If not set, only the timeouts of the HTTP client apply. For listPaths, listFileSystem and the listing of the consumer, it applies to each page of the listing. It does not apply to reading a file as a stream (getFile without an OutputStream body, and the consumer without fileDir), to openQueryInputStream and to the delete of deleteAfterRead. The CamelAzureStorageDataLakeTimeout header replaces this option for the producer. | Duration | |
camel.component.azure-storage-datalake.umask | The umask, in 4-digit octal notation such as 0027, that restricts the permissions of the file that createFile and upload create. Only for an account with a hierarchical namespace. The CamelAzureStorageDataLakeUmask header replaces this option. | String | |
camel.component.azure-storage-datalake.user-principal-name-returned | Whether listPaths returns the owner and group of each path as user principal names instead of Microsoft Entra ID object IDs. Only for an account with a hierarchical namespace. The CamelAzureStorageDataLakeUserPrincipalNameReturned header replaces this option. | false | Boolean |