Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running a quarkus application with debug mode does not suspend the vm #4532

Closed
tmplcl opened this issue Oct 13, 2019 · 6 comments
Closed

Running a quarkus application with debug mode does not suspend the vm #4532

tmplcl opened this issue Oct 13, 2019 · 6 comments
Labels
bug
Milestone

Comments

@tmplcl
Copy link

@tmplcl tmplcl commented Oct 13, 2019

When running a quarkus application with maven and the debug property as described in https://quarkus.io/guides/maven-tooling#debugging the vm does not wait for a debugger to attach.

Expected behavior
The VM should be suspended until a debugger is attached.

Actual behavior
The application starts without suspending the VM.

To Reproduce

  1. Create simple quarkus application:
mvn io.quarkus:quarkus-maven-plugin:0.24.0:create \
    -DprojectGroupId=org.acme \
    -DprojectArtifactId=getting-started \
    -DclassName="org.acme.quickstart.GreetingResource" \
    -Dpath="/hello"
  1. Run the application in dev mode with maven debug property:
./mvnw compile quarkus:dev -Ddebug=true
  1. Check is application is running:
wget localhost:8080/hello

Environment:

  • Output of uname -a or ver:

Linux tmplcl-Virtual-Machine 5.0.0-31-generic #33-Ubuntu SMP Mon Sep 30 18:51:59 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux

  • Output of java -version:

openjdk version "1.8.0_222"
OpenJDK Runtime Environment (build 1.8.0_222-20190711120915.buildslave.jdk8u-src-tar--b08)
OpenJDK 64-Bit GraalVM CE 19.2.0.1 (build 25.222-b08-jvmci-19.2-b02, mixed mode)

  • Quarkus version or git rev: 0.24.0

Additional context
Same behaviour with OpenJDK: 11 and 13

@tmplcl tmplcl added the bug label Oct 13, 2019
@jaikiran

This comment has been minimized.

Copy link
Member

@jaikiran jaikiran commented Oct 13, 2019

This looks like because of hte change I recently did #4395. For now, you can additionally pass -Dsuspend=true to have the VM suspended when -Ddebug=true. I'll submit a PR tomorrow, to have -Ddebug=true behave like it used to before.

@geoand

This comment has been minimized.

Copy link
Contributor

@geoand geoand commented Oct 13, 2019

I am little lost with the change to -Ddebug. It was my understanding that that the fact that it no longer suspends was intentional.
Is that not the case?

@jaikiran

This comment has been minimized.

Copy link
Member

@jaikiran jaikiran commented Oct 13, 2019

When I did that change I was only thinking about the port override and hadnt considered changing the debug=true case. But I think the current behaviour of letting suspend decide whether or not to suspend, I guess, makes it more consistent. We will have to fix our documentation about it.

@geoand

This comment has been minimized.

Copy link
Contributor

@geoand geoand commented Oct 13, 2019

Yes, let's at least have some documentation

@jaikiran

This comment has been minimized.

Copy link
Member

@jaikiran jaikiran commented Oct 16, 2019

Documentation has now been updated #4596. I think we can close this one now.

@gsmet gsmet added this to the 0.25.0 milestone Oct 16, 2019
@gsmet gsmet closed this Oct 16, 2019
@gsmet

This comment has been minimized.

Copy link
Member

@gsmet gsmet commented Oct 16, 2019

Thanks everyone!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.