Envy/Stats
The WSI Monitor window and the HTML Test and Profiler window both include an Envy/Stats checkbox. If you load the Envy/Stats config map from the Configuration Maps browser, the checkbox will be enabled. When you select Profile using ENVY/Stats, the Profiler iterations field becomes enabled. This allows you to specify how many times you want ENVY/Stats to iterate through the Web Connection part. If you specify a high number, the time it takes the Web Connection part to render in the Web browser will be longer than if you do not profile or if you profile with a small number of iterations.
When the Web part is processed to generated HTML, the process will be profiled using the Envy/Stats EsbSampler spyOn: method. After the part has been generated, an Envy/Stats Method Execution Trace browser is opened. This shows a tree view of the methods detected to have been executed during processing and the time spent in each method.
Note that the EsbSampler uses a timer to periodically sample which methods are executing. The results from this way of profiling may not show every method that is executed because some methods can execute between timer ticks. For simple web parts on fast machines, profiling the execution may show that no methods were executed. This of course is an anomaly of the sampling method. However, the profiling should show the time spent in file I/O, database transactions, and other more expensive methods of your application, thus letting you optimize your code.
Last modified date: 01/29/2015