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

Implement Return CanNotTargetItself error from Shard::runCommand

    XMLWordPrintableJSON

Details

    • Icon: Improvement Improvement
    • Resolution: Won't Fix
    • Icon: Major - P3 Major - P3
    • None
    • None
    • Sharding
    • None
    • Sharding
    • Fully Compatible

    Description

      Currently its possible to run a command on the node that schedules it via
      ShardRemote::runCommand. Instead the ShardRemote instance should return a new ErrorCode::CanNotTargetItself. This will allow clients that call it to catch the error and implement a different scenario. e.g. running the command locally.
      The possible implementation is to make RemoteCommandTargeter::findHost issue an error if its requested to "target itself". The code written as a part of SERVER-27772 fix needs to address the change when its done.

      Attachments

        Activity

          People

            backlog-server-sharding [DO NOT USE] Backlog - Sharding Team
            misha.tyulenev@mongodb.com Misha Tyulenev
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: