How to set timeout for VM
I'm altering classes with javassist and I have reason to believe this takes longer then 10 seconds. I get the following:
And I was wondering, can I make that time period longer?
best Doeke
Not supported yet. We didn't expose the timeout setting for the launching.
We only expose the timeout in launch.json for remote debugging.
Hi @clankill3r, I'm an AI Support assistant here to help with your issue. While the team reviews your request, I wanted to provide some possible tips and documentation that might help you in the meantime.
You can increase the debug-attach timeout by adding a timeout attribute (in milliseconds) to your launch.json. For example:
{
"version": "0.2.0",
"configurations": [
{
"type": "java",
"name": "Debug (Launch)",
"request": "launch",
"mainClass": "com.example.Main",
"timeout": 30000 // wait up to 30 seconds for the VM to start
}
]
}
• See the official Java Debug configuration docs for all supported attributes: • https://github.com/microsoft/vscode-java-debug#configuration-attributes
Other references with low confidence
• Failed to attach to remote debuggee VM (suggests how the extension code uses a timeout):
• Description: shows setting a 500 ms wait in BaseRunner.ts when programmatically attaching
• URL: https://github.com/microsoft/java-debug/issues/252#issuecomment-451335304
The team will respond to your issue shortly. I hope these suggestions are helpful in the meantime. If this comment helped you, please give it a 👍. If the suggestion was not helpful or incorrect, please give it a 👎. Your feedback helps us improve!