new ChannelBuffer[]{ChannelBuffers.wrappedBuffer("|".getBytes())}
);
// The String decoder is sharable so we wrap it in a simple SharedChannelHandlerProvider
ChannelHandlerProvider stringDecoder = ChannelHandlerProviderFactory.getInstance("stringDecoder", new StringDecoder());
// Lastly, we need a "business" handler. It is sharable so we wrap it in a simple SharedChannelHandlerProvider
ChannelHandlerProvider stringReporter = ChannelHandlerProviderFactory.getInstance("stringReporter", new StringReporter());
// We want to send some numbers back to the caller, so we need an ObjectEncoder
// We're going to use a simple groovy client to submit strings, so it needs to be a CompatibleObjectEncoder
// which is not sharable so we need to wrap it's configuration in a ChannelHandlerProviderFactory