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

Deduplicate ReplyBuilderInterface::augmentReplyWithStatus logic

    • Type: Icon: Improvement Improvement
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Server Programmability
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      ReplyBuilderInterface::augmentReplyWithStatus duplicates CommandHelpers::appendCommandStatusNoThrow, supposedly to avoid a cyclic library dependency. The former is used primarily by mongod/mongocryptd, whereas the latter is primarily used by mongos, so any deviations can create behavioral differences between the two. We should unify these implementations to eliminate the risk of divergence.

      https://github.com/10gen/mongo/blob/4e860a655875d75217a485c54344f9cdfadb37c6/src/mongo/rpc/reply_builder_interface.cpp#L54-L55

      https://github.com/10gen/mongo/blob/4e860a655875d75217a485c54344f9cdfadb37c6/src/mongo/db/commands.cpp#L389-L390

      ReplyBuilderInterface::augmentReplyWithStatus is owned by NO whereas CommandHelpers::appendCommandStatusNoThrow is owned by SP. I'm going to assign this to SP since it concerns standardizing an API.

            Assignee:
            Unassigned Unassigned
            Reporter:
            patrick.freed@mongodb.com Patrick Freed
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              None
              None
              None
              None