The function has use outside of the monitors as it makes execution of worker tasks much more convenient. Currently, this change only moves the code and takes it into use: there should be no functional changes.