Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-40583

Provide reason for why connections are closed

    • Type: Icon: Improvement Improvement
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 4.0.9
    • Component/s: None
    • Labels:
    • Service Arch 2019-05-06, Service Arch 2019-05-20, Service Arch 2019-07-15

      Currently, when a server closes connections, it sometimes provides a reason why it does that, and sometimes does not.

      SERVER-39941 provides an example when the server does indicate the reason for closing a connection:

      2019-03-04T13:07:11.146-0500 E NETWORK  [conn129] no SSL certificate provided by peer; connection rejected
      2019-03-04T13:07:11.146-0500 I NETWORK  [conn129] Error receiving request from client: SSLHandshakeFailed: no SSL certificate provided by peer; connection rejected. Ending connection from (connection id: 129)

      SERVER-40556 provides an example when the server does not indicate the reason:

      2019-04-09T20:55:09.182-0400 I NETWORK  [listener] connection accepted from #3015 (1 connection now open)
      2019-04-09T20:55:09.182-0400 I NETWORK  [conn3015] received client metadata from conn3015: { application: { name: "MongoDB Shell" }, driver: { name: "MongoDB Internal Client", version: "4.0.8" }, os: { type: "Windows", name: "Microsoft Windows 10", architecture: "x86_64", version: "10.0 (build 17763)" } }
      2019-04-09T20:55:09.184-0400 I NETWORK  [conn3015] end connection (0 connections now open)

      In cases like RUBY-1713, connections are being closed when the driver does not expect this leading to the driver marking the server unknown (per SDAM specifications), which ultimately can cause application unavailability. Troubleshooting these cases is currently difficult because the server side does not indicate whether a connection close was initiated by the server, and if so for what reason, vs the server closing a connection on which a network error occurred, for example.

            ben.caimano@mongodb.com Benjamin Caimano (Inactive)
            oleg.pudeyev@mongodb.com Oleg Pudeyev (Inactive)
            0 Vote for this issue
            6 Start watching this issue