I am upgrading Sitecore 8.2 to Sitecore 9.3. While upgrading Sitecore.analytics.aggregation
reference to target version 9.3, I'm getting the error The type or namespace 'AggregationProcessor' could not be found
for the code. And to upgrade the below custom processor, we need to get the visit details (args.context.visit.sitename and args.context.visit.pages) and it is not available in the 'InteractionAggregationPipelineArgs'. How could i use Interaction and Contact to get the visit details?
public class CentralLikeProcessor : AggregationProcessor
{
private Guid LikeEventDefinitionId = Common.Constants.PageEvents.Like.Guid;
protected override void OnProcess(AggregationPipelineArgs args)
{
Assert.ArgumentNotNull(args, "args");
Log.Info("xDB Started CentralLikeProcessor event", this);
if (args.Context.Visit.SiteName == "central" || args.Context.Visit.SiteName == "authoring")
{
if (args.Context.Visit.Pages == null)
{
return;
}
foreach (PageData page in args.Context.Visit.Pages)
{
if (page.PageEvents != null)
{
var fact = args.GetFact<CentralLikes>();
foreach (var pageEvent in page.PageEvents.Where(p => p.PageEventDefinitionId
== LikeEventDefinitionId))
{
var itemId = pageEvent.ItemId;
if (itemId != Guid.Empty)
{
var likeKey = new CentralLikeKey();
likeKey.ItemId = itemId;
var likeValue = new CentralLikeValue();
likeValue.Count = 1;
fact.Emit(likeKey, likeValue);
}
}
}
}
}
Log.Info("xDB Ended CentralLikeProcessor event", this);
}
}
}
Could you please suggest me on how to upgrade the above code with Sitecore 9.3?