AppDynamics Application Intelligence Platform

3.8.x Documentation

PDFs

Videos

Release Notes

  • Developers use .NET remoting to build distributed applications that share objects across processes or across application domains running in the same process. AppDynamics doesn't enable correlation for .NET remoting functions by default.

    Instrumenting Applications That Use .NET Remoting

    You can configure the App Agent for .NET to discover .NET remoting entry and exit points.

    To enable correlation for .NET remoting

    1. Launch a text editor as administrator.
    2. Edit the config.xml file as an administrator. See Where to Configure App Agent Properties.

    3. Copy the code block below to a child element of the Machine Agent element. (See Machine Agent Element):

          <instrumentation>
              <instrumentor name="RemotingMscorlibEntryInstrumentor" enabled="true"/>
              <instrumentor name="RemotingExitInstrumentor" enabled="true"/> 
          </instrumentation>

      For example:

      <?xml version="1.0" encoding="utf-8"?>
      <appdynamics-agent xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
      ...
       <machine-agent>
          <!--Enable correlation for .NET remoting-->
          <instrumentation>
              <instrumentor name="RemotingMscorlibEntryInstrumentor" enabled="true"/>
              <instrumentor name="RemotingExitInstrumentor" enabled="true"/>
          </instrumentation>
        </machine-agent>
      ...
      </appdynamics-agent>
    4. Save the config.xml file.
    5. Restart the AppDyanmics.Agent.Coordinator Service.
    6. Restart instrumented applications for your changes to take effect.

    If the agent doesn't discover the entry points after configuration, specify an agent trigger.

    To specify an agent trigger

    .NET remoting entry point functions execute in low-level .NET libraries that may not trigger automatic agent instrumentation. New in 3.8.1,  if the agent doesn't discover the .NET remoting entry points after configuration you can specify a function that triggers the agent to begin instrumentation.

    1. Identify a function to trigger the agent to begin instrumentation. The function can be any function that executes as part of the application process.

      For example, consider the following code for a MovieTicket remoting object. In this case, use the function GetTicketStatus to trigger the agent. 

      using System;
      namespace MovieGoer
      {
          public class MovieTicket : MarshalByRefObject
          {
              public MovieTicket()
              {
              }
              public string GetTicketStatus(string stringToPrint)
              {
                  return String.Format("Enquiry for {0} -- Sending back status: {1}", stringToPrint, "Ticket Confirmed");
              }
          }
      }
      
      
    2. Edit the config.xml file as an administrator. See Where to Configure App Agent Properties.

    3. Update the Instrumentation element to include the AgentTriggerInstrumentor. (See Machine Agent Element):

          <instrumentation>
      		<instrumentor name="AgentTriggerInstrumentor" enabled="true" args="" />
              <instrumentor name="RemotingMscorlibEntryInstrumentor" enabled="true"/>
              <instrumentor name="RemotingExitInstrumentor" enabled="true"/> 
          </instrumentation>
    4. Set the AgentTriggerInstrumentor args value to the name of the trigger function from step 1.

      For example:

      <?xml version="1.0" encoding="utf-8"?>
      <appdynamics-agent xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
      ...
       <machine-agent>
          <!--Enable correlation for .NET remoting-->
          <instrumentation>
              <instrumentor name="AgentTriggerInstrumentor" enabled="true" args="MovieGoer.MovieTicket.GetTicketStatus" />
              <instrumentor name="RemotingMscorlibEntryInstrumentor" enabled="true"/>
              <instrumentor name="RemotingExitInstrumentor" enabled="true"/>
          </instrumentation>
        </machine-agent>
      ...
      </appdynamics-agent>
    5. Save the config.xml file.
    6. Restart instrumented applications for your changes to take effect.

     

    Learn More