ManageEngine has been recognized as a Customers' Choice in the 2023 Gartner Peer Insights™ Voice of the Customer for Application Performance Monitoring and Observability report. Learn more

Configure Application Filters for .NET Core applications


You can exclude select .NET Core applications from being monitored by APM Insight. This will help exclude unwanted applications and result in efficient use of your license. As practising Dot NET Core monitoring is essential for the smooth running of .NET Core applications, you can use the following steps to monitor select .NET Core applications using APM Insight.

Note: This is applicable only for applications hosted in IIS.

.NET core agent v6.0 and above

Follow the steps below to monitor specific .NET Core applications:

  1. Filter .NET Core applications hosted on IIS
  2. Filter .NET Core applications running as standalone processes or Windows services
  3. Filter .NET Core applications running as Windows services

1. Filtering .NET Core applications hosted on IIS

  1. Navigate to the folder where the .NET Core agent is installed.
  2. Open the appfilter.config file in the text editor.
  3. Add or modify the app pool name and its corresponding monitor name as shown below:

    <?xml version="1.0" encoding="utf-8" ?>
    <applications>
    <application AppPoolName="<Your_Application_Pool_Name>"
    MonitorName="<Your_APM_Application_Name>" />
    </applications>

    Note: Since applications in the .NET Core agent are monitored or excluded based on their application pool name, it is important to specify the name of the corresponding application pool. You can also use the same name or a new name to monitor the IIS applications in Applications Manager.

  4. Save the appfilter.config file.
  5. Recycle the application pool or use the IISRESET command to restart it.
  6. Perform transactions in the application to view data in the Applications Manager console.

2. Filtering .NET Core applications running as standalone processes or Windows services

  1. Navigate to the folder where the .NET Core agent is installed.
  2. Open the netcore_appfilter.config file in the text editor.
  3. Note: For .NET Core agent versions upto v6.0.2, the applications running as Windows services can be filtered by executing netcore_appfilter.config file.

  4. Add or modify the process name and its corresponding monitor name as shown below:

    <?xml version="1.0" encoding="utf-8" ?>
    <processes>
    <process Name="<Your_ApplicationProcess_Or_WindowsServiceProcess_Name>.exe"
    MonitorName="<Your_APM_Application_Name>" />
    </processes>

    Note: You can set the same name or a new name to monitor the application in Applications Manager.

  5. Save the netcore_appfilter.config file.
  6. Restart the standalone .NET Core application or the .NET Core Windows service to create the monitor.
  7. Add the application methods to the custom instrumentation to collect performance metrics, as shown in the following steps:
    1. Log in to Applications Manager.
    2. Navigate to APM tab → Your applicationMonitor ActionsEdit, which directs you to the Edit APM Insight Application Configuration window.
    3. In the Custom instrumentation field, add the class method that is called periodically in the Windows service or the method that is triggered most of the time in a standalone application.

    4. After specifying the required class method, save the configuration and wait for a couple of minutes.
    5. Now restart the .NET Core application to start monitoring.

3. Filtering .NET Core applications running as Windows services

Note: The option to filter .NET Core applications running as Windows services is applicable only for .NET Core agent versions from 6.3.0

  1. Navigate to the folder where the .NET Core agent is installed.
  2. Open the windowsservice_appfilter.config file in the text editor.
  3. Add or modify the app pool name and its corresponding monitor name as shown below:

    <?xml version="1.0" encoding="utf-8" ?>
    <windowsServices>
    <windowsService ServiceName="<Your_Windows_service_Name>" MonitorName="<Your_APM_Application_Name>" />
    </windowsServices>

    Note: You can either set the same name as the Windows service or choose a different name for the applications's monitor.

  4. Save the windowsservice_appfilter.config file.
  5. Restart the configured .NET Core Windows services to start monitoring.

.NET Core agent v5.4 and below

Follow the steps given below to configure application filters for .NET Core agent v5.4 and below:

  1. Navigate to the .NET Core agent folder.
  2. Open the appfilter.config file in the text editor.
  3. Add or modify the app pool name and its corresponding monitor name as shown below.

    <?xml version="1.0" encoding="utf-8" ?>
    <applications>
    <application AppPoolName="[Your_Application_Pool_Name]"
    MonitorName="[Your_APM_Application_Name]" />
    </applications>

    Note: Unlike .NET agent, applications are monitored or excluded based on their application pool name in .NET Core agent. This is why you need to enter the corresponding application pool name. You can also set the same name or a new name by which you want to monitor the app pools in Applications Manager.

  4. Save the appfilter.config file.
  5. Recycle the application pool or run the RESET IIS command.
  6. Perform transactions in the application to view data in the Applications Manager console.