From 24ec8b297ccfaf3c8a5f56ac55ef820f3952c188 Mon Sep 17 00:00:00 2001 From: luke-lombardi <33990301+luke-lombardi@users.noreply.github.com> Date: Sun, 6 Oct 2024 13:41:12 -0400 Subject: [PATCH] remove inflight cancellation --- pkg/abstractions/endpoint/buffer.go | 8 -------- 1 file changed, 8 deletions(-) diff --git a/pkg/abstractions/endpoint/buffer.go b/pkg/abstractions/endpoint/buffer.go index 0fe2583ae..10f6072c6 100644 --- a/pkg/abstractions/endpoint/buffer.go +++ b/pkg/abstractions/endpoint/buffer.go @@ -110,7 +110,6 @@ func (rb *RequestBuffer) ForwardRequest(ctx echo.Context, task *EndpointTask) er return nil case <-done: return nil - case <-time.After(requestProcessingInterval): } } } @@ -478,14 +477,7 @@ func (rb *RequestBuffer) heartBeat(req request, containerId string) { rb.rdb.Set(rb.ctx, Keys.endpointRequestHeartbeat(rb.workspace.Name, rb.stubId, req.task.msg.TaskId), containerId, endpointRequestHeartbeatInterval) for { select { - case <-req.done: - return case <-ctx.Done(): - if err := req.ctx.Request().Context().Err(); err == context.Canceled { - rb.cancelInFlightTask(req.task) - return - } - return case <-ticker.C: rb.rdb.Set(rb.ctx, Keys.endpointRequestHeartbeat(rb.workspace.Name, rb.stubId, req.task.msg.TaskId), containerId, endpointRequestHeartbeatInterval)