Trigger
type: "io.kestra.plugin.azure.storage.adls.Trigger"
Run a flow as soon as files are uploaded to Azure Data Lake Storage
This trigger will poll the specified Azure Data Lake Storage bucket every interval
. Using the from
and regExp
properties, you can define which files arrival will trigger the flow. Under the hood, we use the Azure Data Lake Storage API to list the files in a specified location and download them to the internal storage and process them with the declared action
. You can use the action
property to move or delete the files from the container after processing to avoid the trigger to be fired again for the same files during the next polling interval.
Examples
Run a flow if one or more files arrived in the specified Azure Data Lake Storage bucket location. Then, process all files in a for-loop either sequentially or concurrently, depending on the
concurrencyLimit
property.
id: react_to_files
namespace: company.team
tasks:
- id: each
type: io.kestra.plugin.core.flow.ForEach
concurrencyLimit: 1
values: "{{ trigger.files | jq('.[].uri') }}"
tasks:
- id: return
type: io.kestra.plugin.core.debug.Return
format: "{{ taskrun.value }}"
triggers:
- id: watch
type: io.kestra.plugin.azure.storage.adls.Trigger
interval: PT5M
endpoint: "https://yourblob.blob.core.windows.net"
connectionString: "DefaultEndpointsProtocol=...=="
fileSystem: myFileSystem
directoryPath: yourDirectory/subdirectory
Properties
action
- Type: string
- Dynamic: ✔️
- Required: ✔️
- Default:
NONE
- Possible Values:
MOVE
DELETE
NONE
The action to perform on the retrieved files. If using NONE
, make sure to handle the files inside your flow to avoid infinite triggering.
conditions
- Type: array
- SubType: Condition
- Dynamic: ❌
- Required: ❌
List of conditions in order to limit the flow trigger.
connectionString
- Type: string
- Dynamic: ✔️
- Required: ❌
Connection string of the Storage Account.
directoryPath
- Type: string
- Dynamic: ❓
- Required: ❌
endpoint
- Type: string
- Dynamic: ✔️
- Required: ❌
The blob service endpoint.
fileSystem
- Type: string
- Dynamic: ❓
- Required: ❌
interval
- Type: string
- Dynamic: ❌
- Required: ❌
- Default:
60.000000000
- Format:
duration
Interval between polling.
The interval between 2 different polls of schedule, this can avoid to overload the remote system with too many calls. For most of the triggers that depend on external systems, a minimal interval must be at least PT30S. See ISO_8601 Durations for more information of available interval values.
moveTo
- Type: Trigger-DestinationObject
- Dynamic: ✔️
- Required: ❌
The destination container and key.
sasToken
- Type: string
- Dynamic: ✔️
- Required: ❌
The SAS token to use for authenticating requests.
This string should only be the query parameters (with or without a leading '?') and not a full URL.
sharedKeyAccountAccessKey
- Type: string
- Dynamic: ✔️
- Required: ❌
Shared Key access key for authenticating requests.
sharedKeyAccountName
- Type: string
- Dynamic: ✔️
- Required: ❌
Shared Key account name for authenticating requests.
stopAfter
- Type: array
- SubType: string
- Dynamic: ❌
- Required: ❌
List of execution states after which a trigger should be stopped (a.k.a. disabled).
Outputs
files
- Type: array
- SubType: AdlsFile
- Required: ❌
The list of file.
Definitions
io.kestra.plugin.azure.storage.adls.Trigger-DestinationObject
Properties
directoryPath
- Type: string
- Dynamic: ✔️
- Required: ✔️
The full destination directory path on the file system.
fileSystem
- Type: string
- Dynamic: ✔️
- Required: ✔️
The destination file system.
com.azure.storage.file.datalake.models.ArchiveStatus
io.kestra.plugin.azure.storage.adls.models.AdlsFile
Properties
accessControlList
- Type: array
- SubType: string
- Dynamic: ❓
- Required: ❓
archiveStatus
- Type: ArchiveStatus
- Dynamic: ❓
- Required: ❓
archiveTier
- Type: AccessTier
- Dynamic: ❓
- Required: ❓
contentEncoding
- Type: string
- Dynamic: ❓
- Required: ❓
contentLanguage
- Type: string
- Dynamic: ❓
- Required: ❓
contentMd5
- Type: string
- Dynamic: ❓
- Required: ❓
contentType
- Type: string
- Dynamic: ❓
- Required: ❓
creationTime
- Type: string
- Dynamic: ❓
- Required: ❓
- Format:
date-time
eTag
- Type: string
- Dynamic: ❓
- Required: ❓
fileName
- Type: string
- Dynamic: ❓
- Required: ❓
fileSystem
- Type: string
- Dynamic: ❓
- Required: ❓
group
- Type: string
- Dynamic: ❓
- Required: ❓
isDirectory
- Type: boolean
- Dynamic: ❓
- Required: ❓
lastModifed
- Type: string
- Dynamic: ❓
- Required: ❓
- Format:
date-time
leaseDuration
- Type: string
- Dynamic: ❓
- Required: ❓
- Possible Values:
INFINITE
FIXED
leaseState
- Type: string
- Dynamic: ❓
- Required: ❓
- Possible Values:
AVAILABLE
LEASED
EXPIRED
BREAKING
BROKEN
leaseStatus
- Type: string
- Dynamic: ❓
- Required: ❓
- Possible Values:
LOCKED
UNLOCKED
name
- Type: string
- Dynamic: ❓
- Required: ❓
owner
- Type: string
- Dynamic: ❓
- Required: ❓
permissions
- Type: string
- Dynamic: ❓
- Required: ❓
size
- Type: integer
- Dynamic: ❓
- Required: ❓
uri
- Type: string
- Dynamic: ❓
- Required: ❓
- Format:
uri
com.azure.storage.file.datalake.models.AccessTier
Was this page helpful?