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

Circular dependency between the libraries for Client and transport::Session

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major - P3 Major - P3
    • None
    • None
    • None
    • None
    • Service Arch
    • ALL

    Description

      The Client class is part of the service context/service/client/op context hierarchy of process-related concepts and they are all decorable. The Client class also owns a transport::Session object, which implemented in a separate library and that library depends on ServiceContext.

      This makes the library dependency between service_context and transport_layer_common circular, which requires the introduction of unnecessary references to executables that don't even care about either of these two libraries, such as this one.

      This ticket is to find a way to decouple this circular dependency. IMO it could be done in one of two ways:

      1. (Most desirable) Pull the transport::Session into a decoration of Client as opposed to ownership
      2. (Undesirable as it just adds more complexity to our component graph) Pull the ServiceContext into a separate library and make Client and transport::Session both depend on it (this should only be done if there is absolutely no other way)

      Attachments

        Activity

          People

            amirsaman.memaripour@mongodb.com Amirsaman Memaripour
            kaloian.manassiev@mongodb.com Kaloian Manassiev
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated: