Server code to demonstrate non-blocking IO