Page MenuHomePhabricator

[reports-service] Introduce database client
ClosedPublic

Authored by bartek on Aug 25 2023, 3:10 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Dec 14, 7:42 PM
Unknown Object (File)
Sat, Dec 14, 7:42 PM
Unknown Object (File)
Sat, Dec 14, 7:42 PM
Unknown Object (File)
Sat, Dec 14, 7:41 PM
Unknown Object (File)
Sat, Dec 14, 7:30 PM
Unknown Object (File)
Mon, Nov 25, 3:04 PM
Unknown Object (File)
Mon, Nov 25, 8:21 AM
Unknown Object (File)
Nov 22 2024, 5:59 AM
Subscribers

Details

Summary

Similiar to other services, created a struct representing DynamoDB client.
Created basic interfaces to store and retrieve reports. They're very simple but sufficient for now.

Depends on D8939, D8895

Test Plan

Storing reports was tested in D8895, other methods are tested together with HTTP interface (later in the stack)

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

bartek held this revision as a draft.
bartek published this revision for review.Aug 25 2023, 4:21 AM
jon added inline comments.
services/reports/src/database/client.rs
58 ↗(On Diff #30306)

should this go in constants?

102 ↗(On Diff #30306)

Potentially avoid forcing a Vec construction here if we take IntoIter<ReportItem>. But feel strongly about it, as DDB deals with Vec directly.

This revision is now accepted and ready to land.Aug 25 2023, 4:37 PM
services/reports/src/database/client.rs
102 ↗(On Diff #30306)

Good point