Dataflow-Based Rollback Recovery in Distributed and Multi-Core Systems