publish reason of failure
save and restore state