Use full method signature for sampling instead of just the method name
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 3.3k
- Forks
- 334
- PR merge metrics
- No merged PRs in 30d
Description
Is your feature request related to a problem? Please describe.
Sampling does not include method parameters. Instead, all calls to methods with the same name are aggregated as calls with parameters ().
Describe the solution you'd like
Sampling should behave like profiling with respect to tracking method calls. If that is too computational expensive in general, there should be an option to activate it (maybe limited to certain packages with the possibility of a ** wildcard).
Describe alternatives you've considered
Alternative solutions:
- renaming all methods: not feasible in a large project
- using profiling: might slow down the execution too much
Additional context
Analyzing a very simple class (see source code below):
| Sampling | Profiling |
|---|---|
![]() |
![]() |
package com;
import java.io.*;
final class VisualvmExperiment
{
public static void main(String[] args) throws InterruptedException, IOException
{
System.out.println("press enter");
System.in.read();
System.out.println("running ...");
call(0);
System.out.println("done");
}
private static void call(int i) throws InterruptedException
{
Thread.sleep(200);
call(++i, false);
if (i < 4)
call(++i);
}
private static void call(int i, boolean b) throws InterruptedException
{
if (i > 10)
return;
Thread.sleep(200);
call(++i);
}
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the sampling-versus-profiling behavior described in the issue and reproduce it using the VisualvmExperiment example, especially the overloaded call methods. Define done as sampling distinguishing calls by their full method signatures, or document a scoped opt-in if the general approach is too expensive; the issue does not name implementation files or tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- performance
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100

