Added RunMainWithPersistance