Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support event caching for Blazor WebAssembly #2291

Open
mdemler opened this issue Apr 5, 2023 · 2 comments
Open

Support event caching for Blazor WebAssembly #2291

mdemler opened this issue Apr 5, 2023 · 2 comments
Labels
Blazor Feature New feature or request

Comments

@mdemler
Copy link

mdemler commented Apr 5, 2023

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.
@mattjohnsonpint mattjohnsonpint self-assigned this Apr 6, 2023
@mattjohnsonpint mattjohnsonpint transferred this issue from getsentry/sentry Apr 6, 2023
@getsentry getsentry deleted a comment from brianthi Apr 6, 2023
@getsentry getsentry deleted a comment from getsantry bot Apr 6, 2023
@getsentry getsentry deleted a comment from getsantry bot Apr 6, 2023
@getsentry getsentry deleted a comment from getsantry bot Apr 6, 2023
@mattjohnsonpint
Copy link
Contributor

@mdemler - Thanks for the feature request. I transferred this from the main Sentry repo, as it is specific to the .NET SDK. Please log .NET SDK issues to this repo (sentry-dotnet) going forward.

The abstraction is a good suggestion. We do actually have some abstraction already around our file system internals, but they are mostly designed for testing purposes at the moment. We can consider a future enhancement to expose an API for this, or perhaps to provide this automatically as a Blazor-specific Sentry package.

Neither are on the immediate plan, but we can keep this issue here to reference in the future.

Thanks.

@mattjohnsonpint
Copy link
Contributor

Related to #2021

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Blazor Feature New feature or request
Projects
Status: No status
Archived in project
Development

No branches or pull requests

3 participants