Working Sender and Receiver, refactored to use factory