bloomberg / bloomberg/quantum

Spurious calls of task state handler in sequencer

Open
#163 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
639
Forks
108
PR merge metrics
No merged PRs in 30d

Description

**Describe the bug**
When I enqueued a single task with sequencer and checked a number of times the task state handler processed `Started` state, I noticed that it was called for all coroutine threads in case of "old" Sequencer and 2 times for experimental Sequencer.

**To Reproduce**
Steps to reproduce the behavior:
1. Create a [handler](https://github.com/bloomberg/quantum/blob/master/tests/quantum_task_state_handler_tests.cpp#L90) with atomic counters and setup it to the configuration
2. Create dispatcher and sequencer with a simple integer key
3. Enqueue a simple task
4. Check counters

**Expected behavior**
Task state handler must be called only on a thread to which the task is assigned to

**Environment (please complete the following information):**
- Ubuntu Linux 20.04

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.