backport CASSANDRA-6927 to 2.0
merge