Skip to content

Isolate metrics lifecycles between plugin owners - #126

Draft
BenCodez wants to merge 1 commit into
mainfrom
cez/metrics-owner-lifecycle
Draft

BenCodez wants to merge 1 commit into
mainfrom
cez/metrics-owner-lifecycle

Conversation

@BenCodez

Copy link
Copy Markdown
Owner

Disabling one plugin previously shut down the static metrics scheduler shared by other owners and could prevent later initialization. Give each metrics instance its own executor, retire only the matching owner on Bukkit disable, and preserve construction before enable and when metrics are opted out. Reporting intervals, service identifiers and payloads remain unchanged.

Handle rejected platform handoffs, delayed callbacks after retirement and partial initialization without retiring siblings or leaking an idle executor. Adds an explicit MetricsBase.shutdown() for direct consumers.

Validation for commit 01168e12dcf2d9bd0de3d8c5cc8b957d1db4370b:

  • 12 deterministic focused lifecycle and constructor tests passed, including sibling isolation, disable/re-enable, later initialization, rejection and cleanup.
  • JDK 21 Maven package: 479 ordinary cases, zero failures/errors, one optional MQTT skip; three full-artifact checks and one shared-artifact check passed.
  • Full/shared/shared-sources inspected; metrics remains confined to the full artifact. The shared loader linked 60 neutral classes. Whitespace checks passed.
  • Independent source review approved the exact committed source tree, including resolved Bukkit registration and disable-dispatch contracts.

No live Bukkit-family server acceptance was performed. This draft is separate from YAML API and nested configuration changes.

@coderabbitai

coderabbitai Bot commented Nov 18, 2026

Copy link
Copy Markdown

Important

  • Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 3274d99a-35c3-48f5-96a7-8e71c8f3e389
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

This branch has not been deployed

No deployments
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