Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9131195
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T08:06:15+00:00 2026-06-17T08:06:15+00:00

Now I am implementing UDP server to gather sflow datagrams using netty library. Here

  • 0

Now I am implementing UDP server to gather sflow datagrams using netty library.

Here is my setting for udp server.

ChannelFactory factory = new NioDatagramChannelFactory(this.threadPool.getScheduledExecutor());
    ConnectionlessBootstrap bootstrap = new ConnectionlessBootstrap(factory);
    bootstrap.setPipelineFactory(new ChannelPipelineFactory(){
        public ChannelPipeline getPipeline(){
            ChannelPipeline lChannelPipeline = Channels.pipeline();
            lChannelPipeline.addLast("sflowmessagedecoder", new SflowMessageDecoder());
            lChannelPipeline.addLast("handler", new SflowCollectorHandler());

            return lChannelPipeline;
        }
    });

    bootstrap.setOption("receiveBufferSize", 65536);
    bootstrap.bind(new InetSocketAddress(port));

The problem is that when I receive a sflow datagram (about 1300 bytes long, this can be checked using wireshark), netty only reads about 700 bytes, this can be checked by channelbuffer’s size, of the datagram from the channelbuffer.

However, I use java.net.* libraries such as DatagramSocket.class and DatagramPacket.class, it receives sflow datagram correctly (about 1300 bytes).

Somebody can help me? Due to this, I cannot parse sflow datagram correctly.

Thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T08:06:16+00:00Added an answer on June 17, 2026 at 8:06 am

    I had the same Issue, try using Oio and not Nio! (simply change “nio” to “oio” and “Nio” to “Oio”.

    http://lists.jboss.org/pipermail/netty-users/2009-June/000891.html

    Now it’s working 😉

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm implementing a client/server application using UDP transmissions. Here is my part of my
I'm now implementing the network program using the namedpipe and C#. Within the server
I am using this library for implementing coverflow in my app http://www.chaosinmotion.com/flowcover.html Now I
Hey I am implementing the drag and drop operations using Kineticjs Now I want
I am iphone developer but now i am implementing cocoa application.I am new for
I am now implementing an email filtering application using the Naive Bayes algorithm. My
I'm now implementing an epub reader in iphone. I'm using uiwebview to display the
I am quite new to the FuelPHP framework. Right now I'm implementing an autocomplete
I'm implementing a network server that processes udp packets. I want to avoid replay
I'm now implementing my academic project software using named pipe technologies to connect heterogeneous

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.