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
on a simple Blazor Server .NET 7 project for example, if I store a 25kb value, I can't read it back
Expected Behavior
No response
Steps To Reproduce
Create a new projet Blazor Server .NET 7 and paste this on Index.razor :
@page "/"
@inject ProtectedSessionStorage sessionStorage
<button @onclick="ReadSave">Test</button>
@avatar
@code {
string avatar;
private async Task ReadSave()
{
// Create a long string
int max = 24445; // ok with 24445
// change to 24446 it stop when reading
System.Text.StringBuilder sb = new(max);
for (int i = 0; i < max; i++)
{
sb.Append('a');
}
avatar = sb.ToString();
// save
await sessionStorage.SetAsync("avatar", avatar);
// load it
var data = await sessionStorage.GetAsync<string>("avatar");
if (data.Success)
{
avatar = data.Value;
}
}
}
I tested and found that if I save a string larger than 24445, the program freezes when reading the session variable
Exceptions (if any)
No response
.NET Version
7
Anything else?
No response
The text was updated successfully, but these errors were encountered:
Is there an existing issue for this?
Describe the bug
on a simple Blazor Server .NET 7 project for example, if I store a 25kb value, I can't read it back
Expected Behavior
No response
Steps To Reproduce
Create a new projet Blazor Server .NET 7 and paste this on Index.razor :
I tested and found that if I save a string larger than 24445, the program freezes when reading the session variable
Exceptions (if any)
No response
.NET Version
7
Anything else?
No response
The text was updated successfully, but these errors were encountered: