Commit 8cdaa9b
committed
Auto merge of #2064 - jtgeibel:prod/interlaced-logs, r=carols10cents
Consolidate logging into a single `println!()`
In production I observed serveral log lines with only " SLOW REQUEST".
Occasionally another thread will obtain the lock on stdout between our
calls to `print!()`.
This implementation consolidates the entire log line into a single
`println!()` and avoids an allocation unless an error is being logged.
r? @smarnach1 file changed
Lines changed: 16 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
36 | 36 | | |
37 | 37 | | |
38 | 38 | | |
39 | | - | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
40 | 52 | | |
41 | 53 | | |
42 | 54 | | |
43 | | - | |
| 55 | + | |
44 | 56 | | |
45 | 57 | | |
46 | 58 | | |
| |||
50 | 62 | | |
51 | 63 | | |
52 | 64 | | |
| 65 | + | |
| 66 | + | |
53 | 67 | | |
54 | 68 | | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | 69 | | |
66 | 70 | | |
67 | 71 | | |
| |||
0 commit comments