Support & Documentation
Follow

Prefix Premium: Advanced Custom Configuration

In Prefix you may notice that some events  By default, the Stackify .NET APM+ Profiler only instruments key, pre-defined events in the IIS pipeline and page lifecycle. One of the key benefits of the profiler, however, is that you may instrument how long any .NET method takes to execute and include that output in the call stack.

In deciding what to profile, keep in mind the overhead that could be incurred. For example, if you choose to use a wildcard configuration as described below, all .NET properties that have Get and Set accessors (which includes dynamic properties) will be profiled via these accessors, and can be quite “chatty.”

Advanced Custom Configuration

Note: This section describes how to customize the Stackify .NET Profiler to add instrumentation. Any changes made to the configuration file must be formatted properly at the risk of causing instability.

To add custom configuration:

  • Create a configuration file named ProfileClientConfig.txt in your installation folder ([Install Drive]:\Program Files (x86)\Stackify\ProfileClientConfig.txt)  
  • Make changes as described below to the JSON document
  • Save changes
  • Recycle the IIS application pool for your app

In the ProfileClientConfig.txt configuration file you created, you will need to create a JSON format document that allows you to specify methods you wish to profile. The document follows this format:

[{
	"Class": "MyNamespace.MyClass",
	"Method": "MyMethod"
},
{
	"Class": "MyNamespace.MyClass2",
	"Method": "MyMethod"
}
]

A wildcard of “*” may be used for both Class and Method properties. It is not recommended to use the wildcard character for a namespace, as that will key the profiler to instrument every single .NET method call. Please note that every tracked method adds overhead to your application and will slow it down slightly. Adding a few methods picked up per web request is no big deal, however, a wildcard for something like System.Data.* is a bad idea and could crash your application.

Valid options are:

[{
	"Class": "MyNamespace.MyClass",
	"Method": "*"
},
{
	"Class": "MyNamespace.*",
	"Method": "*"
}
]

Please ensure to follow proper JSON document formatting. Incorrect formatting will prevent the profiler from starting.

 

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments

Powered by Zendesk