pub struct Relay {
pub mode: RelayMode,
pub instance: RelayInstance,
pub upstream: UpstreamDescriptor<'static>,
pub host: IpAddr,
pub port: u16,
pub internal_host: Option<IpAddr>,
pub internal_port: Option<u16>,
pub tls_port: Option<u16>,
pub tls_identity_path: Option<PathBuf>,
pub tls_identity_password: Option<String>,
pub override_project_ids: bool,
}Expand description
Relay specific configuration values.
Fields§
§mode: RelayModeThe operation mode of this relay.
instance: RelayInstanceThe instance type of this relay.
upstream: UpstreamDescriptor<'static>The upstream relay or sentry instance.
host: IpAddrThe host the relay should bind to (network interface).
port: u16The port to bind for the unencrypted relay HTTP server.
internal_host: Option<IpAddr>The host the relay should bind to (network interface) for internally exposed APIs, like health checks.
If not configured, internal routes are exposed on the main HTTP server.
Note: configuring the internal http server on an address which overlaps with the main
server (e.g. main on 0.0.0.0:3000 and internal on 127.0.0.1:3000) is a misconfiguration
resulting in approximately half of the requests sent to 127.0.0.1:3000 to fail, as the handling
http server is chosen by the operating system ‘at random’.
As a best practice you should always choose different ports to avoid this issue.
Defaults to Self::host.
internal_port: Option<u16>The port to bind for internally exposed APIs.
Defaults to Self::port.
tls_port: Option<u16>Optional port to bind for the encrypted relay HTTPS server.
tls_identity_path: Option<PathBuf>The path to the identity (DER-encoded PKCS12) to use for TLS.
tls_identity_password: Option<String>Password for the PKCS12 archive.
override_project_ids: boolAlways override project IDs from the URL and DSN with the identifier used at the upstream.
Enable this setting for Relays used to redirect traffic to a migrated Sentry instance. Validation of project identifiers can be safely skipped in these cases.