Add tuple support with protocol v2 (JAVA-362).

Based on patch submitted by Robert Stupp.