ANTS Performance Profiler 7

Profiling a COMplus server application

To profile a COM+ server application correctly, there are two main steps:

  1. Change the COM+ server so that it can be profiled.
  2. Set up ANTS Performance Profiler.

Change the COM+ server so that it can be profiled

ANTS Performance Profiler can only profile COM+ server applications which are activated in a process provided by the system, not by the client. To do this, set the ApplicationActivation attribute as follows:

[assembly: ApplicationActivation(ActivationOption.Server)]

If you cannot set this attribute (for example, if you do not have access to the source code), you may still be able to profile the COM+ application by profiling the client application. You should note, however, that:

  • the resulting server application will not be a true COM+ application and will run in the client process
  • ANTS Performance Profiler will profile the client application, and will treat the COM+ server as a DLL invoked by the client.

Set up ANTS Performance Profiler

To profile COM+ server applications, on the ANTS Performance Profiler Settings dialog box, perform the following steps:

  1. Under Choose application type to profile, click COM+ server.
  2. Use the dropdown list to select the COM+ server application that you want to profile.Click  to update the list of COM+ server applications.
  3. Select the required Profiling mode, file I/O, and Profile child processes options; see Working with Application Settings.
  4. If you want to profile a client application's communications with the COM+ server:
    1. Browse to the client application Executable.
    2. If required, specify any command line Arguments that are to be used when running the client application.
  5. If required, change the performance counters to record; see Setting up Charting Options.
  6. Click .

If the client application was specified, the client application starts.

If the client application was not specified, start it manually.

During a profiling session you can interact with the client application while your COM+ server is still being profiled. You obtain results by selecting areas of the timeline.

When you have finished interacting with your client application, and you are ready to finish profiling the COM+ server, click the  Stop Profiling button in ANTS Performance Profiler.

Profiling remote COM+ applications

The security architecture of COM+ does not allow COM+ applications to be started from a Remote Desktop session with a GUI, or a terminal services session.

To profile COM+ applications remotely, type mstsc /console at a command prompt to start a Remote Desktop session in console mode.

Note that all users who are logged on to the computer that you are connecting to will be logged off when you connect.

Troubleshooting

Some COM+ server applications need to be fully trusted before being profiled. If profiling the COM+ server does not work, you may need to make the application's code fully trusted by setting the ApplicationAccessControl attribute as follows:

[assembly: ApplicationAccessControl(false)]

Note that you should not normally release the COM+ application in this trusted state.


Didn't find what you were looking for?