[SERVER-47475] Make PeriodicJob aware of cancelation at global shutdown Created: 10/Apr/20  Updated: 29/Oct/23  Resolved: 21/Apr/20

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 4.2.7, 4.4.0-rc2, 4.7.0

Type: Bug Priority: Major - P3
Reporter: Amirsaman Memaripour Assignee: Amirsaman Memaripour
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Related
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v4.4, v4.2, v4.0
Sprint: Service arch 2020-04-20, Service arch 2020-05-04
Participants:
Case:
Linked BF Score: 7

 Description   

Starting a PeriodicJob that is not in the NOT_SCHEDULED state causes an invariant failure (see here). However, a PeriodicJob might get stopped before it's even started if its process receives a kill signals before it has fully initialized. To tolerate such scenarios, PeriodicJob should check if shutdown is in progress and quick return before checking the invariant.



 Comments   
Comment by Githook User [ 22/Apr/20 ]

Author:

{'name': 'Amirsaman Memaripour', 'email': 'amirsaman.memaripour@mongodb.com', 'username': 'samanca'}

Message: SERVER-47475 Make PeriodicJob aware of cancelation at global shutdown

(cherry picked from commit e7165a3e49beb6b6904ba5047301a142cccea646)
Branch: v4.2
https://github.com/mongodb/mongo/commit/961990a17633e468f6d313f0f146ec635310724f

Comment by Githook User [ 22/Apr/20 ]

Author:

{'name': 'Amirsaman Memaripour', 'email': 'amirsaman.memaripour@mongodb.com', 'username': 'samanca'}

Message: SERVER-47475 Make PeriodicJob aware of cancelation at global shutdown

(cherry picked from commit e7165a3e49beb6b6904ba5047301a142cccea646)
Branch: v4.4
https://github.com/mongodb/mongo/commit/37931b8ddf5bfbd7d2e0813df9e92002395283cf

Comment by Githook User [ 21/Apr/20 ]

Author:

{'name': 'Amirsaman Memaripour', 'email': 'amirsaman.memaripour@mongodb.com', 'username': 'samanca'}

Message: SERVER-47475 Make PeriodicJob aware of cancelation at global shutdown
Branch: master
https://github.com/mongodb/mongo/commit/e7165a3e49beb6b6904ba5047301a142cccea646

Generated at Thu Feb 08 05:14:17 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.