Refactoring to separate REST API server definition from start up.
Revert "Refactoring to separate REST API server definition from start up."

This reverts commit c6641065c48368c2f0bd5a737f317867e3231a3e.