Added error structures and helper methods for database client. These are mostly copy-pasted from blob and identity services. In the future I plan to extract these to some shared rust library: https://linear.app/comm/issue/ENG-2311/shared-rust-code-across-services
Depends on D6178