[SERVER-38387] agg_out.js concurrency workload always fails to shard the output collection Created: 04/Dec/18  Updated: 29/Oct/23  Resolved: 14/Jan/19

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: None
Fix Version/s: 3.6.11, 4.0.7, 4.1.7

Type: Bug Priority: Major - P3
Reporter: Jack Mulrow Assignee: James Wahlin
Resolution: Fixed Votes: 0
Labels: todo_in_code
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Related
related to SERVER-43482 Complete TODO listed in SERVER-38387 Closed
related to SERVER-44213 Remove obsoleted agg_out.js blacklisting Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v4.0, v3.6, v3.4
Sprint: Query 2019-01-14, Query 2019-01-28
Participants:
Linked BF Score: 0

 Description   

The concurrency workload jstests/concurrency/fsm_workloads/agg_out.js runs aggregates with $out and will rarely attempt to shard the output collection with the key: _id: 'hashed', expecting all subsequent aggregates to fail.

The workload's first state inserts to the output collection and sharding a populated collection requires an existing index matching the proposed key, but the test does not create a hashed index on _id in the output collection, so every attempt to shard the output collection fails with InvalidOptions, which isn't caught because the test does not assert the shardCollection command succeeds.



 Comments   
Comment by Githook User [ 05/Feb/19 ]

Author:

{'name': 'James Wahlin', 'email': 'james@mongodb.com', 'username': 'jameswahlin'}

Message: SERVER-38387 agg_out.js concurrency workload always fails to shard the output collection

(cherry picked from commit 9ed4ddae8b3c2aa7f876bdbfce00523c2b2a118c)

SERVER-39081 Fix createIndexes/shardCollection race condition in agg_out.js

(cherry picked from commit aad17aeba520f5c421716cb2d740057be96ce61a)
Branch: v4.0
https://github.com/mongodb/mongo/commit/0aee7dae5a62206232223614cc95cb371e69070a

Comment by Githook User [ 04/Feb/19 ]

Author:

{'name': 'James Wahlin', 'email': 'james@mongodb.com', 'username': 'jameswahlin'}

Message: SERVER-38387 agg_out.js concurrency workload always fails to shard the output collection

(cherry picked from commit 9ed4ddae8b3c2aa7f876bdbfce00523c2b2a118c)

SERVER-39081 Fix createIndexes/shardCollection race condition in agg_out.js

(cherry picked from commit aad17aeba520f5c421716cb2d740057be96ce61a)
Branch: v3.6
https://github.com/mongodb/mongo/commit/683afc244ee5104372190d29c6905a868cb6a78d

Comment by Githook User [ 14/Jan/19 ]

Author:

{'username': 'jameswahlin', 'email': 'james@mongodb.com', 'name': 'James Wahlin'}

Message: SERVER-38387 agg_out.js concurrency workload always fails to shard the output collection
Branch: master
https://github.com/mongodb/mongo/commit/9ed4ddae8b3c2aa7f876bdbfce00523c2b2a118c

Generated at Thu Feb 08 04:48:49 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.