Some new tricks for CodeTrack

CodeTrack has become pretty good at tracing .NET processes, if you haven’t tried it out: get your copy on and give it a go (it’s free !).
I assume you already heard about it, but if you didn’t here’s a 1 minute overview:

The latest release now supports plugins and deeptrace rulesets. This allows you to fine tune exactly which info you want to capture and then show this in a way that’s very specific for your use case.

This might still be a little bit abstract so let me explain this by giving an example.
In the latest version there’s a plugin included out of the box that allows you to capture all output to the console and show that back to you while analyzing your data.
This allows you to just scroll through your output, select a particular line in your output and jump straight to that location in the timeline. This way you can easily filter out a particular moment in time where something interesting happened.

So how is this done ?

  • First a ruleset was created that specified which methods manipulate the console output, like so:
    As you can see, there are many including the ones that change the console colors.
    Also notice how some methods have ‘Trace arguments’ enabled. If these methods get called, CodeTrack will also capture all arguments for that method and the return value.
    In this case the arguments are really simple: just some strings and an enum for the consolecolors. Sometimes the arguments you care about are objects and in those cases you can use the fields tab and specify which fields of which types you want to be captured.
  • Secondly a plugin was created to put this captured data to use and reconstruct the console output to the screen.

You can find the code for this plugin on the github page : CodeTrack Plugins On Github

To see the result in action check out this small video:

I Need your help

I hope that by now you understand the huge potential this has got: you can easily create rules about what to trace and you’re able to extend CodeTrack to use this data the way you want.

I’ve got lots of ideas for stuff to build:

  • A plugin that exports specific data out of your trace
  • A plugin that show you some nice statistics about your performance
  • A ruleset and plugin that allow you to capture trace output and or log files (eg. with support for Log4Net, NLog,…)
  • Rulesets and plugin for info about DB queries (eg. with support for RavenDb, Entity Framework, MongoDB, Redis, …)
  • Rulesets and plugin specific to Web development
  • A ruleset and or plugin that helps you understand why an assembly couldn’t be loaded (like fusionlog but easier to use/understand)
  • Plugins and rulesets to better show async behavior (and maybe also threading, locking, etc…)

Unfortunately I don’t have the time to build all of this, and I don’t know enough about these things, to decide on what methods and fields are important to trace. I’m not just talking about ‘performance-wise-interesting’, I also mean functionally (eg. in case of a web specific scenario things like: why -or why not- was a certain method called on my controller ? Which route did it take and why ?)

So I’m hoping there are people out there who know lots of stuff I don’t know (that should already be a whole bunch ;-)) and that are willing to spend some of their time to help me out by

  • Listing all interesting methods, arguments and fields for a particular scenario
  • Write plugins for codetrack
  • Providing small samples that can be used to test a particular case
  • Or maybe come up with some other interesting ideas

So are you and ASP.NET expert or an async-await-whizkid with some free time ?
Please let me know ( and maybe you can help me out !

Of course all plugins and rulesets will be shared for free!

For more info on writing plugins check the documentation on


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s