Collection of multiple smaller clean ups in gitserver codebase
Created by: eseliger
Collection of various stuff I picked up while diving into the code more. Most notably, this reduces RPC calls to gitserver which makes the things that did them before essentially HA by that, and it does a lot of polish of the store after the trigger was introduced and we didn't need to do the on conflict inserts anymore.
Test plan
Tests still passing.