grafana/pkg/components/imguploader
Joe Blubaugh 687e79538b
Alerting: Add a general screenshot service and alerting-specific image service. (#49293)
This commit adds a pkg/services/screenshot package for taking and uploading screenshots of Grafana dashboards. It supports taking screenshots of both dashboards and individual panels within a dashboard, using the rendering service.

The screenshot package has the following services, most of which can be composed:

BrowserScreenshotService (Takes screenshots with headless Chrome)
CachableScreenshotService (Caches screenshots taken with another service such as BrowserScreenshotService)
NoopScreenshotService (A no-op screenshot service for tests)
SingleFlightScreenshotService (Prevents duplicate screenshots when taking screenshots of the same dashboard or panel in parallel)
ScreenshotUnavailableService (A screenshot service that returns ErrScreenshotsUnavailable)
UploadingScreenshotService (A screenshot service that uploads taken screenshots)

The screenshot package does not support wire dependency injection yet. ngalert constructs its own version of the service. See https://github.com/grafana/grafana/issues/49296

This PR also adds an ImageScreenshotService to ngAlert. This is used to take screenshots with a screenshotservice and then store their location reference for use by alert instances and notifiers.
2022-05-22 22:33:49 +08:00
..
gcs Security: Add gosec G304 auditing annotations (#29578) 2020-12-03 22:13:06 +01:00
azureblobuploader_test.go Migrate to Wire for dependency injection (#32289) 2021-08-25 15:11:22 +02:00
azureblobuploader.go Chore: Disable default golangci-lint filter (#29751) 2020-12-15 09:32:06 +01:00
imguploader_test.go Migrate to Wire for dependency injection (#32289) 2021-08-25 15:11:22 +02:00
imguploader.go Alerting: Add a general screenshot service and alerting-specific image service. (#49293) 2022-05-22 22:33:49 +08:00
localuploader_test.go migrate away from goconvey (#36203) 2021-07-02 19:22:47 +08:00
localuploader.go imguploader: Add support for new internal image store (#6922) 2018-01-12 21:40:12 +01:00
mock.go Alerting: Add a general screenshot service and alerting-specific image service. (#49293) 2022-05-22 22:33:49 +08:00
s3uploader_test.go Migrate to Wire for dependency injection (#32289) 2021-08-25 15:11:22 +02:00
s3uploader.go Chore: upgrade gocloud.dev and go mod tidy (#47797) 2022-04-15 07:48:44 -07:00
webdavuploader_test.go migrate away from goconvey (#36203) 2021-07-02 19:22:47 +08:00
webdavuploader.go Chore: Disable default golangci-lint filter (#29751) 2020-12-15 09:32:06 +01:00