added recovery mechanishm to main
added recovery mechanishm to main
added recovery mechanishm to main