Preliminary. ThinkMeta ConcurrentTasks and this documentation are preliminary; everything is subject to change.

API reference / Async I/O

OrderedFileWriterSettings struct

How an OrderedFileWriter writes: granule, writes at once, copy queue sizes.

Use
import ThinkMeta.ConcurrentTasks.AsyncIo.OrderedFileWriter;
Namespace
ThinkMeta::ConcurrentTasks::AsyncIo

Syntax

Remarks

OrderedFileWriter::Open corrects out-of-range values instead of failing: segmentSize is raised to at least 64 KB and rounded up to a multiple of 64 KB, writesInFlight is clamped to 1..OrderedFileWriter::MaxWritesInFlight, batchRing and jobRing are raised to at least 2.

Fields

segmentSize

Bytes per write; memory is committed and decommitted in the same unit.

Syntax

std::uint64_t segmentSize = std::uint64_t{4} << 20;

writesInFlight

Overlapped writes the writer task keeps in flight.

Syntax

std::uint32_t writesInFlight = 4;

batchRing

Batches submitted to the copy tasks and not yet retired.

Syntax

std::uint32_t batchRing = 256;

Remarks

The producer waits (and helps) when the ring is full.

jobRing

OrderedFileWriter::WriteDeferred copies not yet retired.

Syntax

std::uint32_t jobRing = 65536;

Remarks

A batch is split at half of it; the producer waits when the ring is full.

unbuffered

Open the file with FILE_FLAG_NO_BUFFERING.

Syntax

bool unbuffered = false;

Remarks

The last write is padded to whole sectors and OrderedFileWriter::Close sets the exact size.

Generated from ThinkMeta.ConcurrentTasks.API @ 137ec1d (2026-10-17).