Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

SFINT-3372 Fix incoherent event for good #92

Merged
merged 3 commits into from
Sep 18, 2020

Conversation

jeremierobert-coveo
Copy link
Collaborator

Issue

The click event sent by ClickedDocumentList is not linked to any Search Event.

Overview

User Actions sent by ML only have the urihash.
To display the documents, ClickedDocumentList fetch then by doing a search request using the SearchEndpoint.
That's mainly why the click event emitted by ClickedDocumentList are not linked to any event.

Solutions

  • Tranforming the Click event into a Custom event (We can't prevent a result link from sending a click event without modifying the Search-ui)
  • Emit a Search event when we fetch the documents.

Considerations

  • We can't use the QueryController because we don't want to impact the main search.
  • We don't have direct reference to the LiveAnalyticsClient.

Flaws

The current PR manually build a search event from the QueryBuilder & the SearchRequest.

Copy link
Collaborator

@louis-bompart louis-bompart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I saw the discussion in the Jira, if I understand properly, the 'product' goal is to eliminate those pesky incoherent events. If so, that seems like a good compromise.

sendSearchEvents: sendSearchEventsStub,
},
},
} as any;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ain't that at least a Partial something?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's a test mock polyfill

@jeremierobert-coveo jeremierobert-coveo merged commit 46b9007 into master Sep 18, 2020
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants