msquic icon indicating copy to clipboard operation
msquic copied to clipboard

Add global Stream tracker in debug builds

Open anrossi opened this issue 1 month ago • 4 comments

Description

Help debug lost reference issues in MsQuic by keeping a global list of streams.

Testing

CI

Documentation

N/A

anrossi avatar Nov 18 '25 01:11 anrossi

Codecov Report

:white_check_mark: All modified and coverable lines are covered by tests. :white_check_mark: Project coverage is 85.29%. Comparing base (d3d182c) to head (8465cc6). :warning: Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5598      +/-   ##
==========================================
+ Coverage   84.81%   85.29%   +0.47%     
==========================================
  Files          60       60              
  Lines       18647    18658      +11     
==========================================
+ Hits        15816    15914      +98     
+ Misses       2831     2744      -87     

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

codecov[bot] avatar Nov 18 '25 02:11 codecov[bot]

I am not convinced this helps given that AllStreamsLink already exists + the debugger extension. The PR is adding / removing to the list in the exact same spot as for AllStreamsLink. It seems redundant to me.

guhetier avatar Nov 20 '25 22:11 guhetier

I am not convinced this helps given that AllStreamsLink already exists + the debugger extension. The PR is adding / removing to the list in the exact same spot as for AllStreamsLink. It seems redundant to me.

The debugger extension is fine, but isn't cross platform. We need a way to provide simple debugging steps for all platforms, so having simple, manually-inspectable lists seems the path of least cost and most reliability.

In terms of the stream tracker specifically being redundant, I agree it's perhaps a lower value object if the owning connections can be reliably found. I'd think of this PR more as a litmus test for the general model than a standalone PR that will dramatically change the debugging experience by itself.

mtfriesen avatar Nov 21 '25 13:11 mtfriesen

I am not convinced this helps given that AllStreamsLink already exists + the debugger extension. The PR is adding / removing to the list in the exact same spot as for AllStreamsLink. It seems redundant to me.

The debugger extension is fine, but isn't cross platform. We need a way to provide simple debugging steps for all platforms, so having simple, manually-inspectable lists seems the path of least cost and most reliability.

In terms of the stream tracker specifically being redundant, I agree it's perhaps a lower value object if the owning connections can be reliably found. I'd think of this PR more as a litmus test for the general model than a standalone PR that will dramatically change the debugging experience by itself.

Good point for the debugger extension. It still feels redundant to me, or at least, I have a hard time thinking of a scenario where this global list brings much value over the per-connection list.

If there are scenarios, it would be good to extend our trouble shooting guide (or have another doc file focused on debugger) with a list of those debug helpers and when they are relevant. It will be easier to do as we go.

guhetier avatar Nov 21 '25 17:11 guhetier