Reduce the probability of test flakiness in server

Some transactions have been shown to be prone to transient transaction failures, such
as from DeadLockExceptions. Those transactions will now be retried a limited number of times.
Merge pull request #2511 from chrisvest/2.2-reduce-flakiness

Reduce the probability of test flakiness in server