Fix a thread safety issue in TimerServiceImpl

The commit here fixes a thread safety issue in TimerServiceImpl.

P.S: Sorry about the import reordering noise in the PR, but at least this in now in correct order, so I let that change stay