Skip to content

Plugins can no longer create new Metrics Categories #7818

@jflo

Description

@jflo

Steps to Reproduce (Bug)

  1. Create a new plugin, which adds its own instance of MetricCategory to the MetricsCategoryRegistry service that is provided in the BesuContext at plugin registry time. Give it a unique name.
  2. Deploy the plugin to any instance of Besu.
  3. Startup the instance, with your new metrics category specified in the list of --metrics-categories to collect data on.

Expected behavior: new metrics are produced under the new category.

Actual behavior: Startup fails, because there is no MetricCategoryConverter for the string provided as an option to --metrics-categories. Plugin registration happens AFTER those converters are setup and used to parse the supplied --metrics-categories options.

Frequency: always

Logs (if a bug)

Please post relevant logs from Besu (and the consensus client, if running proof of stake) from before and after the issue.

Versions (Add all that apply)

  • Software version: 24.10.0+
  • Java version: 21

Metadata

Metadata

Assignees

Labels

P2High (ex: Degrading performance issues, unexpected behavior of core features (DevP2P, syncing, etc))bugSomething isn't working

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions