Commit b5d2cb6
authored
Structured Logging (Service Project) (#1666)
## Why make this change?
- Adds structured logging to the Core project per #1517
## What is this change?
- In instances of ilogger usage, removes interpolated strings and uses
structured logging paradigm:
- in the `message` parameter, names in curly brackets are names that can
be filtered in a log view such as app insights/log analytics. The
parameters after message are the variables which supply the values for
the names in curly brackets.
```csharp
_logger.LogDebug(
message: "{correlationId} Request authentication state:
{requestAuthStatus}.",
HttpContextExtensions.GetLoggerCorrelationId(httpContext),
requestAuthStatus);
```
## testing
Testing is manual via analyzing the console, no logic changes were made to the engine.1 parent f8373b8 commit b5d2cb6
3 files changed
Lines changed: 35 additions & 19 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
8 | 9 | | |
9 | 10 | | |
10 | 11 | | |
| |||
53 | 54 | | |
54 | 55 | | |
55 | 56 | | |
56 | | - | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
57 | 60 | | |
58 | 61 | | |
59 | 62 | | |
60 | 63 | | |
61 | | - | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
62 | 68 | | |
63 | 69 | | |
64 | 70 | | |
| |||
92 | 98 | | |
93 | 99 | | |
94 | 100 | | |
95 | | - | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
96 | 104 | | |
97 | 105 | | |
98 | 106 | | |
99 | 107 | | |
100 | | - | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
101 | 112 | | |
102 | 113 | | |
103 | 114 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
246 | 246 | | |
247 | 247 | | |
248 | 248 | | |
249 | | - | |
250 | | - | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
251 | 254 | | |
252 | 255 | | |
253 | 256 | | |
254 | 257 | | |
255 | 258 | | |
256 | | - | |
257 | | - | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
258 | 264 | | |
259 | 265 | | |
260 | 266 | | |
| |||
277 | 283 | | |
278 | 284 | | |
279 | 285 | | |
280 | | - | |
281 | | - | |
282 | | - | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
283 | 290 | | |
284 | 291 | | |
285 | 292 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
255 | 255 | | |
256 | 256 | | |
257 | 257 | | |
258 | | - | |
259 | | - | |
| 258 | + | |
260 | 259 | | |
261 | 260 | | |
262 | 261 | | |
263 | 262 | | |
264 | 263 | | |
265 | | - | |
266 | | - | |
| 264 | + | |
267 | 265 | | |
268 | 266 | | |
269 | 267 | | |
| |||
592 | 590 | | |
593 | 591 | | |
594 | 592 | | |
595 | | - | |
| 593 | + | |
596 | 594 | | |
597 | 595 | | |
598 | 596 | | |
| |||
614 | 612 | | |
615 | 613 | | |
616 | 614 | | |
617 | | - | |
| 615 | + | |
618 | 616 | | |
619 | 617 | | |
620 | | - | |
| 618 | + | |
621 | 619 | | |
622 | 620 | | |
623 | 621 | | |
624 | 622 | | |
625 | | - | |
| 623 | + | |
626 | 624 | | |
627 | 625 | | |
628 | 626 | | |
| |||
0 commit comments