Skip to content

docs: correct the Dispatchers.IO and publishing claims - #28

Merged
youndie merged 1 commit into
mainfrom
docs/dispatchers-io-and-publishing
Oct 2, 2026
Merged

youndie merged 1 commit into
mainfrom
docs/dispatchers-io-and-publishing

Conversation

@youndie

@youndie youndie commented Oct 2, 2026

Copy link
Copy Markdown
Owner

Corrects two statements in the documentation. No code changes; one comment in publish.yml is updated.

Dispatchers.IO exists on Kotlin/Native

Research §1.8 said Dispatchers.IO is internal on Kotlin/Native. The member really is internal. The public Dispatchers.IO on Native is an extension property in kotlinx.coroutines, and without import kotlinx.coroutines.IO the compiler picks the member and reports "it is internal".

Evidence (macosArm64, Kotlin/Native 2.4.20, coroutines 1.11.0):

  • klib dump-metadata of kotlinx-coroutines-core-macosArm64Main-1.11.0, the artefact §1.8 quoted, shows both declarations:
    internal final val IO: kotlinx/coroutines/CoroutineDispatcher
    public final val kotlinx/coroutines/Dispatchers.IO: kotlinx/coroutines/CoroutineDispatcher
    
  • One file, compiled two ways. Without the import: cannot access 'val IO: CoroutineDispatcher': it is internal in 'kotlinx.coroutines.Dispatchers'. With the import it compiles, and withContext(Dispatchers.IO) runs on DefaultIoScheduler.
  • kore B-42 found the same independently on linuxX64 and macosArm64, and measured that Native's IO dispatcher is elastic.

The research keeps the original text, adds a dated correction, and fixes the §1.4 row that had been struck out wrongly. CLAUDE.md, the README, feature-crud-mvp, mongkn-core and the M2 summary now say the corrected thing.

The design decision. MongoClient owns its thread pool, and the only reason ever recorded was this claim. Since then the pool's size has gained measured reasons (M-78, M-85), but nobody has weighed it against Dispatchers.IO.limitedParallelism(n). M-92 opens that question, with the arguments on both sides and the acceptance criteria. Code and KDoc (MongoClient.dispatcher, CollectionOps) are left for M-92, because the KDoc explains the design that M-92 will decide.

Publishing, as it works now

CLAUDE.md still described publishing.gradle.kts, which 3f6196c removed. It now describes the current setup:

  • io.github.youndie.sborka.publish declares the wip repository and builds the POM; sborka.base sets the group.
  • The convention reads REPOSILITE_USER / REPOSILITE_SECRET, which CI fills from the MONGKN_REPO_* secrets.
  • The address is overridden with sborka.snapshotRepository. MONGKN_REPO_URL is read only by the verification step, not by the upload. That secret is not set today; if someone sets it, verification will check a different place than the one the artefact went to. The publish.yml comment that pointed at the removed file now says this too.
  • The runner label is no longer copied into the prose. It lives in publish.yml, which says ubuntu-26.04 while the text still said 24.04.

Research 1.8 recorded Dispatchers.IO as internal on Kotlin/Native. The
member is internal; the public Dispatchers.IO there is an extension
property, and without `import kotlinx.coroutines.IO` the compiler finds
the member and says "it is internal". The same klib dump that was quoted
shows both declarations, and a probe compiled and ran with the import on
macosArm64; kore B-42 established the same on linuxX64 and measured the
native IO dispatcher as elastic. The research keeps the old text with a
dated correction; CLAUDE.md, the README, the feature and service
documents say the corrected thing.

The client's own thread pool was justified by that claim alone. Its size
has measured reasons since (M-78, M-85), but nobody weighed it against
Dispatchers.IO.limitedParallelism, so M-92 opens that question. No code
changes here.

CLAUDE.md still described publishing.gradle.kts, removed in 3f6196c. It
now says what publishes today: sborka.publish's wip repository, its
REPOSILITE_* properties fed from the MONGKN_REPO_* secrets, and that
MONGKN_REPO_URL moves only the verification step, not the upload.
@youndie
youndie merged commit 582199f into main Oct 2, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant