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
Closes#57376Closes#34037
- Adds a lock in `SimpleLogger` and `ConsoleLogger` for use on maxlog
tracking and stream writes to improve threadsafety.
Closely similar to #54497
- Turns the internal `_min_enabled_level` into a `Threads.Atomic`. There
are [some direct
interactions](https://juliahub.com/ui/Search?type=code&q=_min_enabled_level&w=true)
to this internal in the ecosystem, but they should still work
```
julia> Base.CoreLogging._min_enabled_level[] = Logging.Info+1
LogLevel(1)
```
- Brings tests over from #57448
Performance seems highly similar:
### Master
```
julia> @time for i in 1:10000
@info "foo" maxlog=10000000
end
[ Info: foo
...
0.481446 seconds (1.33 M allocations: 89.226 MiB, 0.49% gc time)
```
### This PR
```
0.477235 seconds (1.31 M allocations: 79.002 MiB, 1.77% gc time)
```
0 commit comments