-
Story
-
Resolution: Unresolved
-
Normal
-
None
-
None
-
None
-
False
-
-
False
-
Unset
-
No
-
-
In OCM, we're annotating analytics with a ocm_resource_type field, depending on page and in some cases — when viewing details of specific cluster — on the cluster type.
The technical problem we hit in HAC-2424 is cluster type is fetched asynchronously from backend. AFAICT, the analytics gets sent right after URL change:
https://github.com/RedHatInsights/insights-chrome/blob/b067cb24f8702092dc2cd8cc14ca2df65faa5f65/src/analytics/SegmentProvider.tsx#L72-L77
The setTimeout() gives our app a chance to setPageMetadata() on first render but no chance to customize it when backend data arrives later.
We do call setPageMetadata() again but it merely sets window._segment for future use, does not trigger re-sending the analytics.
- nice-to-have: Could we skip the initial analytics when we need more data? To not pollute it with 'unknown' values?
- important: Can we explicitly cause segment.page() to happen again once we get the data?
- is depended on by
-
OCMUI-68 [ROSA]: Frequency of ocm_cluster_type set to unknown increasing
- To Do