Handling Data Preservation on dora stop and dora destroy Commands in Rust #586
-
Hi! Currently, I have a Dora node written in Rust that is storing sensor data into an HDF5 file every minute or so. I was wondering if there was an easy way to handle a Obviously, in Rust, there are crates like the ctrlc crate to handle interruptions like this. However, we do not use ctrl+c to end a Dora dataflow. I'm not entirely sure what happens when a Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hi, thanks for reaching out! So basically if you use the cli and send a stop signal. Each node will receive a stop event before. Closing the event stream, that will make the loop return None. In which case you can write on disk. You can use --grace-duration if you're not is killed to quickly and does not have time to write on disk. Does this work for you or do you need a more specific control flow for your dataflow ? |
Beta Was this translation helpful? Give feedback.
Hi, thanks for reaching out!
So basically if you use the cli and send a stop signal.
Each node will receive a stop event before. Closing the event stream, that will make the loop return None.
In which case you can write on disk.
You can use --grace-duration if you're not is killed to quickly and does not have time to write on disk.
Does this work for you or do you need a more specific control flow for your dataflow ?