Moved server utilities to separate file