Implement consume_in_thread_group() for RPC connections. Fixes bug 1050371.

The RPC service class has been updated to make use of this feature.

Change-Id: Ie13e0d7bf82bc3366e9c5ab1cb063fc96a4463ac