sentry-dotnet icon indicating copy to clipboard operation
sentry-dotnet copied to clipboard

Support event caching for Blazor WebAssembly

Open mdemler opened this issue 1 year ago • 2 comments

Problem Statement

General .NET implementations of Sentry support a CacheDirectoryPath option for enabling caching of events, should there be an interruption in Internet connectivity. A Blazor WebAssembly application can successfully run during an Internet outage. The existing option doesn't and can't work, since WebAssembly applications have limited access to the local file system. But, there are other options for caching events locally that Sentry could be taking advantage of.

Solution Brainstorm

  • Abstract the underlying storage mechanism used for caching and provide a mechanism for integrators to be able to define their own implementation. This actually solves this and other needs, as it would allow integrators to override the basic implementation, to target a database, for instance.
  • Provide an implementation behind an option that utilizes local storage for persisting events that need to be submitted to the server.

mdemler avatar Apr 05 '23 15:04 mdemler