Quantcast
Channel: Active questions tagged blazor - Stack Overflow
Viewing all articles
Browse latest Browse all 4839

Blazor Connection Disconnected

$
0
0

I have a web app with Client running on Blazor Server. I have set a custom Blazor reconnect modal (<div id="components-reconnect-modal"...) as the documentation says here - Microsoft Docs

Also I have these settings for SignalR and Blazor circuits:

    services.AddServerSideBlazor        (options =>        {            options.DisconnectedCircuitMaxRetained = 100;            options.DisconnectedCircuitRetentionPeriod = TimeSpan.FromMinutes(5);            options.JSInteropDefaultCallTimeout = TimeSpan.FromMinutes(1);            options.MaxBufferedUnacknowledgedRenderBatches = 10;        })        .AddHubOptions(options =>        {            options.ClientTimeoutInterval = TimeSpan.FromSeconds(30);            options.EnableDetailedErrors = false;            options.HandshakeTimeout = TimeSpan.FromSeconds(15);            options.KeepAliveInterval = TimeSpan.FromSeconds(15);            options.MaximumReceiveMessageSize = 32 * 1024;            options.StreamBufferCapacity = 10;        });

But I have an annoying problem - Whenever the app is open in a browser tab and stays still with nobody using it it disconnects. It happens very inconsistently and I can't locate the configuration for these custom time periods but I need to enlarge them. Example:

  1. Initialy loaded the app at 11:34:24AM
  2. Leave it like that for a while
  3. In the Console: "Information: Connection disconnected." at 11:55:48AM and my reconnect-modal appears.

How can I enlarge the lifetime of the connection so that it is always bigger than my session timeout. I checked the Private Memory Limit of my app pool but it is unlimited. It happens really inconsistently with the same steps to reproduce. Test 1 - 16 mins 20 sec; Test 2 - 21 mins 58 sec; Test 3 - 34 mins 56 sec...and then after iisreset...Test 4 - 6 mins 28 sec

Please help.


Viewing all articles
Browse latest Browse all 4839

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>