DDF-511 fixed some thread safety issues in the handlers