Using a Handler class to send messages when called by "client"

Christian Migowski chrismfwrd at gmail.com
Mon Mar 8 02:26:32 EST 2010


Hi Michael,

Your question was not very specific so here is a quite generic answer:
Of course it is possible! When you connect to/are connected from
another system, you get the Netty Channel that represents this
connection (either from connect() or from getChannel() of the Event in
your server). Store the reference of that channel somewhere and use it
to send to the other system anytime you like.


regards,
christian!

On Sat, Mar 6, 2010 at 11:08 PM, Michael Lok <fulat2k at yahoo.com> wrote:
>
> Hi folks,
>
> I'm writing an application to send messages via TCP socket to a custom
> server.  Is it possible to use Netty in such a way that I can be able to
> send messages as an when necessary?  In other words, my application will
> serve as an intermediary server to other clients which will then send
> messages to the end server.
>
> Clients ==> My App (Netty client) ==> Custom Server
>
> Any help is greatly appreciated.
>
>
> Thanks.
> --
> View this message in context: http://n2.nabble.com/Using-a-Handler-class-to-send-messages-when-called-by-client-tp4687992p4687992.html
> Sent from the Netty User Group mailing list archive at Nabble.com.
> _______________________________________________
> netty-users mailing list
> netty-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/netty-users
>



More information about the netty-users mailing list