We should duplicating code like this. The pattern seems to be repeated in several places. Much better to just have a method which takes a Runnable and does the check of actualCtx.isOnCorrectWorker itself. Most places (e.g. exceptions, connections created) where this pattern is used performance is not critical so the creation of an extra Runnable does not matter.
For the few places where performance is critical (e.g. message received) then can avoid an extra Runnable by abstracting out the duplicated code into a local method and calling that.