-
Notifications
You must be signed in to change notification settings - Fork 4
Add Enterprise Telemetry #183
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
base: enterprise-main
Are you sure you want to change the base?
Conversation
…metry sending Changes sendingEnabled() to check AppConstants.MOZ_TELEMETRY_REPORTING instead of Services.telemetry.isOfficialTelemetry. This aligns with the conceptual separation of MOZILLA_OFFICIAL (official Mozilla build) from MOZ_TELEMETRY_REPORTING (telemetry transmission enabled), allowing for more granular control over telemetry behavior. Fixes the issue where "upload is turned off" was incorrectly shown in builds with MOZ_TELEMETRY_REPORTING enabled but MOZILLA_OFFICIAL disabled.
…NG config - Reset telemetry.fog.test.localhost_port to 0 (default) - Use MOZ_TELEMETRY_REPORTING instead of MOZILLA_OFFICIAL for glean upload control - Expose MOZ_TELEMETRY_REPORTING as config variable for build system access
- Create new enterprise ping definition in browser/components/downloads/pings.yaml - Move both file_downloaded and security_download_completed events to enterprise ping - Consolidate all download telemetry events in browser component metrics.yaml - Register enterprise ping in glean metrics_index.py for Firefox Desktop - Add GleanPings.enterprise.submit() calls to actually send the ping - Remove duplicate telemetry event definitions from toolkit component This separates enterprise security telemetry from the general events ping, providing better data organization and privacy controls.
PathUtils is available as a WebIDL global binding in Firefox, not as an ES module. Removed the ChromeUtils.importESModule call and fallback code since PathUtils is always available in this context.
916526d to
9f6d06f
Compare
| _isEnabled() { | ||
| return Services.prefs.getBoolPref( | ||
| "browser.download.enterprise.telemetry.enabled", | ||
| true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we default to enabled by default? ok
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mostly for debugging, can flip the default later on. We did enable the other stuff by default.
CrowdStrike knows your downloads anyway :P
| telemetry_mirror: DOWNLOADS_PANEL_SHOWN | ||
|
|
||
| #ifdef MOZ_ENTERPRISE | ||
| download_completed: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we need feedback from glean people on how we do this? not data review but making sure event is the correct way?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I already had this discussions about this part. An event works, but it's only live if it's not part of the normal (Firefox) events ping, which is why this needed a separate enterprise ping. Normal Firefox events are queued up to 500 and sent together. We don't want this for Enterprise to make the console a "live" view.
| # Only run in MOZ_ENTERPRISE builds | ||
| skip-if = [ | ||
| "!buildapp:firefox", | ||
| "!enterprise", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we have this mozinfo flag? good to know I'll use it for policies
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I should probably test the non-enterprise build :P
| }, | ||
|
|
||
| BlocklistDomainBrowsedTelemetry: { | ||
| onBeforeAddons(manager, param) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: onRemove could be welcome :)
| }, | ||
|
|
||
| PrintPageTelemetry: { | ||
| onBeforeAddons(manager, param) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: onRemove would be welcome
| }, | ||
|
|
||
| DownloadTelemetry: { | ||
| onBeforeAddons(manager, param) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: onRemove would be welcome
| "browser.newtabpage.activity-stream.feeds.system.topstories=true", | ||
| "browser.newtabpage.activity-stream.feeds.section.topstories=true", | ||
| "browser.newtabpage.activity-stream.feeds.system.topstories=true", | ||
| "browser.newtabpage.activity-stream.telemetry.structuredIngestion=false", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do we remove?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i would feel safer if we did this removal conditionnally on being an enterprise build
| // We only send pings when telemetry reporting is enabled, but allow overriding this for tests. | ||
| if ( | ||
| !Services.telemetry.isOfficialTelemetry && | ||
| !AppConstants.MOZ_TELEMETRY_REPORTING && |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
might be worth scoping this only to enterprise builds?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe at some point we'll have our own distinction of official / non official builds?
| #ifdef MOZ_ENTERPRISE | ||
| send_in_pings: | ||
| - enterprise | ||
| - default |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why default ? isn't it always sent to in the default ping?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I hope the other events aren't :P
No description provided.