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

Manage connected client information via a decoration on the service context

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • None
    • None
    • Networking
    • Fully Compatible
    • Platform 5 06/26/16

    Description

      ClientBasic current caches information about the connected network client by holding an AbstractMessagingPort pointer. This pointer is accessed from a few places in the database layer, notably:

      • src/mongo/db/auth/sasl_commands.cpp
      • src/mongo/db/commands/authentication_commands.cpp
      • src/mongo/db/repl/replset_commands.cpp

      This couples the database implementation to details of the network implementation. Additionally, the last instance, in the replication code, makes use of the connection tagging facility, which is currently managed by a global "Ports" object instantiated inside messaging_port.cpp, which is used to implement MessagingPort::closeAllSockets.

      Rather than allowing the database layer direct access to the socket types and using globals to track connections, we should create a new connection management facility, and attach it to the service context. The connection management facility would be responsible for providing database Client level access to information about the network (local and remote addresses, X509 names, etc.), and for managing tagging and global actions on connected clients.

      Attachments

        Activity

          People

            backlog-server-platform DO NOT USE - Backlog - Platform Team
            andrew.morrow@mongodb.com Andrew Morrow (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: