Add locks around execution engine.