Skip to content

Commit

Permalink
remove sleep
Browse files Browse the repository at this point in the history
  • Loading branch information
chodges15 committed May 21, 2024
1 parent c5dbee1 commit e0f8b81
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
## main / unreleased

* [ENHANCEMENT] Remove hardcoded delay in distributor shutdown [#3687](https://github.com/grafana/tempo/pull/3687) (@chodges15)
* [ENHANCEMENT] Update OTLP and add attributes to instrumentation scope in vParquet4 [#3649](https://github.com/grafana/tempo/pull/3649) (@stoewer)
**Breaking Change** The update to OTLP 1.3.0 removes the deprecated `InstrumentationLibrary`
and `InstrumentationLibrarySpan` from the OTLP receivers
Expand Down
6 changes: 0 additions & 6 deletions modules/distributor/receiver/shim.go
Original file line number Diff line number Diff line change
Expand Up @@ -305,12 +305,6 @@ func (r *receiversShim) starting(ctx context.Context) error {

// Called after distributor is asked to stop via StopAsync.
func (r *receiversShim) stopping(_ error) error {
// when shutdown is called on the receiver it immediately shuts down its connection
// which drops requests on the floor. at this point in the shutdown process
// the readiness handler is already down so we are not receiving any more requests.
// sleep for 30 seconds to here to all pending requests to finish.
time.Sleep(30 * time.Second)

ctx, cancelFn := context.WithTimeout(context.Background(), 30*time.Second)
defer cancelFn()

Expand Down

0 comments on commit e0f8b81

Please sign in to comment.