Skip to content

perf(scheduler): cache immutable dispatch plans#116

Merged
Arbousier1 merged 1 commit into
devfrom
codex/perf-scheduler-dispatch-plan
Jul 19, 2026
Merged

perf(scheduler): cache immutable dispatch plans#116
Arbousier1 merged 1 commit into
devfrom
codex/perf-scheduler-dispatch-plan

Conversation

@Arbousier1

Copy link
Copy Markdown
Collaborator

Summary

  • cache immutable global, region, and entity scheduler dispatch plans by runtime class
  • use fixed-arity Sparrow invokers and flatten Paper fallbacks without weakening identity-safe concurrent routing
  • cache Bukkit scheduler fallbacks by server identity and add mixed-capability, invalidation, concurrency, and no-double-scheduling coverage

Test plan

  • ./gradlew test --tests 'top.ellan.mahjong.runtime.ServerScheduler*' -PmahjongJavaToolchain=25 -PmahjongJavaTarget=21
  • ./gradlew spotlessCheck check assemble -PmahjongJavaToolchain=25 -PmahjongJavaTarget=21 -PmahjongRequireNative=true
  • Local scheduler JMH: Folia 14.132 -> 4.182 ns/op (-70.4%), Paper 5.199 -> 4.099 ns/op (-21.2%), allocation stable at ~16 B/op

Avoid repeated reflection lookups and flatten scheduler fallbacks while preserving identity-safe concurrent routing.
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@Arbousier1 Arbousier1 added performance-ab Run the base-owned paired performance gate performance-scheduler-reflection Use the scheduler reflection performance profile labels Jul 19, 2026
@Arbousier1
Arbousier1 merged commit 8d65030 into dev Jul 19, 2026
23 of 26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

performance-ab Run the base-owned paired performance gate performance-scheduler-reflection Use the scheduler reflection performance profile

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant