Skip to content

go: prevent concurrent reads or writes on the same stream or future #1460

@dicej

Description

@dicej

There's currently nothing in the code generated for Go to prevent the programmer from issuing multiple concurrent reads or writes on the same stream or future, which is currently disallowed by the component model spec and will lead to a trap. We should handle this more gracefully by returning an idiomatic error from {Stream,Future}Writer.Write and {Stream,Future}Reader.Read (or else a panic if we feel this is a programmer error rather than a runtime error).

Metadata

Metadata

Assignees

Labels

gen-goRelated to the Go code generator

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions