Rewriting Trustin Lee example using JDK7 NIO2.