Skip to content

fix: ensure goroutines never leak in Suspense example#1374

Open
scrhartley wants to merge 1 commit into
a-h:mainfrom
scrhartley:issue_1352
Open

fix: ensure goroutines never leak in Suspense example#1374
scrhartley wants to merge 1 commit into
a-h:mainfrom
scrhartley:issue_1352

Conversation

@scrhartley
Copy link
Copy Markdown
Contributor

Fixes #1352.

In the Suspense example, use a buffered channel to avoid relying on the template consuming the channel for the goroutines to finish.

The alternative to this fix would be to use a done channel.

Note: this post on the official Go blog is a good resource in this area.

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

Successfully merging this pull request may close these issues.

Unbuffered channel in Suspense example could leak goroutines

1 participant