openinx commented on pull request #1145:
URL: https://github.com/apache/iceberg/pull/1145#issuecomment-669027407


   > The only concern I have is about how methods are called in the stream 
writer -- whether multiple threads are used.
   
   
[Here](https://github.com/apache/iceberg/pull/1185/files#diff-d741068a159d97f5eaabd09c4a88ab55R92)
 is an example to show how to use the stream writer, saying we will chain the 
user provided  `DataStream` by appending two operators : 1) 
IcebergStreamWriter;  2) IcebergFilesCommitter ( with parallelism =1 ).  
Finally, the records from user's datastream will be sinked to iceberg table.  
we only need to load table once, and then initial those IcebergStreamWriter and 
IcebergFilesCommitter ,  and deploy to different TaskManager, each task will 
have a thread to process elements.  For one IcebergStreamWriter instance, 
there's one thread to use it to process events (Even if in the snapshot 
processing as jingsong said, we will have lock to handle the thread safety 
issue). 
   


----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to