ThreadAction - run code in a controlled manner on another thread

ThreadAction runs code in a controlled manner on another thread and 
also passes exceptions back to the iitiatign thread.

Useful for testing as the sequence of actiosn can be carefully
controlled with Semaphores.

Rework ThreadTxn to use ThreadAction.
5 files changed