package async_kernel

  1. Overview
  2. Docs
Monadic concurrency library

Install

Dune Dependency

Authors

Maintainers

Sources

v0.17.0.tar.gz
sha256=01ced973dbc70535f692f38bed524ae82dba17e26e58791b2fbf0d647b160d2e

doc/async_kernel/Async_kernel/Priority/index.html

Module Async_kernel.PrioritySource

A job's priority determines when in an async cycle the job is run. A "cycle" runs a bounded number of Normal priority jobs followed by a bounded number of Low priority jobs. The bound is Async_kernel_config.max_num_jobs_per_priority_per_cycle.

The primary consequence and use case of Low priority is to improve batching in jobs that flush buffers filled by other, Normal priority jobs.

Neither priority can starve out the other entirely. If there are more Normal priority jobs than can run in a single cycle, then the rest will be delayed until after (some) Low priority jobs run.

Sourcetype t =
  1. | Normal
  2. | Low
Sourceval sexp_of_t : t -> Sexplib0.Sexp.t
include Ppx_enumerate_lib.Enumerable.S with type t := t
Sourceval all : t list
Sourceval normal : t
Sourceval low : t
OCaml

Innovation. Community. Security.