Thread Tagging for On-Demand Java Memory Profiling
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Conventional profiling tools for Java-based systems are limited in detecting memory leaks and system inefficiencies, often requiring significant system resources, causing performance issues and disrupting user sessions due to high memory consumption and the need for VM restarts, which is not suitable for large-scale applications.
Innovation Solution
An on-demand profiling infrastructure is provided that allows for customizing allocation statistics by tagging threads, enabling profiling without restarting the VM, using a proprietary interface integrated within the JVM, which provides real-time monitoring and debugging capabilities without additional memory overhead.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Difficulty of detecting and measuring
If conventional profiling tools are used to detect memory leaks and system inefficiencies, then detection capability is improved, but system resource consumption increases and user sessions are disrupted
Solution Approach 1:
The invention segments the profiling functionality by introducing a tagging mechanism that allows selective profiling of specific threads or code sections. Instead of profiling the entire system, only tagged portions are monitored, reducing overall resource consumption while maintaining detection capability for critical areas.
Solution Approach 2:
The profiling system applies local quality by enabling customized allocation statistics for specific tagged threads or code sections rather than uniformly profiling all system activities. This allows concentrated monitoring resources to be applied where memory leaks are most likely to occur, improving detection efficiency while minimizing system-wide overhead.
2Difficulty of detecting and measuring
If conventional profiling tools are used to detect memory leaks, then detection capability is improved, but system stability deteriorates due to VM restarts
Solution Approach 1:
The invention applies preliminary action by tagging threads or code sections before profiling begins. This pre-tagging allows the system to prepare monitoring targets in advance without interrupting execution, enabling seamless integration of profiling into ongoing operations and eliminating the need for VM restarts.
Solution Approach 2:
The profiling mechanism maintains continuity of useful action by enabling memory leak detection during live system operation. The tagging approach allows profiling to continue uninterrupted alongside normal application execution, ensuring system stability while maintaining detection capability throughout the profiling session.
3Measurement precision
If comprehensive allocation statistics are collected for all threads, then detection accuracy is improved, but processing time increases
Solution Approach 1:
The invention applies partial action by collecting allocation statistics only for tagged threads or code sections rather than all system threads. This selective approach maintains measurement precision for critical areas while significantly reducing the total volume of data to be processed, thereby decreasing profiling processing time.
Data Source
AI summary
A system and method are provided to customize allocation statistics. In one embodiment, a tag is associated to one or more threads to receive allocation statistic information relating to the one or more tagged threads, the one or more threads are tagged prior to performing an allocation statistic session. The allocation statistic session is performed via a plurality of threads at a first virtual machine at a server. A plurality of threads performing the allocation statistic session includes the one or more tagged threads is determined. The allocation statistic information relating to the one or more tagged threads is extracted, if the plurality of threads includes the one or more tagged threads.


