Try our conversational search powered by Generative AI!

Installing the Aggregation Service

Product version:

EPiServer CMO 1.1

Document version:

1.0

Document last saved:

The aggregation service is a Windows service application which aggregates CMO statistics data in defined time intervals for defined CMO instances.

The installation files for the aggregation service can be found on http://world.episerver.com/download. The following files should be deployed:

  • EFExtensions.dll
  • EPiServer.Cmo.AggregationService.exe
  • EPiServer.Cmo.AggregationService.exe.config
  • EPiServer.Cmo.Core.dll
  • log4net.dll

The default installation folder is [Path to your EPiServer installation]\ Shared\ Services\ CMO Aggregation Service\. For example: C:\Program Files\ EPiServer\ Shared\ Services\ CMO Aggregation Service\.

Aggregation service can be installed and uninstalled using standard framework utility:

InstallUtil.exe EPiServer.Cmo.AggregationService.exe

By default Aggregation service is installed with Automatic startup type and logs on as Local service.

Configuration

Service and aggregation settings should be defined on CMO Settings page in CMS Admin mode on Data Aggregation tab. Database connection parameters are defined in connection strings section using ADO.NET Entity Framework format.

User can define the number of connection strings to various CMO sites and aggregation service will process data for all available CMO instances. Each connection string must have unique name:
<connectionStrings>  
   <add name="CmoSite1" connectionString="metadata=res://*/Entities.CmoModel.csdl|res://*/Entities.CmoModel.ssdl|res://*/Entities.CmoModel.msl;provider=System.Data.SqlClient;provider connection string=&quot;Data Source=.\EPISERVER;Initial Catalog=CmoSiteDB1;Integrated Security=True;MultipleActiveResultSets=True&quot;" providerName="System.Data.EntityClient" />  
   <add name="CmoSite2" connectionString="metadata=res://*/Entities.CmoModel.csdl|res://*/Entities.CmoModel.ssdl|res://*/Entities.CmoModel.msl;provider=System.Data.SqlClient;provider connection string=&quot;Data Source=.\EPISERVER;Initial Catalog=CmoSiteDB2;Integrated Security=True;MultipleActiveResultSets=True&quot;" providerName="System.Data.EntityClient" />
</connectionStrings>

Application logging can be configured in application configuration file. See more details about log4net configuration here: http://logging.apache.org/log4net/. By default logging is configured to write logs to debug output:

<configuration>
  <configSections>
        <section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net, Version=1.2.10.0, Culture=neutral, PublicKeyToken=1b44e1d426115821" />
  </configSections>  
  <log4net>  
  <appender name="OutputDebugStringAppender" type="log4net.Appender.OutputDebugStringAppender">
    <layout type="log4net.Layout.PatternLayout">
      <conversionPattern value="%date [%thread] %-5level - %message%newline" />
    </layout>
  </appender>  

  <appender name="RollingLogFileAppender" type="log4net.Appender.RollingFileAppender">
    <file value="AggregationService.log.txt" />
    <appendToFile value="true" />
    <rollingStyle value="Date" />
    <datePattern value="yyyyMMdd " />
    <layout type="log4net.Layout.PatternLayout">
      <conversionPattern value="%date [%thread] %-5level - %message%newline" />
    </layout>
  </appender>  
  <root>
    <level value="DEBUG" />
    <appender-ref ref="OutputDebugStringAppender" />
    <!--<appender-ref ref="RollingLogFileAppender" />-->
  </root>
 
  </log4net>
</configuration>

Note: Service can output log data to files. To enable logging to file you need to uncomment RollingLogFileAppender option of <root> node in service configuration file, grant Modify permission on aggregation service folder (by default C:\Program Files\ EPiServer\ Shared\ Services\ CMO Aggregation Service\) to user used to run aggregation service (by default Local service).

Removing service

Aggregation service can be installed and uninstalled using standard framework utility:

InstallUtil.exe /u EPiServer.Cmo.AggregationService.exe