Add new APIs to support read/write file operations for ndjson format #5099
Labels
module/io
Status/Draft
In circulation by the author for initial review and consensus-building
Type/NewFeature
Type/Proposal
Description:
The current IO file APIs support read/write JSON files which require complete json object to pass for writing and returns complete object when reading. With ndjson format, which stands for "Newline Delimited JSON,". can store multiple JSON objects in a single file, with each JSON object separated by a newline character. like,
The key features of NDJSON are:
This format is useful specially for storing log data. Each log entry can be represented as a JSON object, and the entries are separated by newlines.
Having new File IO APIs for reading/writing ndjson file is useful for dumping log records to the file and read them later as stream.
Proposed APIs
Related Issues (optional):
Discord discussion: https://discord.com/channels/957996897782616114/1164531854041427980/1164531854041427980
Resources: https://docs.mulesoft.com/dataweave/2.5/dataweave-formats-ndjson
https://github.com/ndjson/ndjson-spec
The text was updated successfully, but these errors were encountered: