Implemented simple nio example for channels