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

kill_pinned_cursor.js is not robust to periodic sharded index consistency checker



    • Sharding NYC
    • Fully Compatible
    • ALL
    • 0
    • 2


      kill_pinned_cursor.js has fairly loose targeting of its getMores here and here. If there is another getMore additionally running on the system (eg. from the periodic sharded index consistency checker), then this can cause the $currentOp to return more than 1 matching getMore, making the test fail here or here.

      Similarly, if there is some other internal getMore running on the system when the parallel shell is started and it has cursors pinned, then the sleep to wait for the parallel shell to startup can short-circuit. In conjunction with the above loose targeting, this can cause the killFunc to kill the internal getMore, instead of the test one. This causes the test getMore to never be interrupted, and since it is waiting on a failpoint that is only switched off after the getMore returns, this means the test is deadlocked and will time out.

      Based on this kill_pinned_cursor.js should be updated to more accurately use $currentOp to find only the test getMore. eg. have the original find include a dummy query predicate (that increments for each test) such as "foo1": {$exists: false}, and then have the $currentOp only look for getMores with that query predicate in the originating command.


        Issue Links



              backlog-server-sharding-nyc Backlog - Sharding NYC
              kevin.pulo@mongodb.com Kevin Pulo
              0 Vote for this issue
              2 Start watching this issue