This is a reproducer of a bug reported in FLINK-28591.
Run
mvn clean install exec:java -Dexec.mainClass=com.github.swtwsk.FlinkArrayRowBugJob
and cat
the file that got generated (named part-...
).
Although in the INSERT we tried to insert
array[
('Field1', 'Value1'),
('Field2', 'Value2')
]
in the JSON that got printed to the generated file we get duplicate of the last inserted row:
"bar": [
{"foo1":"Field2", "foo2":"Value2"},
{"foo1":"Field2", "foo2":"Value2"}
]