Migrated Server run() behavior to its main() method.