mirror of
https://github.com/PluralKit/PluralKit.git
synced 2026-02-04 13:06:50 +00:00
feat: add sentry error logging to dotnet-api and rust crates
This commit is contained in:
parent
8266100155
commit
63777bf810
8 changed files with 86 additions and 38 deletions
|
|
@ -14,6 +14,16 @@ public class Program
|
|||
await BuildInfoService.LoadVersion();
|
||||
var host = CreateHostBuilder(args).Build();
|
||||
var config = host.Services.GetRequiredService<CoreConfig>();
|
||||
|
||||
// Initialize Sentry SDK, and make sure it gets dropped at the end
|
||||
using var _ = SentrySdk.Init(opts =>
|
||||
{
|
||||
opts.Dsn = config.SentryUrl ?? "";
|
||||
opts.Release = BuildInfoService.FullVersion;
|
||||
opts.AutoSessionTracking = true;
|
||||
// opts.DisableTaskUnobservedTaskExceptionCapture();
|
||||
});
|
||||
|
||||
await host.Services.GetRequiredService<RedisService>().InitAsync(config);
|
||||
await host.RunAsync();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue