6

I am trying to debug a basic Quarkus app by running the command ./mvnw compile quarkus:dev on IntelliJ (as stated in the Quarkus docs) and it seems to run ok (gives me the following message: Listening for transport dt_socket at address: 5005) I can call the APIs on port 8080 and all fine but when I try to call the same API on port 5005 I get the following error Debugger failed to attach: handshake failed - received >GET /api/domai< - expected >JDWP-Handshake<. I tried configuring a Remote Debug configuration as shown in the image but doesn't seem to work.

enter image description here

Does anyone know how to solve this?

Andre Carrilho
  • 133
  • 1
  • 1
  • 7

1 Answers1

9

One process can listen on multiple TCP/IP sockets for multiple things.

The debug port is the port 5005 where you attach the remote debugger to.

The API calls still need to go to port 8080, though. When you hit a breakpoint, you will see it in your debugger.

GeertPt
  • 16,398
  • 2
  • 37
  • 61
  • I was trying to access the APIs through localhost:5005 but if I switch to localhost:8080 attaching the debugger to 5005 it works (breakpoint stops). So thanks a lot (will mark your answer as correct)!! What I don't understand is how is the debugger running on 5005 but when I hit the API on port 8080 the breakpoint stops? – Andre Carrilho Nov 09 '21 at 15:21
  • 1
    They're different things. One process can have multiple TCP/IP sockets for multiple things. – GeertPt Nov 09 '21 at 15:23