camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Cristiano Costantini <cristiano.costant...@gmail.com>
Subject Re: Codecs for Camel Mina2 (or Netty?)
Date Thu, 28 Nov 2013 07:50:45 GMT
Thank you Claus,
then I'll check about mina2 on the book when I'll be back home this evening
;-)

In the meanwhile I've also seen that there are some examples down in the
section "Using Multiple Codecs" for the Camel Netty component (I skipped
that section at first as I read only the "Usage Sample" section that say
nothing about encoder/decoders)

Cristiano



2013/11/28 Claus Ibsen <claus.ibsen@gmail.com>

> Camel in Action chapter 7, section 7.5.2 talks about how to write
> custom codecs with mina and have example to go along.
>
> Also you can check the unit tests of these components as we may have a
> custom codec unit test also.
>
> And then there is the documentation of these projects also you can
> take a look at how to write custom codecs.
>
> And for Netty then the Netty in Action book have a full chapter on
> writing custom codecs.
> http://manning.com/maurer/
>
>
>
> On Thu, Nov 28, 2013 at 8:27 AM, Cristiano Costantini
> <cristiano.costantini@gmail.com> wrote:
> > Hi All,
> > I'm trying to make a camel-mina2 TCP endpoint which should only dump that
> > bytes are received by the socket.
> >
> > With UDP this is easy as "For UDP if no codec is specified the default
> uses
> > a basic ByteBuffer based codec."
> >
> > On TCP I have some limitations, textline don't works as my consumer don't
> > sends endlines.
> > Could you suggest me how to make or use a simple codec that allow me to
> do
> > this in TCP?
> > It is enough for me to sysout the number of bytes of each TCP receive...
> >
> > I've seen that the custom codec need to be registered in SimpleRegistry,
> > but I've found no examples with real codecs and I don't know what to use.
> > Do mina2 component already provides some codec I can use, or should I
> write
> > a codec by myself? Or should I use camel-netty?
> >
> > Thank you!
> > Cristiano
> >
> > P.S. Sorry I'm a newbie of camel-mina2, it is the second time I use this
> > component but with UDP was much easier, I just need some hints for taking
> > the right direction an then I'll figure out what to do by myself
>
>
>
> --
> Claus Ibsen
> -----------------
> Red Hat, Inc.
> Email: cibsen@redhat.com
> Twitter: davsclaus
> Blog: http://davsclaus.com
> Author of Camel in Action: http://www.manning.com/ibsen
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message