An state machine architecture based platform for cloud