sending messages from one thread