dotCMS / dotCMS/core

Expose mimalloc metrics in Micrometer implementation

Open
#33,041 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

dotCMS : Containerization dotCMS : Metrics Priority : 3 Average stale Team : Platform
Dominant language
Java
Stars
970
Forks
486
Avg merge
3d 33m
Merged PRs (30d)
170

Description

Description

Integrate mimalloc memory allocator metrics into the existing Micrometer metrics implementation to provide detailed memory allocation insights.

Background

mimalloc is a high-performance memory allocator that provides detailed metrics about memory allocation patterns, fragmentation, and performance. Exposing these metrics through our Micrometer implementation would provide valuable insights for memory optimization and leak detection.

Requirements

  1. mimalloc Integration: Detect when mimalloc is being used as the memory allocator
  2. Metric Exposure: Expose key mimalloc metrics through Micrometer
  3. Performance Consideration: Ensure minimal overhead when collecting metrics
  4. Documentation: Provide configuration and usage documentation

Acceptance Criteria

  • Detect mimalloc availability and usage at runtime
  • Expose core mimalloc metrics (heap usage, fragmentation, allocation stats)
  • Integrate with existing Micrometer metric collection
  • Add configuration options for metric collection frequency
  • Maintain compatibility with other memory allocators (graceful fallback)
  • Include metric labels for easy filtering and analysis
  • Add comprehensive documentation for setup and usage

Technical Considerations

  • Native integration with mimalloc statistics API
  • JNI bindings or native library integration
  • Conditional compilation/loading based on mimalloc availability
  • Integration with containerized environments

Acceptance Criteria

  • [Define what needs to be accomplished]

Additional Notes

[Any additional context or notes]

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the existing Micrometer metrics implementation and reviewing how it collects metrics. Then investigate mimalloc's statistics API and the proposed JNI or native-library loading approach, including allocator fallback behavior. Done means defining the metrics, configuration, labels, compatibility behavior, and documentation; the issue does not name specific files or tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
observability
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.