The following describes Windows support for generating a report.json file when the task times out in Evergreen. It is adapted from what is currently done in shell_utils_launcher.cpp and signal_handlers.cpp.
Spawn a new thread in resmoke.py that
- Creates an Event object using win32event.CreateEvent().
- Waits on the Event object indefinitely using win32event.WaitForSingleObject().
- If the event is ever set, then dump the stacks of the process and write out the report.json file.
- Get the handle to the Event object created by resmoke.py using win32event.OpenEvent().
- Set the event.
We still need to come up with some naming convention for the Event object. One idea is for it to use the task_id from Evergreen.