PutHDFS

Description:

Write FlowFile data to Hadoop Distributed File System (HDFS)

Additional Details...

Tags:

hadoop, HDFS, put, copy, filesystem, restricted

Properties:

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 NiFi Expression Language.

NameDefault ValueAllowable ValuesDescription
Hadoop Configuration ResourcesA file or comma separated list of files which contains the Hadoop file system configuration. Without this, Hadoop will search the classpath for a 'core-site.xml' and 'hdfs-site.xml' file or will revert to a default configuration. To use swebhdfs, see 'Additional Details' section of PutHDFS's documentation.
Supports Expression Language: true
Kerberos PrincipalKerberos principal to authenticate as. Requires nifi.kerberos.krb5.file to be set in your nifi.properties
Supports Expression Language: true
Kerberos KeytabKerberos keytab associated with the principal. Requires nifi.kerberos.krb5.file to be set in your nifi.properties
Supports Expression Language: true
Kerberos Relogin Period4 hoursPeriod of time which should pass before attempting a kerberos relogin. This property has been deprecated, and has no effect on processing. Relogins now occur automatically.
Supports Expression Language: true
Additional Classpath ResourcesA comma-separated list of paths to files and/or directories that will be added to the classpath. When specifying a directory, all files with in the directory will be added to the classpath, but further sub-directories will not be included.
DirectoryThe parent HDFS directory to which files should be written. The directory will be created if it doesn't exist.
Supports Expression Language: true
Conflict Resolution Strategyfail
  • replace Replaces the existing file if any.
  • ignore Ignores the flow file and routes it to success.
  • fail Penalizes the flow file and routes it to failure.
  • append Appends to the existing file if any, creates a new file otherwise.
Indicates what should happen when a file with the same name already exists in the output directory
Block SizeSize of each block as written to HDFS. This overrides the Hadoop Configuration
IO Buffer SizeAmount of memory to use to buffer file contents during IO. This overrides the Hadoop Configuration
ReplicationNumber of times that HDFS will replicate each file. This overrides the Hadoop Configuration
Permissions umaskA umask represented as an octal number which determines the permissions of files written to HDFS. This overrides the Hadoop Configuration dfs.umaskmode
Remote OwnerChanges the owner of the HDFS file to this value after it is written. This only works if NiFi is running as a user that has HDFS super user privilege to change owner
Supports Expression Language: true
Remote GroupChanges the group of the HDFS file to this value after it is written. This only works if NiFi is running as a user that has HDFS super user privilege to change group
Supports Expression Language: true
Compression codecNONE
  • NONE No compression
  • DEFAULT Default ZLIB compression
  • BZIP BZIP compression
  • GZIP GZIP compression
  • LZ4 LZ4 compression
  • LZO LZO compression - it assumes LD_LIBRARY_PATH has been set and jar is available
  • SNAPPY Snappy compression
  • AUTOMATIC Will attempt to automatically detect the compression codec.
No Description Provided.

Relationships:

NameDescription
successFiles that have been successfully written to HDFS are transferred to this relationship
failureFiles that could not be written to HDFS for some reason are transferred to this relationship

Reads Attributes:

NameDescription
filenameThe name of the file written to HDFS comes from the value of this attribute.

Writes Attributes:

NameDescription
filenameThe name of the file written to HDFS is stored in this attribute.
absolute.hdfs.pathThe absolute path to the file on HDFS is stored in this attribute.

State management:

This component does not store state.

Restricted:

Provides operator the ability to write to any file that NiFi has access to in HDFS or the local filesystem.

Input requirement:

This component requires an incoming relationship.

See Also:

GetHDFS