core icon indicating copy to clipboard operation
core copied to clipboard

Spike: Scope work needed to record analytics infra events via Java code

Open john-thomas-dotcms opened this issue 1 year ago • 1 comments

Parent Issue

https://github.com/dotCMS/core/issues/29475

Task

Currently, all events written to the analytics infrastructure (experiments events) are written via Javascript code inserted in the page.

However, for the Content Analytics feature, we will need to track some types of events that happen in the back-end Java code (as opposed to events that happen on the front-end page). For these events, we need to be able to:

  1. Call a Java method that records an event (or series of events).
  2. Call a Java method that retrieves a series of events via a query.
    • For example, one place this method might be used is in the implementation of a Velocity viewtool to query analytics infrastructure data.

This spike is to scope the work needed to implement Java methods to interact with the analytics infrastructure, for both write (recording new events) and read (querying events).

Proposed Objective

Same as Parent Issue

Proposed Priority

Same as Parent Issue

Acceptance Criteria

  • Create cards to cover all work required to implement Java methods that duplicate existing JS method functionality.

External Links... Slack Conversations, Support Tickets, Figma Designs, etc.

No response

Assumptions & Initiation Needs

No response

Quality Assurance Notes & Workarounds

No response

Sub-Tasks & Estimates

No response

### Tasks
- [ ] https://github.com/dotCMS/core/issues/29711
- [ ] https://github.com/dotCMS/core/issues/29712
- [ ] https://github.com/dotCMS/core/issues/29713
- [ ] https://github.com/dotCMS/core/issues/29714
- [ ] https://github.com/dotCMS/core/issues/29717

john-thomas-dotcms avatar Aug 06 '24 21:08 john-thomas-dotcms

Analytics core

we have think on two scenarios:

  1. intercepting a request (api, urls, etc via web interceptor)
  2. advising a piece of code (via annotation)

For 1 we need an issue to do the: 1.a) the matcher layer 1.b) collectors layer 1.c) broadcast abstraction/emitters layer 1.d) write some subscriber to send to jitsu

for 2 we need an issue to do the:

  1. the annotation
  2. integrate the method interceptor annotation to the mechanism described on #1

jdotcms avatar Aug 22 '24 16:08 jdotcms