driftx/Telephus — pull request #32 by nickmbailey (2012-04-11 15:35:21+00:00)
Title: Pooling rpc address

This pull request also includes the changes from the pull request: https://github.com/driftx/Telephus/pull/31

That request should be merged in first before reviewing this one.

The changes here should be pretty simple. Versions of cassandra > 0.7 include an rpc_address field in the output of describe_ring. When using describe ring for purposes of connection pooling/failover the rpc address should be used when attempting to connect to auto discovered nodes, assuming it is a good ip and not '0.0.0.0'.

There is an included unit test that should cover all added functionality. Additionally I've manually tested against both 0.7, and 0.8 where nodes had differing rpc and listen addresses.