Deduplicate ReplyBuilderInterface::augmentReplyWithStatus logic

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Unresolved
    • Priority: Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Server Programmability
    • None
    • 3
    • 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
              Reporter:
              Patrick Freed
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated: