pkg/graphdb: use transactions for transactions

Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>
Merge pull request #9746 from unclejack/graphdb_fix

pkg/graphdb: use transactions for transactions
pkg/units: fix size_test.go compilation

Signed-off-by: Cristian Staretu <cristian.staretu@gmail.com>