Vscode-java-debug: Pause All Threads on Hitting Breakpoint?

Created on 25 Nov 2019  路  3Comments  路  Source: microsoft/vscode-java-debug

Is it possible to configure a breakpoint (or the debugger in general) to pause all threads when a breakpoint is hit?

I have a scenario where once one of my (worker) threads hits a breakpoint, the main thread continues creating more threads that also end up hitting the same breakpoint. I can manually pause my main thread when my breakpoint is reached, but it would be nice to be able to configure the breakpoint so that _all_ threads are _automatically_ paused. (This would probably need to be integrated with any new Continue All action being discussed elsewhere to make it easier to resume operation).

feature request

Most helpful comment

The request is to allow setting the suspend policy of the breakpoint.

  • SUSPEND_ALL: Suspend all threads when the event occurs.
  • SUSPEND_EVENT_THREAD: Suspend only the thread which generated the event when the event occurs.

All 3 comments

If we support Continue All threads feature, do you think it will mitigate the pain point in your case?

Adding Continue All Threads would be useful, but will only help in my scenario, if a breakpoint can trigger Pause All Threads.

The request is to allow setting the suspend policy of the breakpoint.

  • SUSPEND_ALL: Suspend all threads when the event occurs.
  • SUSPEND_EVENT_THREAD: Suspend only the thread which generated the event when the event occurs.
Was this page helpful?
0 / 5 - 0 ratings

Related issues

Urastor picture Urastor  路  4Comments

dgileadi picture dgileadi  路  3Comments

isidorn picture isidorn  路  4Comments

erihanse picture erihanse  路  3Comments

TheSinding picture TheSinding  路  6Comments