1. A computer program product comprising: a non-transitory computer readable storage medium having computer readable program code embodied therewith, the computer readable program code comprising: computer readable program code configured to receive at least one measurement indicative of a reliability cost associated with executing a dataflow; computer readable program code configured to compute a degree of replication of at least one intermediate data set in the dataflow based on the reliability cost; wherein the reliability cost comprises a metric based at least on a sum of two sub-costs, the two sub-costs comprising a cost of replication for the at least one intermediate data set in the dataflow and a cost of regeneration for the at least one intermediate data set in the dataflow; computer readable program code configured to minimize the reliability cost; and computer readable program code configured to communicate at least one replication factor, corresponding to the computed degree of replication, to at least one component responsible for replication of the at least one intermediate data set in the dataflow; wherein the at least one intermediate data set is replicated according to the replication factor.