Skip to content

Commit dd6ff6d

Browse files
authored
Ensure workflow task only includes events that it should
1 parent 3ea57c8 commit dd6ff6d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

backend/redis/workflow.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ func (rb *redisBackend) GetWorkflowTask(ctx context.Context) (*task.Workflow, er
9898
// New Events
9999
newEvents := make([]history.Event, 0)
100100

101-
msgs, err = rb.rdb.XRange(ctx, pendingEventsKey(instanceTask.ID), "-", "+").Result()
101+
msgs, err = rb.rdb.XRange(ctx, pendingEventsKey(instanceTask.ID), "-", instanceTask.Data.LastPendingEventMessageID).Result()
102102
if err != nil {
103103
return nil, errors.Wrap(err, "could not read event stream")
104104
}

0 commit comments

Comments
 (0)