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 6121165
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T15:45:12+00:00 2026-05-23T15:45:12+00:00

What happens if a client connected through a Socket has a bad lag ?

  • 0

What happens if a client connected through a Socket has a bad lag ?
Let’s say i call socket.read() from the TCP server, and the client writes some stuff on the network pipe, but his connection is laging for 1 or 2 minutes. What will happen ? Will the read fail ? Or will it wait ?

I’m not sure if it’s even possible, but i’m playing online chess on FICS server and sometimes it seems to happen from my point of view (I’m only a user of this chess server).

I’m asking this because i’m working on an online game and i’d like to handle such cases one way or another. But first I need to know if:

  • it can happen
  • it can be detected

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-05-23T15:45:13+00:00Added an answer on May 23, 2026 at 3:45 pm

    I’d advise not relying solely on setting the SO_TIMEOUT variable but rather add application-level heartbeats between your client and server. If either the client or server does not receive a heartbeat message within a specified time (e.g. within twice the heartbeat frequency) it should sever the connection, and in the client’s case attempt a reconnect.

    Using a heartbeat mechanism also allows you to measure the lag by monitoring the delay in receiving heartbeat messages on each end.

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

Sidebar

Related Questions

I have a server-side application opens a socket thread for each connected client. I
I have a server and has 2 clients connecting to it through TCP. These
server: vxworks 6.3 calls the usual socket, bind, listen, then: for (;;) { client
Lets say i have an client application on iOS which is connected to a
I have a server program and a client program. I built it based from
Currently I have this problem. Client downloads from server successfully only the 1st time.
I have a client-server java application, where communication happens over SSL. Right now I
We use Enterprise Library 3.0 to access Oracle DB (microsoft oracle client). What happens
What happen if web.config gets updated while ASP (ASP.NET 2.0) server still process client
What happens if I use SHGetFolderPath api call in a 32 bit system with

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.