microsoft / microsoft/vscode-java-debug

Getting 'ERROR: transport error 202: recv error: Connection reset by peer' while debugging

未关闭
#1,269 7 条评论 2 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

ai-triaged bug disconnect
主要语言
TypeScript
星标
591
派生
429
平均合并
1 天 9 小时
30 天内合并 PR
19

描述

Environment:

  • VS Code Version: 1.73.1
  • Extension Version: Language Support for Java(TM) by Red Hat v1.13.2022111603
  • JDK Type & Version: Oracle jdk1.8.0_351 - 32bit
  • OS Type & Version: Windows 10 Enterprise

Step to Reproduce:

  • Open an existing multi-module maven project in VS Code and wait until it is fully loaded. This project is relatively huge.
  • Setup launch.json with attach and launch for Java Project
  • The launch config is working fine. Still, after a couple of minutes, I get ERROR: transport error 202: recv error: Connection reset by peer in the terminal, and the debugger is disconnected.
  • The same happens with the attach config.
  • I am able to debug successfully as long as the debugger is not disconnected.
  • When debugging in the attach config, the debugger keeps on listening, and I can attach again, but it will disconnect after a couple of minutes.
  • Even after the debugger is disconnected, the application is still active.
  • The command used to start the debugger in attach mode is:
C:\apps\jdk1.8.0_271\bin\java.exe "-agentlib:jdwp=transport=dt_socket,server=y,suspend=y,address=localhost:60082" '-Xincgc -Xms64m -Xmx950m' '-Dsun.security.ssl.allowUnsafeRenegotiation="true"' '-Djava.security.policy="policy.all"' '-Dpython.home=".."' '-Dcom.ibm.mq.cfg.useIBMCipherMappings="false"' '-Xbootclasspath/p:class1 class2 ...' '-cp' '.\classpath.jar' 'mainClassName'

Note: The command above to start the debugger is mostly provided as it is the same one used to launch the actual application.

Launch Config for attach:

        {
            "type": "java",
            "name": "Attach to java debug port 60082",
            "projectName": "sarora",
            "request": "attach",
            "hostName": "localhost",
            "port": "60082"
        }

Expected Behavior:

  • The debugger should remain active and should not disconnect

Actual Behavior:

  • The debugger is disconnecting after a couple of minutes.

Related Issues:
I found this report to be similar:
https://github.com/microsoft/vscode-java-debug/issues/164
and I followed the instructions to do the needed troubleshooting but it is not working.

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

首先,使用所报告的 VS Code、扩展、JDK、Windows、attach 配置和大型多模块 Maven 项目,重现断开连接的问题。将行为与相关 issue 164 进行比较;当应用程序继续运行时调试器仍保持连接,即表示完成。

由索引模型根据 Issue 内容生成。

评估

技术栈
java, typescript, vscode
领域
devtools
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。