Hello! We are finalizing an update on our project to using 5.6, but one thing we noticed was that some functionality we were using specifically with NetTraces stopped working after taking the update.
Specifically in NetTraceReporter.cpp a number of events that are required for being able to use Networking Insights (like the InitEvent) are no longer marked as Important. All of them technically are not marked important but the init event was the main one.
We have been utilizing the tail buffer functionality for most of our playtest tracing as we find retroactively requesting a trace of a bad scenario to be an extremely useful tool. It seems though like with recent changes the direction for tracing in general is moving more towards preemptive tracing with more aspects of the system initializing on trace start instead of program start.
To get around this we had to do a couple small things, notably making some net events important again, running the OnTraceStarted() callback on engine init regardless of whether or not we started with a trace command, and removing the resetting of the name id counter inside OnTraceStarted() so that important net events didn’t duplicate their IDs with non-important events on repeat traces.
My question is mostly around whether tail buffer tracing support is planned to continue in future versions of the engine since I think the net trace events were some of the only users of the Important trace flag.
Steps to Reproduce
This is technically an engine modification since we are using TraceAuxiliary snapshots at runtime instead of just in the editor, but this works for us.
Steps:
Enable the net trace channel and set Net trace verbosity on startup of a dedicated server.
Run a TraceAuxiliary snapshot on the server
Notice the generated .utrace file cannot open the Networking Insights tab
Tail buffer tracing support is for sure going to continue, it’s vital to our strategy of reactive capturing, exactly the scenario you describe.
We have made an effort to move important events to be emitted on OnConnect callback instead, to reduce the memory footprint. This only works for events that can be enumerated when that callback is executed.
In that process we have discovered some flaws in how the OnConnect functionality works and how we deal with it. One issue we found was that there can be gaps in the serial order which prevented some of the NetTrace events to be processed. We fixed that in 46512363 (https://github.com/EpicGames/UnrealEngine/commit/016d2ada5df1f606f59cfd110190c670d992ca4e if you sync from Github). We saw that this fixed the issues with NetTrace we saw internally.
We also have carved out time to look into the design of OnConnect to see if we can make this feature behave a little more robustly.
Are you using snapshots or start/stop trace manually?
We occasionally use stop/start manually but we primarily do tracing through snapshots. In our development builds we have added debug keybinds to run snapshot captures on the server or client so anyone can generate traces of bad scenarios, so any weirdness with snapshot captures shows up pretty quickly.