Updated all state for failure case

Have updated all the state to be consistent when failure happens. Need
to test failures during usual running for cases of failure during update
topology and other states of normal execution