In mapReduceTriplets, walk vertices instead of edges

This greatly improves performance in Pregel when the active set is small, such as in the later stages of connected components.

Not ready to merge yet! To do:
* Support walking destination vertices as well as source vertices.
* Dynamically switch between the two strategies based on the size of the active set.