I have a Datastream which contains some fields like event_id, timestamp, etc. which remains constant for many records in pipeline. I want to use those in filename while writing it back in ParquetFormat using StreamingFileSink. We can use suffix and prefix if we are using constants. However, I wanted help in extracting the value from record which can be used to generate the filename.
Filename Pattern _ <Event_id>--.parquet
OutputFileConfig config = OutputFileConfig
.builder()
.withPartPrefix("prefix")
.withPartSuffix(".ext")
.build();
I am planning to use this, but want help in Extracting "prefix" from the records itself.
Any thoughts on this would really be helpful. Thanks in advance :)