asio icon indicating copy to clipboard operation
asio copied to clipboard

ISSUE : Immediate reception of the network packet, but late processing of the data.

Open 007basaran opened this issue 2 years ago • 0 comments

I reviewed a project prepared with Boost asio, I'm planning to switch to Boost ASIO by abandoning the use of Windows Overlapped IOCP due to too many functional errors.

Project I'm reviewing: https://github.com/mustafakemalgilor/libtcp_boost

In this project, I want to talk about a problem I had while the server was running, I integrated this project into my game server, I use this project during server-client package exchange.

The player sends packets while walking in the game, sends packets when he uses a skill, in short, every function the player does is a packet, and the server processes these packets.

My Problem is - ) : When the player's network packet comes to the server, OnDataReceived Handler seems to be detected directly, but the data is processed too late, if the player sends packets continuously, the previously sent data is processed faster. When using Windows IOCP, the incoming packet was processed immediately, but when I checked this project prepared with Boost, the incoming data is not processed immediately. Normally, it should be processed within 1-2 ms, but the data is pending for a very long time, what could be the reason for this?

Maybe I didn't explain it fully, if you need any other details, please let me know.

How can I solve this problem, or rather is it a problem or a deficiency due to my ignorance?

007basaran avatar Aug 16 '22 01:08 007basaran