You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -144,10 +163,6 @@ This process registers Relay with Sentry so it is ready to send messages. See
144
163
145
164
## Running Relay
146
165
147
-
You can either run the Relay binary directly or using a Docker image.
148
-
149
-
### Running Relay Directly
150
-
151
166
After registering Relay with Sentry, it is ready to run:
152
167
153
168
```shell {tabTitle:Run in Docker}
@@ -167,17 +182,19 @@ Under default configuration, Relay emits log output similar to:
167
182
```
168
183
INFO relay::setup > launching relay from config folder .relay
169
184
INFO relay::setup > relay mode: managed
170
-
INFO relay::setup > relay id: f2119bc9-9a9b-4531-826b-24e9794902f2
171
-
INFO relay::setup > public key: QPBITKKtKUuEZGGbPke8iufEXAcVrEv6nmWrkRtc3l8
185
+
INFO relay::setup > relay id: cde0d72e-0c4e-4550-a934-c1867d8a177c
186
+
INFO relay::setup > public key: nDJI79SbEYH9-8NEJAI7ezrgYfoIPW3Bnkg00k1z0fA
172
187
...
173
188
INFO relay_server::actors::upstream > relay successfully registered with upstream
174
189
```
175
190
191
+
Refer to the [Logging](/product/relay/monitoring/#logging) page for more information on how to configure Relay's logging.
192
+
176
193
If you moved your config folder (for example, for security reasons), use the `--config` option to specify the location:
177
194
178
195
```shell {tabTitle:Run in Docker}
179
196
docker run --rm -it \
180
-
-v $(pwd)/config/:/work/.relay/ \
197
+
-v $(pwd)/config/:/etc/relay/ \
181
198
-p 3000:3000 \
182
199
getsentry/relay \
183
200
run --config /etc/relay/
@@ -187,66 +204,41 @@ docker run --rm -it \
187
204
./relay run --config /etc/relay/
188
205
```
189
206
190
-
## Logging
191
-
192
-
Once Relay is running, you will receive `INFO` messages, such as:
193
-
194
-
```
195
-
INFO relay::setup > launching relay from config folder .relay
196
-
INFO relay::setup > relay mode: managed
197
-
INFO relay::setup > relay id: f2119bc9-9a9b-4531-826b-24e9794902f2
198
-
INFO relay::setup > log level: INFO
199
-
```
200
-
201
-
This example displays the default logging level, which you can modify so it displays either more or less information. For details about configuring logging please see [Logging](/product/relay/options/#logging) on the options page.
202
-
203
-
## Health Checks
204
-
205
-
Relay provides two URLs for checking system status:
206
-
207
-
- `GET /api/relay/healthcheck/live/`: Tests if Relay is running and listening to
208
-
HTTP requests.
209
-
- `GET /api/relay/healthcheck/ready/`: Tests if Relay is authenticated with the
210
-
upstream and operating normally.
211
-
212
-
In case of success, both endpoints return a _200 OK_ response:
213
-
214
-
```json
215
-
{
216
-
"is_healthy": true
217
-
}
218
-
```
219
-
220
207
## Sending a Test Event
221
208
222
-
Once Relay is running and authenticated with Sentry, send a test event.
209
+
Once Relay is running and authenticated with Sentry, send a test event to one of the projects in your organization.
223
210
224
-
Get the DSN of your project by navigating to _Project Settings > Client Keys
225
-
(DSN)_, which looks similar to:
211
+
Get the DSN of your project by navigating to your project settings at _Settings > Projects > {YOUR_PROJECT_NAME} > Client Keys (DSN)_, and select one of the existing DSNs, which looks similar to:
Copy file name to clipboardExpand all lines: src/docs/product/relay/index.mdx
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -10,7 +10,7 @@ Sentry Relay offers enterprise-grade data security by providing a standalone ser
10
10
11
11
Relay is specifically designed to:
12
12
13
-
- Scrub personal information in a central place prior to sending it to Sentry, adding to the places Sentry already scrubs PII
13
+
- Scrub personally identifiable information (PII) in a central place prior to sending it to Sentry
14
14
- Improve event response time in regions with low bandwidth or limited connectivity
15
15
- Act as an opaque proxy for organizations that restrict all HTTP communication to a custom domain name
16
16
@@ -63,6 +63,6 @@ Relay responds very quickly to requests. Installing Relay close to your infrastr
63
63
64
64
By default, SDKs need to be configured with a Data Source Name (DSN) that points to `sentry.io`. If you need to restrict all HTTP communication to a custom domain name, Relay can act as an opaque proxy that reliably forwards events to Sentry.
description: "Configure logging, metrics, and error reporting for your Relay installation."
4
+
sidebar_order: 3
5
+
redirect_from:
6
+
- /meta/relay/logging/
7
+
---
8
+
## Logging
9
+
10
+
Relay produces logs to the standard error stream (`stderr`), with `INFO` logging level by default.
11
+
For example, after starting Relay you may see output such as this:
12
+
13
+
```
14
+
INFO relay::setup > launching relay from config folder .relay
15
+
INFO relay::setup > relay mode: managed
16
+
INFO relay::setup > relay id: cde0d72e-0c4e-4550-a934-c1867d8a177c
17
+
INFO relay::setup > log level: INFO
18
+
```
19
+
20
+
This example displays the messages with the default logging level (`INFO`), which you can modify so it displays either more or less information. For details about configuring logging please see the [Logging](/product/relay/options/#logging) section on the options page.
21
+
22
+
## Error Reporting
23
+
24
+
By default, Relay logs errors to the configured logger. You can enable error
25
+
reporting to your project in Sentry in the Relay configuration file:
26
+
27
+
```yaml
28
+
sentry:
29
+
enabled: true
30
+
dsn: <your_dsn>
31
+
```
32
+
33
+
More information about available options and their meaning can be found [on the options page](/product/relay/options/#internal-error-reporting).
34
+
35
+
## Health Checks
36
+
37
+
Relay provides two URLs for checking system status:
38
+
39
+
- `GET /api/relay/healthcheck/live/`: Tests if Relay is running and listening to
40
+
HTTP requests.
41
+
- `GET /api/relay/healthcheck/ready/`: Tests if Relay is authenticated with the
42
+
upstream and operating normally.
43
+
44
+
Both endpoints return a _200 OK_ response when successful:
45
+
46
+
```json
47
+
{
48
+
"is_healthy": true
49
+
}
50
+
```
51
+
52
+
## Metrics
53
+
54
+
You can submit stats to a StatsD server by configuring the `metrics.statsd` key to an `ip:port` tuple.
55
+
can be set to an `ip:port` tuple.
56
+
57
+
### Example Configuration
58
+
59
+
```yaml
60
+
metrics:
61
+
# Endpoint of your StatsD server
62
+
statsd: 127.0.0.1:8126
63
+
# Prefix all metric names with this string
64
+
prefix: mycompany.relay
65
+
```
66
+
67
+
The options for configuring metrics reporting are documented on the [options page](/product/relay/options/#statsd-metrics).
0 commit comments