another get_server method definition using generators.