oracle / oracle/visualvm

Freeze when connecting to Java application suspended by debugger

Open
#427 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Java
Stars
3.3k
Forks
334
PR merge metrics
No merged PRs in 30d

Description

Describe the bug
It looks like VisualVM freezes when connecting to a Java application which is currently suspended by a debugger. This seems to occur every time you click on the application in the "Applications" tab on the left.

To Reproduce
Steps to reproduce the behavior:

  1. Start any Java program and suspend it with a debugger
    I used IntelliJ and let the program hit a breakpoint.
  2. In VisualVM in the "Applications" tab on the left, click on the application
    ❌ Notice how VisualVM freezes; once you resume execution of the suspended application, VisualVM becomes responsive again

Expected behavior
VisualVM should not freeze. If it cannot obtain certain information while the target application is suspended, it should properly inform the user if necessary, but should not prevent them from using VisualVM.

VisualVM log
logfile.txt
Does not seem to contain anything relevant; I think in a previous run it logged that it got stuck (also in VirtualMachineImpl.connectPipe I think), but unfortunately I don't have that log file anymore.

Maybe the jstack output while VisualVM is stuck is useful though: jstack.txt

Desktop (please complete the following information):

  • OS: Windows 10
  • JDK version JDK 11.0.13+8
  • Version 2.1.4

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 reviewing the attached jstack.txt and logfile.txt, then inspect the reported VirtualMachineImpl.connectPipe area. Reproduce the freeze by connecting VisualVM to a Java application suspended at a debugger breakpoint. Done means VisualVM remains usable while the target is suspended and recovers appropriately when execution resumes.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.