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

Investigate and resolve blazor load error #3589

Closed
pbiggar opened this issue Mar 17, 2022 · 10 comments
Closed

Investigate and resolve blazor load error #3589

pbiggar opened this issue Mar 17, 2022 · 10 comments
Assignees

Comments

@pbiggar
Copy link
Member

pbiggar commented Mar 17, 2022

When loading blazor, many of the files it needs will not load in the browser. The browser stops being able to make a connection to the server. This only happens in production. It is most commonly reproduced by loading and then doing another load from a clean cache.

I managed to reproduce the error:

Uncaught exception Blazor worker failure TypeError: Failed to fetch
    at loadResource (blob:https://darklang.com/dacea6f8-981c-4a6a-9522-f78faeed6aeb:738:24)
    at blob:https://darklang.com/dacea6f8-981c-4a6a-9522-f78faeed6aeb:732:11
    at Array.map (<anonymous>)
    at Object.loadResources (blob:https://darklang.com/dacea6f8-981c-4a6a-9522-f78faeed6aeb:731:39)
    at createEmscriptenModuleInstance (blob:https://darklang.com/dacea6f8-981c-4a6a-9522-f78faeed6aeb:220:52)
    at blob:https://darklang.com/dacea6f8-981c-4a6a-9522-f78faeed6aeb:772:25 undefined undefined undefined
e.<computed> @ appsupport-0aab008024f907c251bfe9927856eeebed075655f5139be469f7af1ceaf66459.js:179373

image

And it seems to happen when part of the load time's out:

image

Unclear why these loads time out, but this happens in about 1/4 of the times I refresh.

Originally posted by @pbiggar in #3254 (comment)

@pbiggar pbiggar self-assigned this Mar 17, 2022
@pbiggar
Copy link
Member Author

pbiggar commented Mar 22, 2022

Some investigation:

  • I can trigger this by loading once, and then clicking "Empty cache and hard reload"
  • the error in Chrome is ERR_CONNECTION_CLOSED. The files being loaded are "pending" for 30 seconds, and then error/timeout
  • if one fails, typically 50 others do as well
  • it is not always the same files that fail to load each time, though it often is
  • ordering matters: the first ~40 all succeed, then progressively more likely to fail, then the last ~30 all fail
  • taking the failing urls and fetching them via curl succeeds
  • the items being requested are uploaded to the bucket and configured properly
  • no observable differences between things that succeed and things that fail, at the bucket level
  • the load balancer does not have any logs for these requests
  • all requests (success and failure) to the static assets load balancer are "h3" (http3)
  • there is no consistency to the name, url length, content-type, or file extension of the files that fail and succeed
  • this happens with all extensions disabled in incognito mode

ERR_CONNECTION_CLOSED means it wasn't able to make a connection:

  • chrome has a connection limit?
  • ddos protection at google?
  • my os/router/isp/other doesn't like that many connections of that size/content-type/etc?
  • a chrome extension is preventing this from working? tested

@pbiggar
Copy link
Member Author

pbiggar commented Mar 22, 2022

I don't have any clues here so I'll see who I can ask.

@pbiggar
Copy link
Member Author

pbiggar commented Mar 22, 2022

Using correct content-types didn't change anything.

@pbiggar
Copy link
Member Author

pbiggar commented Mar 22, 2022

  • ask blazor people about it
  • ask google cloud support about it
  • try a different browser

@pbiggar
Copy link
Member Author

pbiggar commented Mar 23, 2022

Google cloud says it's not them.

@StachuDotNet
Copy link
Member

Given I could eventually replicate this on my laptop, maybe we should figure out what's consistent between my laptop and your computer, and not consistent with my desktop where I can't replicate.

Both my desktop and laptop are Ubuntu with Chrome on WiFi. The initial differences that come to mind would be drivers, chrome versions, extensions loaded, internet config settings, Ubuntu versions (desktop is 21.10 - maybe laptop is 21.04?) or underlying linux versions.

What variables would be worth looking at, if that seems a useful path?

@pbiggar
Copy link
Member Author

pbiggar commented Mar 23, 2022

You're not going to believe this but I just upgraded to Chrome 99 and I can't replicate this anymore!

@StachuDotNet
Copy link
Member

You're not going to believe this but I just upgraded to Chrome 99 and I can't replicate this anymore!

LOL that's amazing. Not sure how to feel about this. I guess we're OK? Would love to find the issue in their tracker.

@pbiggar
Copy link
Member Author

pbiggar commented Mar 23, 2022

@pbiggar
Copy link
Member Author

pbiggar commented Mar 23, 2022

I upgraded from Chrome 97 to Chrome 99 which includes that fix.

@pbiggar pbiggar closed this as completed Mar 23, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants