The Code Profiler in Dynamics AX

The Code Profiler in Dynamics AX is a powerful tool for finding performance issues in the application.

But it can also be a little difficult to use simply just because of the overwhelming amount of data it creates, so sometimes it's nice to limit the amount of code it runs on.

This is where the macro #profileBegin comes in really handy.

If you already know the place in your code that runs slow, you can put in the macro before and after, and then the profiler only runs on that piece of code.

Example:
       
       
       public void  printJournal(Set _journalList)
       {
           /*
            . Cut out code
            .
            .
           */
               {
                   #profileBegin("printJournal")    // RSH Start profiling code
                   this.sendAsXML();
                   this.doPrint();
                   #profileEnd                      // RSH End profiling code
               }
           }
       }
       
 

Now you only profile the code you actually need to measure, and not allot of unnecessary code.

Kommentarer

Populære opslag fra denne blog

Dynamics AX use of the startupcmd parameter

Axapta Manager (AxDynManagerV1.03)

Axapta Manager (AxDynManagerV1.02)