Agents

Concept

An agent will look at a specified folder where the wrapped exceptions (xml files) are stored. He will then try to save those files in the Database through the ELMAH Web service.
The agent will need access to the ELMAH Web service.
The agent will also save a heartbeat to the Database through the same web service so that a monitoring tool (example: ipMonitor) can see if the agent is alive or dead.
We can also monitor the agent’s state on the web interface.
An agent will also make itself known to the Database. So no extra measures need to be taken to create awareness of an agent.

Installation

  1. Download the OrbitOne.Elmah.Agent.zip file from the downloads section
  2. Extract OrbitOne.Elmah.Agent.zip
  3. Run the included executable to install all the necessary files.

Configuration

If this is a newly installed agent, and you typed the configuration correctly in the installer, you do not need to touch the configuration.
If you want to manually configure it, and check the currently configured settings:

Add a configuration section (in the configSections section)

<section name="AgentConfiguration"
	 type="OrbitOne.Elmah.Agent.AgentConfiguration, OrbitOne.Elmah.Agent, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null" />
And below the configSections section:

<AgentConfiguration AgentName="Name of the agent" 	
	AgentDescription="Description of the agent" 
	AgentCreatedOn="12/05/2008 18:38:15"
	ErrorXmlSourceFolder="c:\temp\logs"
	ErrorXmlFileFilter="*.xml"
	InvalidLogFileFolder="c:\temp\Invalidlogs"
	ElmahWebServiceUrl="http://localhost/elmahwebservice/service.asmx"/>
  • AgentName: the name of the agent (uses the full computer name in the installer)
  • AgentDescription: the description of the agent
  • AgentCreatedOn: the date and time the agent was installed. When you have an old agent in the web interface you might want to overwrite it with this new agent (in case of disaster recovery or migration to a new server for instance) If you put the same created on date as the old one, that old agent will be reused by the new one.
  • ErrorXmlSourceFolder: the folder where the errors are dropped by the Elmah HttpModule.
  • InvalidLogFileFolder: when an error cannot be processed for some reason other than unreachable service, the error will be saved in this folder. This way you never lose an exception.
  • ErrorXmlFileFilter: you should not touch this one unless you do some code changes to the handler to spit the errors in a different file type.
  • ElmahWebServiceUrl: the URL of the Elmah web service

Security

Make sure that the Logs and the invalidLogs folders have write / create rights for everyone. If this is not the case you might not get the errors in the folders. They are being placed there by the Application pool users of the web sites on which you configure the Elmah Module

Last edited Jan 25, 2013 at 8:56 AM by OrbitOne, version 15

Comments

No comments yet.