turnfor
Turnfor is a coordination primitive discussed in the context of concurrent programming and task orchestration. It describes a mechanism in which control is handed from the currently running task to the next ready task in a predefined order, with the system “turning” execution forward after each defined interval. The concept emphasizes predictable advancement of tasks and aims to prevent starvation by ensuring every eligible task receives a turn.
Etymology and concept. The name turnfor is a portmanteau of “turn” and “forwarding.” In turnfor-based designs,
Usage and variants. Turnfor can be implemented in asynchronous runtimes, coroutines, or microservice orchestration layers. Variants
Relation to related concepts. Turnfor is related to round-robin scheduling, yield-based cooperative multitasking, and preemptive multitasking.
See also. Concurrency, Scheduling, Cooperative multitasking, Round-robin, Task orchestration.