Integration / Apache NiFi Interview Questions
What is the Record-based processing model in NiFi and why is it preferred?
NiFi's record-based processing model treats FlowFile content as a structured stream of records rather than an opaque blob. A record is one logical row — one JSON object, one CSV line, one Avro record, one database row. Record-aware processors operate on individual records within a FlowFile, enabling format-agnostic transformations.
The model relies on three Controller Service types:
RecordReader: Parses the FlowFile content and produces a stream of records. Implementations include JsonTreeReader, CSVReader, AvroReader, ParquetReader, XMLReader, and GrokReader (for unstructured log parsing).
RecordWriter: Serializes records back to bytes. Implementations include JsonRecordSetWriter, CSVRecordSetWriter, AvroRecordSetWriter, and ParquetRecordSetWriter.
Schema Registry: Optionally provides Avro schemas that readers and writers use to interpret and validate records. NiFi includes an embedded AvroSchemaRegistry.
Key record-aware processors: ConvertRecord (format conversion), QueryRecord (apply SQL SELECT against FlowFile records using Apache Calcite), LookupRecord (enrich records from external sources), UpdateRecord, and PartitionRecord (split into one FlowFile per distinct field value).
The key advantage is format independence: changing from JSON to CSV input requires only swapping the RecordReader Controller Service — no processor logic changes. It also avoids materializing entire FlowFiles into memory by streaming records one at a time.
Invest now in Acorns!!! 🚀
Join Acorns and get your $5 bonus!
Acorns is a micro-investing app that automatically invests your "spare change" from daily purchases into diversified, expert-built portfolios of ETFs. It is designed for beginners, allowing you to start investing with as little as $5. The service automates saving and investing. Disclosure: I may receive a referral bonus.
Invest now!!! Get Free equity stock (US, UK only)!
Use Robinhood app to invest in stocks. It is safe and secure. Use the Referral link to claim your free stock when you sign up!.
The Robinhood app makes it easy to trade stocks, crypto and more.
Webull! Receive free stock by signing up using the link: Webull signup.
More Related questions...
