Separate tracers that will run in simulation from those that won't

This commit is contained in:
Lukas Joswiak 2021-03-02 10:35:37 -08:00
parent 7a40190500
commit d676cb32e1
3 changed files with 3 additions and 3 deletions

View File

@ -1647,7 +1647,7 @@ int main(int argc, char* argv[]) {
//startOldSimulator();
startNewSimulator();
openTraceFile(NetworkAddress(), opts.rollsize, opts.maxLogsSize, opts.logFolder, "trace", opts.logGroup);
openTracer(TracerType(deterministicRandom()->randomInt(static_cast<int>(TracerType::DISABLED), static_cast<int>(TracerType::END))));
openTracer(TracerType(deterministicRandom()->randomInt(static_cast<int>(TracerType::DISABLED), static_cast<int>(TracerType::SIM_END))));
} else {
g_network = newNet2(opts.tlsConfig, opts.useThreadPool, true);
g_network->addStopCallback( Net2FileSystem::stop );

View File

@ -365,7 +365,7 @@ void openTracer(TracerType type) {
g_tracer = new FastUDPTracer{};
#endif
break;
case TracerType::END:
case TracerType::SIM_END:
ASSERT(false);
break;
}

View File

@ -98,7 +98,7 @@ struct Span {
enum class TracerType {
DISABLED = 0,
NETWORK_LOSSY = 1,
END = 2, // Any tracers that come after END will not be tested in simulation
SIM_END = 2, // Any tracers that come after SIM_END will not be tested in simulation
LOG_FILE = 3
};