Description:
This processor sends FlowFiles via FTP to an FTP server.
Properties:
In the list below, the names of required properties appear in bold.
Any other properties (not in bold) are considered optional. If a
property has a default value, it is indicated. If a property supports
the use of the NiFi Expression Language (or simply,
"expression language"), that is also indicated.
-
Hostname
- The fully qualified hostname or IP address of the remote
system.
- Default value: no default
- Supports expression language: true
-
Port
- The port that the remote system is listening on for file transfers.
- Default value: 21
- Supports expression language: false
-
Username
- The username for the user account.
- Default value: no default
- Supports expression language: false
-
Password
- The password for the user account.
- Default value: no default
- Supports expression language: false
-
Remote Path
- The path on the remote system to which files should be put. If not specified, uses the user's home directory. You may use expression language such as /aa/bb/${path}.
- Default value: no default
- Supports expression language: true
- Create Directory
- Specifies whether or not the remote directory should be created if it does not exist. Recommend setting to true when Remote Path uses expression language.
- Default value: false
- Supports expression language: false
-
Batch Size
- The maximum number of FlowFiles to send in a single connection.
- Default value: 500
- Supports expression language: false
-
Connection Timeout
- The amount of time to wait before timing out while creating a
connection.
- Default value: 30 sec
- Supports expression language: false
-
Data Timeout
- The amount of time to wait before timing out while transferring
data.
- Default value: 30 sec
- Supports expression language: false
-
Conflict Resolution
-
Specifies what action the processor should take if a conflict
prevents it from delivering the files. Valid options are:
- replace
- ignore
- rename
- reject
- fail
- NONE
- Default value: NONE
- Supports expression language: false
-
Dot Rename
- A Boolean value (true/false), indicating whether to prepend the
filename of the file with a dot (.) while the file is transferring
and remove the dot when the file is completely transferred.
- Default value: true
- Supports expression language: false
-
Temporary Filename
- If set, the filename of the sent file will be equal to the value specified during the transfer and
after successful completion will be renamed to the original filename. If this value is set, the Dot
Rename property is ignored.
- Default value: no default
- Supports expression language: true
-
Transfer Mode
-
The FTP transfer mode. Valid options are: Binary or ASCII.
- Default value: Binary
- Supports expression language: false
-
Connection Mode
-
The FTP connection mode. Valid options are: Active or Passive.
For most clients, this should be set to Passive.
- Default value: Passive
- Supports expression language: false
-
Reject Zero-Byte Files
- A Boolean value (true/false), indicating whether to reject
files that have zero bytes of content rather than transferring
them.
- Default value: true
- Supports expression language: false
- Last Modified Time
- The lastModifiedTime to assign to the file after transferring it. If not set, the lastModifiedTime
will not be changed. Format must be yyyy-MM-dd'T'HH:mm:ssZ. You may also use expression language such as
${file.lastModifiedTime}. If the value is invalid, the processor will not be invalid but will fail to
change lastModifiedTime of the file.
- Default value: no default
- Supports expression language: true
- Permissions
- The permissions to assign to the file after transferring it. Format must be either UNIX rwxrwxrwx
with a - in place of denied permissions (e.g. rw-r--r--) or an octal number (e.g. 644). If not set, the
permissions will not be changed. You may also use expression language such as ${file.permissions}. If
the value is invalid, the processor will not be invalid but will fail to change permissions of the file.
- Default value: no default
- Supports expression language: true
-
Use Compression
- A Boolean value (true/false), indicating whether to use ZLIB
compression when transferring files.
- Default value: false
- Supports expression language: false
Optional User-Defined Properties:
- pre.cmd.#
- Optional properties of this type can be added by the user and should be used for VERY
RARE cases only. You will know when you need to use it when the recipient specifies that you must
send FTP commands prior to the transfer. Otherwise, do not use it. You may add these optional properties
to send any commands to the FTP server before the file is actually transferred (before the put command).
This option is only available for the PutFTP processor, as only FTP has this functionality. This is
essentially the same as sending quote commands to an FTP server from the command line.
- NOTE: While this is the same as sending a quote command, it is very important that
you leave off the “quote” part of the command from the text value you enter in. For example, if you want
to mimic the command line ftp command quote stat you would give the text value of stat. You have the
option of sending a number of commands to the FTP server before the file is sent. If you have only one
command, then the name of the optional parameter will be pre.cmd.1. If you have a second command, then
the next optional parameter you give is pre.cmd.2, and so on. There is no limit to the number of pre
commands you can send. The commands will be sent in the order of their number, so pre.cmd.1 will be sent
first, pre.cmd.2 will be sent next, etc. This is true regardless of what order they are added to the
processor properties. The property names determine the order.
- NOTE: If the optional property name does not follow the pattern pre.cmd.integer
- then the command will not be sent. If a command is given which is not recognized by the server, then
that will be logged.
- Supports expression language: true. FlowFile attributes can be used in commands using the expression language
- post.cmd.#
- Optional properties of this type can be added by the user and should be used for VERY
RARE cases only. You will know when you need to use it when the recipient specifies that you must
send FTP commands after the transfer. Otherwise, do not use it. These are the same as the pre commands.
(See pre commands above) except that these commands are sent after the file transfer.
- Supports expression language: true. FlowFile attributes can be used in commands using the expression language
Relationships:
-
failure
- If something prevents a FlowFile from being transferred, then
it follows this relationship.
-
reject
- FlowFiles that were rejected by the destination system follow this relationship.
-
success
- If a FlowFile is successfully transferred, then it follows this
relationship.