// Set up the pipeline factory.
bootstrap.setPipelineFactory(new ChannelPipelineFactory() {
public ChannelPipeline getPipeline() throws Exception {
return Channels.pipeline(
new ObjectDecoder(ClassResolvers.cacheDisabled(getClass().getClassLoader())),
new SimpleChannelHandler() {
public void messageReceived(ChannelHandlerContext ctx,MessageEvent e) throws Exception {
Date date = (Date)e.getMessage();
slog("Hey Guys ! I got a date ! [" + date + "]");
super.messageReceived(ctx, e);
}