Pass connection context to transaction execution

My approach on/Targets #563.
Why are you allocating memory for the object id on the _heap_?