Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

[Fleet] Add telemetry for integration cards #115413

Merged
merged 4 commits into from
Oct 19, 2021

Conversation

thomasneirynck
Copy link
Contributor

@thomasneirynck thomasneirynck commented Oct 18, 2021

Summary

Closes #113835

Adds data-test-subj attribute and UI-tracker to package-cards.

id for both is of the form:

integration-card:[epr|ui_link]:{card-id}

For maintainers

@thomasneirynck thomasneirynck added Feature:Unified Integrations Unified Integrations view feature Team:Fleet Team label for Observability Data Collection Fleet team v7.16.0 v8.0.0 labels Oct 18, 2021
@thomasneirynck thomasneirynck added chore release_note:skip Skip the PR/issue when compiling release notes labels Oct 18, 2021
@thomasneirynck thomasneirynck marked this pull request as ready for review October 18, 2021 20:21
@thomasneirynck thomasneirynck requested a review from a team as a code owner October 18, 2021 20:21
@elasticmachine
Copy link
Contributor

Pinging @elastic/fleet (Team:Fleet)

@jen-huang jen-huang changed the title [Fleet] Add telemetry [Fleet] Add telemetry for integration cards Oct 18, 2021
@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
fleet 625.3KB 625.4KB +146.0B

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
fleet 106.2KB 106.4KB +289.0B

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

Copy link
Contributor

@joshdover joshdover left a comment

Choose a reason for hiding this comment

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

LGTM

const unmount = renderApp(startServices, params, config, kibanaVersion, extensions);

const Tracker =
deps.usageCollection?.components.ApplicationUsageTrackingProvider ?? React.Fragment;
Copy link
Contributor

Choose a reason for hiding this comment

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

Interesting little trick here with React.Fragment. Any risks to using this vs. a simple 'passthrough' component like:

const Passthrough: React.FC = ({ children }) => children

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is boilerplate from the telemetry-docs

const ApplicationUsageTrackingProvider = plugins.usageCollection?.components.ApplicationUsageTrackingProvider ?? React.Fragment;

The same syntax is used also in the ML, SIEM, and Maps plugins.

plugins.usageCollection?.components.ApplicationUsageTrackingProvider ?? React.Fragment;
,
deps.usageCollection?.components.ApplicationUsageTrackingProvider ?? React.Fragment;
,
usageCollection?.components.ApplicationUsageTrackingProvider ?? React.Fragment;

So I think it should be OK.

@joshdover
Copy link
Contributor

FYI this PR adds a few "featured" cards that we need to track as well. I added note here about how this could be done, but want to mention it here to ensure it doesn't get missed: #115495 (comment)

@thomasneirynck thomasneirynck added the auto-backport Deprecated - use backport:version if exact versions are needed label Oct 19, 2021
@thomasneirynck thomasneirynck merged commit 7420cc2 into elastic:master Oct 19, 2021
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Oct 19, 2021
@kibanamachine
Copy link
Contributor

💚 Backport successful

Status Branch Result
7.x

This backport PR will be merged automatically after passing CI.

kibanamachine added a commit that referenced this pull request Oct 19, 2021
jloleysens added a commit to jloleysens/kibana that referenced this pull request Oct 19, 2021
…-link-to-kibana-app

* 'master' of github.com:elastic/kibana: (30 commits)
  Fix potential error from undefined (elastic#115562)
  [App Search, Crawler] Fix validation step panel padding/whitespace (elastic#115542)
  [Cases][Connectors] ServiceNow ITOM: MVP (elastic#114125)
  Change default session idle timeout to 8 hours. (elastic#115565)
  Upgrade EUI to v39.1.1 (elastic#114732)
  [App Search] Wired up organic results on Curation Suggestions view (elastic#114717)
  [i18n] remove i18n html extractor (elastic#115004)
  [Logs/Metrics UI] Add deprecated field configuration to Deprecations API (elastic#115103)
  [Transform] Add alerting rules management to Transform UI (elastic#115363)
  Update UI links to Fleet and Agent docs (elastic#115295)
  [ML] Adding ability to change data view in advanced job wizard (elastic#115191)
  Change deleteByNamespace to include legacy URL aliases (elastic#115459)
  [Unified Integrations] Remove and cleanup add data views (elastic#115424)
  [Discover] Show ignored field values (elastic#115040)
  [ML] Stop reading the ml.max_open_jobs node attribute (elastic#115524)
  [Discover] Improve doc viewer code in Discover (elastic#114759)
  [Security Solutions] Adds security detection rule actions as importable and exportable (elastic#115243)
  [Security Solution] [Platform] Migrate legacy actions whenever user interacts with the rule (elastic#115101)
  [Fleet] Add telemetry for integration cards (elastic#115413)
  🐛 Fix single percentile case when ES is returning no buckets (elastic#115214)
  ...

# Conflicts:
#	x-pack/plugins/reporting/public/management/__snapshots__/report_listing.test.tsx.snap
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Deprecated - use backport:version if exact versions are needed chore Feature:Unified Integrations Unified Integrations view feature release_note:skip Skip the PR/issue when compiling release notes Team:Fleet Team label for Observability Data Collection Fleet team v7.16.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unified Integrations View - Improve telemetry on integration funnel
4 participants