Performs a listing of the files residing on an FTP server. For each file that is found on the remote server, a new FlowFile will be created with the filename attribute set to the name of the file on the remote server. This can then be used in conjunction with FetchFTP in order to fetch those files.


list, ftp, remote, ingest, source, input, files


In the list below, the names of required properties appear in bold. Any other properties (not in bold) are considered optional. The table also indicates any default values, and whether a property supports the Expression Language Guide, and whether a property is considered “sensitive”, meaning that its value will be encrypted. Before entering a value in a sensitive property, ensure that the file has an entry for the property nifi.sensitive.props.key.

Name Default Value Allowable Values Description
Hostname The fully qualified hostname or IP address of the remote system
Supports Expression Language: true
Port 21 The port to connect to on the remote host to fetch the data from
Supports Expression Language: true
Password Password for the user account
Sensitive Property: true
Supports Expression Language: true
Username Username
Supports Expression Language: true
Remote Path The path on the remote system from which to pull or push files
Supports Expression Language: true
Distributed Cache Service Controller Service API:
Specifies the Controller Service that should be used to maintain state about what has been pulled from the remote server so that if a new node begins pulling data, it won't duplicate all of the work that has been done. If not specified, the information will not be shared across the cluster. This property does not need to be set for standalone instances of NiFi but should be configured if NiFi is run within a cluster.
Search Recursively false *true
If true, will pull files from arbitrarily nested subdirectories; otherwise, will not traverse subdirectories
File Filter Regex Provides a Java Regular Expression for filtering Filenames; if a filter is supplied, only files whose names match that Regular Expression will be fetched
Path Filter Regex When Search Recursively is true, then only subdirectories whose path matches the given Regular Expression will be scanned
Path Filter Regex When Search Recursively is true, then only subdirectories whose path matches the given Regular Expression will be scanned
Ignore Dotted Files true * true
* false
If true, files whose names begin with a dot (".") will be ignored
Remote Poll Batch Size 5000 The value specifies how many file paths to find in a given directory on the remote system when doing a file listing. This value in general should not need to be modified but when polling against a remote system with a tremendous number of files this value can be critical. Setting this value too high can result very poor performance and setting it too low can cause the flow to be slower than normal.
Connection Timeout 30 sec Amount of time to wait before timing out while creating a connection
Data Timeout 30 sec When transferring a file between the local and remote system, this value specifies how long is allowed to elapse without any data being transferred between systems
Connection Mode Passive *Active *Passive The FTP Connection Mode
Transfer Mode Binary * Binary
The FTP Transfer Mode
Proxy type used for file transfers
Proxy Host The fully qualified hostname or IP address of the proxy server
Proxy Port The port of the proxy server
Http Proxy Username Http Proxy Username
Http Proxy Password Http Proxy Password
Sensitive Property: true


Name Description
success All FlowFiles that are received are routed to success

Reads Attributes:

None specified.

Writes Attributes:

Name Description The hostname of the FTP Server
ftp.remote.port The port that was connected to on the FTP Server
ftp.listing.user The username of the user that performed the FTP Listing
file.owner The numeric owner id of the source file The numeric group id of the source file
file.permissions The read/write/execute permissions of the source file
filename The name of the file on the SFTP Server
path The fully qualified name of the directory on the SFTP Server from which the file was pulled

State management:

Scope Description
CLUSTER After performing a listing of files, the timestamp of the newest file is stored. This allows the Processor to list only files that have been added or modified after this date the next time that the Processor is run. State is stored across the cluster so that this Processor can be run on Primary Node only and if a new Primary Node is selected, the new node will not duplicate the data that was listed by the previous Primary Node.

This component is not restricted.