mirror of
https://github.com/octoleo/syncthing.git
synced 2024-12-22 19:08:58 +00:00
d0ab65a178
Use a global raven.Client because they allocate an http.Client for each, with a separate CA bundle and infinite connection idle time. Infinite connection idle time means that if the client is never used again it will always keep the connection around, not verifying whether it's closed server side or not. This leaks about a megabyte of memory for each client every created. client.Close() doesn't help with this because the http.Client is still around, retained by its own goroutines. The thing with the map is just to retain the API on sendReport, even though there will in practice only ever be one DSN per process instance... |
||
---|---|---|
.. | ||
_testdata | ||
sentry_test.go | ||
sentry.go | ||
sourcecodeloader.go | ||
stcrashreceiver.go |