System Freezes When Debugging Java Applications

less than 1 minute read

Acutally, it is only mouse clicks that are not working anymore. The keyboard is still responsive.

Solution Provide the following system property when starting your application, that you want to debug: -Dsun.awt.disablegrab=true

For Eclipse, you can configure your debug configuration as follows:

eclipse-debugging-arguments

In the VM arguments: field, paste -Dsun.awt.disablegrab=true, press on Apply or Debug.

The UI should stay responsive now!

Happy debugging!

PS: this issue has been already reported here.