Skip to content

Commit

Permalink
Fix goroutine leak and close Computation.Event computation finishes (#15
Browse files Browse the repository at this point in the history
)
  • Loading branch information
pellared authored Apr 24, 2024
1 parent 5c81948 commit 1be78a9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/).
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## Unreleased

### Fixed

- Fix a goroutine leak and close the channel returned by `Computation.Events` when the computation finishes.
[(#15)](https://github.com/signalfx/signalflow-client-go/pull/15)
1 change: 1 addition & 0 deletions signalflow/computation.go
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,7 @@ func (c *Computation) shutdown() {
close(c.dataChBuffer)
close(c.expirationChBuffer)
close(c.infoChBuffer)
close(c.eventChBuffer)
}

var ErrMetadataTimeout = errors.New("metadata value did not come in time")
Expand Down

0 comments on commit 1be78a9

Please sign in to comment.