[deploy] implement REVISION upgrade mechanism

commit c8df4e7b3af86d8c9d27ba1ed3071a682bb212da