Hi Yogesh, From the documentation, it looks that the encoding is used only when the textline codec is activated.
https://github.com/apache/camel/blob/master/components/camel-netty4/src/main/docs/netty4-component.adoc So it's worth trying something like: <to uri="netty4:tcp://99.99.99.9999:9999?textline=true&encoding=UTF-16LE" /> hth, Alex On Fri, Apr 26, 2019 at 11:31 PM Yogesh Chawla <premiergenerat...@gmail.com> wrote: > Hello, > I am trying to send TCP data over a socket connection to a server written > in .NET. They are trying to decode what I send and are expecting Unicode > Little Endian with no byte order marking. In .NET this is done as follows: > > Encoding encoder = new System.Text.UnicodeEncoding(false, false); > byte[] byteData = encoder.GetBytes(data); > > To do this, I am trying to use Netty to send Unicode Little Endian > encoding. I thought it would be as simple as: > > <to uri="netty4:tcp://99.99.99.9999:9999?encoding=UTF-16LE" /> > > Ignore the IP above. I though the argument "encoding=UTF-16LE" would do it. > Is there a way we can tell what encoding's the netty4 endpoints allows? Any > tips on how I can have the message encoded in UTF-16LE format? > > Thanks! > Yogesh >