1

We are migrating from sitecore 8.2 to sitecore 9.3 and having some custom page events to register few actions from our users. While debugging the code we could see the event name, event id everything getting added perfectly but in sitecore experience profile under events we are not able to see event type and name of event formed properly. Please see attached screenshot from sitecore 8.2 and sitecore 9.3 for reference.

Name displayed in Sitecore 8.2 -

enter image description here

Name not getting displayed in Sitecore 9.3 -

enter image description here

Custom code -

 [CLSCompliant(false)]
    public class TrackEvent : MarketingDefinitionBasedEventProcessor<EventInstance, IPageEventDefinition>
    {
        protected override bool IsValidEvent(EventInstance eventInstance)
        {
            return !string.IsNullOrWhiteSpace(eventInstance.EventId);
        }

        protected override IPageEventDefinition ResolveDefinition(EventInstance eventInstance, TrackEventPipelineArgs args)
        {
            return Sitecore.Analytics.Tracker.MarketingDefinitions.PageEvents.FirstOrDefault(
                e => e.Id == new Guid(eventInstance.EventId));
        }

        protected override void DoTrack(IPageContext pageContext, IPageEventDefinition eventDefinition, EventInstance eventInstance, ITracker tracker)
        {
            if (tracker.IsActive && tracker.Session?.Contact != null)
            {
                Sitecore.Analytics.Tracker.Current.CurrentPage.RegisterPageEvent(eventDefinition);
            }
        }
    }
2
  • 1
    I wonder if it is as simple as the page event has been removed from the content tree, or something along the lines of needing to redeploy your Page events using the Deploy marketing definitions option on the control panel?
    – dru_ward
    Commented May 2, 2022 at 15:38
  • Hi @dru_ward , we redeployed using the Deploy marketing definitions but still facing same issue.
    – NewbieHere
    Commented May 5, 2022 at 6:53

1 Answer 1

0

This issue is resolved now and we are able to see the page event names in sitecore experience profile. In our publishing targets, we have 2 databases - staging and web. So we published the events to staging database as well this time. Earlier we were publishing it only to web. After publishing to staging database, the names started to show.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.