relay_dynamic_config/lib.rs
1//! Protocol for dynamic configuration passed down to Relay from Sentry.
2//!
3//! In contrast to static configuration files, parts of Relay's configuration is generated by
4//! Sentry and polled by Relay in regular intervals.
5//! Dynamic configuration includes (but is not limited to)
6//!
7//! 1. rate limits and quotas,
8//! 1. feature flags,
9//! 1. settings that the user configured in Sentry's UI.
10//!
11//! # Project Configuration
12//!
13//! So far, the only scope of dynamic configuration is per [`relay_auth::PublicKey`] a.k.a. [DSN](https://docs.sentry.io/product/sentry-basics/dsn-explainer/).
14//! The schema for this configuration is defined in [`ProjectConfig`].
15//!
16//! ## Example Config
17//!
18//! ```json
19//! {
20//! "organizationId": 1,
21//! "config": {
22//! "excludeFields": [],
23//! "filterSettings": {},
24//! "scrubIpAddresses": False,
25//! "sensitiveFields": [],
26//! "scrubDefaults": True,
27//! "scrubData": True,
28//! "groupingConfig": {
29//! "id": "legacy:2019-03-12",
30//! "enhancements": "eJybzDhxY05qemJypZWRgaGlroGxrqHRBABbEwcC",
31//! },
32//! "blacklistedIps": ["127.43.33.22"],
33//! "trustedRelays": [],
34//! },
35//! }
36//! ```
37//!
38//! # Global configuration
39//!
40//! This is the configuration for all Relays, independently from what per-project configuration is, and is defined in [`GlobalConfig`].
41//!
42//! ## Example Config
43//!
44//! ```json
45//! {
46//! "measurements": {
47//! "builtinMeasurements": [
48//! {
49//! "name": "app_start_cold",
50//! "unit": "millisecond"
51//! }
52//! ],
53//! "maxCustomMeasurements": 1
54//! }
55//! }
56//!
57#![warn(missing_docs)]
58#![doc(
59 html_logo_url = "https://raw.githubusercontent.com/getsentry/relay/master/artwork/relay-icon.png",
60 html_favicon_url = "https://raw.githubusercontent.com/getsentry/relay/master/artwork/relay-icon.png"
61)]
62#![allow(clippy::derive_partial_eq_without_eq)]
63
64mod defaults;
65mod error_boundary;
66mod feature;
67mod global;
68mod metrics;
69mod project;
70mod utils;
71
72pub use error_boundary::*;
73pub use feature::*;
74pub use global::*;
75pub use metrics::*;
76pub use project::*;
77pub use utils::*;