amogh-jahagirdar commented on code in PR #6660:
URL: https://github.com/apache/iceberg/pull/6660#discussion_r1088335461
##########
flink/v1.16/flink/src/main/java/org/apache/iceberg/flink/sink/FlinkSink.java:
##########
@@ -316,6 +316,11 @@ public Builder setSnapshotProperty(String property, String
value) {
return this;
}
+ public Builder toBranch(String branch) {
Review Comment:
Yeah it's a fair question, so in the Iceberg library API we're using
toBranch as well so I thought it would be nice to follow the same convention
for FlinkSink as well. for example to append files using the Iceberg library we
would do the following
```
table.appendFiles().append(FILE_A).toBranch("test-branch").commit()
```
and so I thought we could do the same for Flink
```
FlinkSink sink = FlinkSink.forRow(dataStream, SimpleDataUtil.FLINK_SCHEMA)
.table(table)
.tableLoader(tableLoader)
.toBranch("test-branch")
.set("write-format", "avro")
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]