[BZ-1073880] add a method to create a single thread executor
(cherry picked from commit 80c3bb63f3fe372d29e7445d302e6a2e379068ff)