Description:

Adds rows to HBase based on the contents of incoming JSON documents. Each FlowFile must contain a single UTF-8 encoded JSON document, and any FlowFiles where the root element is not a single document will be routed to failure. Each JSON field name and value will become a column qualifier and value of the HBase row. Any fields with a null value will be skipped, and fields with a complex value will be handled according to the Complex Field Strategy. The row id can be specified either directly on the processor through the Row Identifier property, or can be extracted from the JSON document by specifying the Row Identifier Field Name property. This processor will hold the contents of all FlowFiles for the given batch in memory at one time.

Tags:

hadoop, hbase, put, json

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
HBase Client ServiceController Service API:
HBaseClientService
Implementation:
HBase_1_1_2_ClientService
Specifies the Controller Service to use for accessing HBase.
Table NameThe name of the HBase Table to put data into
Supports Expression Language: true
Row IdentifierSpecifies the Row ID to use when inserting data into HBase
Supports Expression Language: true
Row Identifier Field NameSpecifies the name of a JSON element whose value should be used as the row id for the given JSON document.
Supports Expression Language: true
Column FamilyThe Column Family to use when inserting data into HBase
Supports Expression Language: true
Batch Size25The maximum number of FlowFiles to process in a single execution. The FlowFiles will be grouped by table, and a single Put per table will be performed.
Complex Field StrategyText
  • Fail Route entire FlowFile to failure if any elements contain complex values.
  • Warn Provide a warning and do not include field in row sent to HBase.
  • Ignore Silently ignore and do not include in row sent to HBase.
  • Text Use the string representation of the complex field as the value of the given column.
Indicates how to handle complex fields, i.e. fields that do not have a single text value.

Relationships:

NameDescription
failureA FlowFile is routed to this relationship if it cannot be sent to HBase
successA FlowFile is routed to this relationship after it has been successfully stored in HBase

Reads Attributes:

None specified.

Writes Attributes:

None specified.