Change the api for start-nio-server to be flat
Use the .. macro to simplify java interop
Other improvements