Page MenuHomePhabricator

[reports-service] Endpoint for Redux Devtools import
ClosedPublic

Authored by bartek on Aug 28 2023, 2:51 AM.
Tags
None
Referenced Files
F3366775: D8972.id30634.diff
Mon, Nov 25, 12:25 PM
F3366208: D8972.diff
Mon, Nov 25, 10:08 AM
Unknown Object (File)
Sat, Nov 16, 6:15 AM
Unknown Object (File)
Sun, Nov 10, 12:58 AM
Unknown Object (File)
Sun, Oct 27, 3:42 PM
Unknown Object (File)
Sep 28 2024, 9:54 AM
Unknown Object (File)
Sep 27 2024, 10:56 PM
Unknown Object (File)
Sep 27 2024, 10:56 PM
Subscribers

Details

Summary

Keyserver has an endpoint for importing Redux Devtools state. This diff adds a similar endpoint to reports-service.

The function for modifying JSON is based on: this keyserver function.

Depends on D8971

Test Plan
  1. Uploaded an error report to the service
  2. Opened the endpoint in the browser - a report-{uuid}.json file was downloaded
  3. I was able to open the file in Redux Devtools and browse the state

For non-error reports, the service returned HTTP 415.

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

bartek held this revision as a draft.
bartek published this revision for review.Aug 28 2023, 3:00 AM
michal added inline comments.
services/reports/src/service.rs
198 ↗(On Diff #30430)

If _persist doesn't exists will it create it be default or will this throw an error?

This revision is now accepted and ready to land.Aug 28 2023, 6:51 AM
services/reports/src/service.rs
198 ↗(On Diff #30430)

It will be created