@c1m-public/dash-site-kit 0.4.0 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -1
- package/dist/sentry.d.ts +5 -0
- package/dist/sentry.js +6 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -173,7 +173,10 @@ server the kit uses `CHANNEL_SITE_NAME` when present, then derives `site` from
|
|
|
173
173
|
`location.hostname`. Every event also receives `site_kind=dash-site`, so one
|
|
174
174
|
shared Sentry project and one Grafana dashboard can separate future site
|
|
175
175
|
families without another per-deployment variable. This prevents a deployment
|
|
176
|
-
from claiming error reporting while sending no attributable events.
|
|
176
|
+
from claiming error reporting while sending no attributable events. The
|
|
177
|
+
`observability.grafana_dashboard` event context links directly back to the same
|
|
178
|
+
site selection in the shared Grafana dashboard; it is derived from `site` and
|
|
179
|
+
does not need configuration.
|
|
177
180
|
Use `CHANNEL_SITE_CHANNEL_ID` only when one deployment always represents one
|
|
178
181
|
channel. If a process can serve multiple channels, attach `channel_id` inside a
|
|
179
182
|
request-local Sentry scope after resolving the request instead of setting a
|
package/dist/sentry.d.ts
CHANGED
package/dist/sentry.js
CHANGED
|
@@ -39,6 +39,12 @@ export function resolveChannelSiteSentryOptions(configuration) {
|
|
|
39
39
|
enableLogs: false,
|
|
40
40
|
...(environment ? { environment } : {}),
|
|
41
41
|
initialScope: {
|
|
42
|
+
contexts: {
|
|
43
|
+
observability: {
|
|
44
|
+
grafana_dashboard: "https://cloud1medialtd.grafana.net/d/c1m-sites-errors-health/saasdash-sites-errors-health" +
|
|
45
|
+
`?var-site=${encodeURIComponent(site)}&var-site_kind=dash-site&from=now-24h&to=now`,
|
|
46
|
+
},
|
|
47
|
+
},
|
|
42
48
|
tags: {
|
|
43
49
|
site,
|
|
44
50
|
site_kind: "dash-site",
|