lizining1231 commented on issue #3640:
URL: https://github.com/apache/dubbo-go/issues/3640#issuecomment-5245971865
我尝试构造了一份 最小复现测试 用于辅助该issue,它在当前场景下稳定报错
1. 测试的报错日志是:
```text
=== RUN TestRepro_RunHangsOnOccupiedTCP
repro_issue9_test.go:125: BUG REPRODUCED: Run did not return within 3s
after HTTP/2 failed to start (hung on errgroup.Wait)
--- FAIL: TestRepro_RunHangsOnOccupiedTCP (3.00s)
```
2. 测试的行为是:
测试拿到空闲 TCP 端口并验证同端口 UDP 空闲,然后占住 TCP 端口,用这个地址创建开启 HTTP/3 的 Server,在 goroutine
里调用 srv.Run 并把结果发到 channel。主 goroutine 用 select 等 3 秒:收到错误就打 t.Logf 日志,超时则打
t.Errorf 的 BUG REPRODUCED 日志
3. 测试的预期是:
如果 Run 在这 3 秒内返回了,带着 HTTP/2 的 bind 错误及时返回,测试通过。反之则FAIL,bug复现
4. 测试的原文件是:
[repro_issue3640_test.txt](https://github.com/user-attachments/files/30913881/repro_issue3640_test.txt)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]