Sorry for bothering you guys, found out the problem by myself. <div>Wasn&#39;t initializing the ChannelPipelineFactory correctly, thanks anyways! :)<br><br><div class="gmail_quote">On Mon, Jul 25, 2011 at 5:08 PM, Akash Gangil <span dir="ltr">&lt;<a href="mailto:akashg1611@gmail.com">akashg1611@gmail.com</a>&gt;</span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div class="gmail_quote"><div class="im"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<blockquote style="margin:0 0 0 40px;border:none;padding:0px"><div><div><br></div></div></blockquote>
<div><b>EchoServerhandler.java :</b></div><blockquote style="margin:0 0 0 40px;border:none;padding:0px">
<div><div> @Override</div><div>      public void messageReceived(</div><div>              ChannelHandlerContext ctx, MessageEvent e) {</div><div>    <span style="white-space:pre-wrap">        </span>  System.out.print(&quot;Message Received : &quot; + e.getMessage());</div>



<div>    <span style="white-space:pre-wrap">        </span><span style="background-color:rgb(255, 255, 255)"><font color="#ff0000">  Packet req = (Packet) e.getMessage();</font></span></div>
<div>    <span style="white-space:pre-wrap">        </span>  System.out.print(&quot;Packet Id received  :  &quot; + req.getPacketId());</div><div>    <span style="white-space:pre-wrap">        </span>  System.out.print(&quot;Packet Type received  :  &quot; + req.getPacketType());</div>



<div>    <span style="white-space:pre-wrap">        </span>  System.out.print(&quot;Packet Content received  :  &quot; + req.getPacketContent());</div><div><span style="font-weight:bold">     </span>}</div>
</div></blockquote><div><br></div></blockquote><div><br></div></div><div>Also a system.out.print(e.getMessage()) here gives</div><div>Message Received : BigEndianHeapChannelBuffer(ridx=0, widx=17, cap=17)</div><div>so I guess somehow the decoder is not working.</div>


<div><br></div><div>Though, I have implemented the same message receive logic on the client side too,</div><div>and there I am able to receive messages from the server through this framework.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


<div></div><div>-- </div></blockquote></div>Akash<font color="#888888"><br><br>
</font></blockquote></div><br><br clear="all"><br>-- <br>Akash<br><br>
</div>