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

  • Home
  • SEARCH
  • 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 6898511
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T07:18:20+00:00 2026-05-27T07:18:20+00:00

I have programmed a plugin in Lua for a game that sends player information

  • 0

I have programmed a plugin in Lua for a game that sends player information via a UDP packet (512 bytes) to a remote server that reads the data from the packet and aggregates all player information into an xml file (which can then be viewed on the web by all players so they can see eachother’s current state).

I have programmed the server in Java using a DatagramSocket to handle the incoming packets, however I noticed some strange behavior. After a certain period of time, the DatagramSocket appears to temporarily stop accepting connections for about 10-12 seconds, then resumes normal behavior again (no exceptions are thrown that I can see). There is definitely a relationship between how often packets are sent by the clients and how quickly this behavior occurs. If I increase the update frequency of the clients, the DatagramSocket will “fail” sooner.

It may be worth mentioning, but each packet received spawns a thread which handles the data in the packet. I am running the server on linux if it makes a difference!

Does anyone know what could be causing this sort of behavior to occur?

Andrew

  • 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-05-27T07:18:20+00:00Added an answer on May 27, 2026 at 7:18 am

    UDP is a network protocol with absolutely no delivery guarantee. Any network component anywhere along the way (including the client and server PC itself) can decide drop the packets for any reason, such as high load or network congestion.

    This means you’ll have to spelunk a bit to find out where the packet loss is happening. You can use something like wireshark to see whether packets are arriving at the server at all.

    If reliable delivery is more important than lower latency, switch to TCP. If you stick to UDP you’ll have to allow for packets getting lost, regardless of whether you fix this particular issue at this particular time.

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

Sidebar

Related Questions

I have programmed an emulator, but I have some doubts about how to organizate
Once I have programmed GUI with Java and have used Form Layouts. Form layout
I have been using oracle database throughout database courses, and I have programmed there
I have recently programmed a console application and I've experienced a lot of pain
I have never programmed a gadget for Vista or Seven, but I would like
I have a webservice programmed in coldfusion which I'm attempting to consume using c#.net.
I have multiple IPs on a NIC. I've programmed a console application to connect
I have another programmer who I'm trying to explain why it is that a
We have a junior programmer that simply doesn't write enough tests. I have to
I'm building a commenting mechanism into an application that allows a programmer/plugin author to

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.