refactor server.js, place all inside derby.run because of cluster if not isProduction