Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. IO Completion Ports socket error

IO Completion Ports socket error

Scheduled Pinned Locked Moved C / C++ / MFC
helpc++game-devsysadminquestion
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • Y Offline
    Y Offline
    yani dzhurov
    wrote on last edited by
    #1

    hi guys, we have a game server/written in c++/ and an application/written in erlang/ simulating thousand of users playing on the game server. The server manages connections using IO Completion ports, but when launching many/thousands connections/ against the server it starts dropping connections - the erlang application reports that the socket is closed, while trying to write to the socket. How can I get the reason for closing the socket on the server side - with GetLastError function i'm getting just the error code of the io operation attempt on the socket. But I need the error for socket closure, please help! All ideas are welcomed, Thanks yani

    _ 1 Reply Last reply
    0
    • Y yani dzhurov

      hi guys, we have a game server/written in c++/ and an application/written in erlang/ simulating thousand of users playing on the game server. The server manages connections using IO Completion ports, but when launching many/thousands connections/ against the server it starts dropping connections - the erlang application reports that the socket is closed, while trying to write to the socket. How can I get the reason for closing the socket on the server side - with GetLastError function i'm getting just the error code of the io operation attempt on the socket. But I need the error for socket closure, please help! All ideas are welcomed, Thanks yani

      _ Offline
      _ Offline
      __yb
      wrote on last edited by
      #2

      socket closure causes 1. completion of a queued read operation with 0 bytes(gracefull close) and this is no error. or/and 2. GetQueuedCompletionStatus returns false. now GetLastError returns the error of the queued operation. U gotta mungle with the OS's settings to allow more sockets and give WSAAccept/accept a big queue.

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups