Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
111 changes: 106 additions & 5 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions components/places/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ sync-guid = { path = "../support/guid", features = ["rusqlite_support", "random"
thiserror = "2"
anyhow = "1.0"
uniffi = { version = "0.31" }
glean-sym = { git = "https://github.com/mozilla/glean", rev = "0401cd87c365fd8356e5d3bb6d72a67c8940c934" }

[dev-dependencies]
error-support = { path = "../support/error", features = ["testing"] }
Expand All @@ -40,3 +41,4 @@ sql-support = { path = "../support/sql" }

[build-dependencies]
uniffi = { version = "0.31", features=["build"]}
glean-build = { git = "https://github.com/mozilla/glean", rev = "0401cd87c365fd8356e5d3bb6d72a67c8940c934" }
13 changes: 13 additions & 0 deletions components/places/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,19 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */

use glean_build::Builder;

fn main() {
uniffi::generate_scaffolding("./src/places.udl").unwrap();

if let Ok("android") = std::env::var("CARGO_CFG_TARGET_OS")
.as_ref()
.map(String::as_str)
{
Builder::default()
.file("metrics.yaml")
.format("rust_sym")
.generate()
.expect("Error generating Glean Rust bindings");
}
}
114 changes: 114 additions & 0 deletions components/places/metrics.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,114 @@
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

---
$schema: moz://mozilla.org/schemas/glean/metrics/2-0-0
Comment thread
badboy marked this conversation as resolved.

places_manager:
connection_initialized:
type: counter
description: |
Number of times a `PlacesConnection` was initialized.
bugs:
- https://bugzilla.mozilla.org/show_bug.cgi?id=2034534
data_reviews:
- https://github.com/mozilla/application-services/pull/7336
notification_emails:
- jrediger@mozilla.com
expires: 2026-11-13
data_sensitivity:
- technical

run_maintenance_prune_time_temp:
type: timing_distribution
description: |
Time taken to execute `prune_older_visits()` inside `run_maintenance()`

Duplication of `run_maintenance_prune_time` for glean-sym testing.
time_unit: millisecond
bugs:
- https://github.com/mozilla/application-services/issues/5246
- https://bugzilla.mozilla.org/show_bug.cgi?id=2034534
data_reviews:
- https://github.com/mozilla/application-services/issues/5247
- https://github.com/mozilla/application-services/issues/5387
- https://github.com/mozilla/application-services/issues/5830
- https://github.com/mozilla/application-services/pull/7336
notification_emails:
- synced-client-integrations@mozilla.com
- bdk@mozilla.com
- jrediger@mozilla.com
expires: 2026-11-13
data_sensitivity:
- technical
no_lint: [COMMON_PREFIX]

run_maintenance_vacuum_time_temp:
type: timing_distribution
description: |
Time taken to execute `VACUUM` inside `run_maintenance()`

Duplication of `run_maintenance_vacuum_time` for glean-sym testing.
time_unit: millisecond
bugs:
- https://github.com/mozilla/application-services/issues/5246
- https://bugzilla.mozilla.org/show_bug.cgi?id=2034534
data_reviews:
- https://github.com/mozilla/application-services/issues/5247
- https://github.com/mozilla/application-services/issues/5387
- https://github.com/mozilla/application-services/issues/5830
- https://github.com/mozilla/application-services/pull/7336
notification_emails:
- synced-client-integrations@mozilla.com
- bdk@mozilla.com
- jrediger@mozilla.com
expires: 2026-11-13
data_sensitivity:
- technical

run_maintenance_optimize_time_temp:
type: timing_distribution
description: |
Time taken to execute `PRAGMA optimize` inside `run_maintenance()`

Duplication of `run_maintenance_optimize_time` for glean-sym testing.
time_unit: millisecond
bugs:
- https://github.com/mozilla/application-services/issues/5246
- https://bugzilla.mozilla.org/show_bug.cgi?id=2034534
data_reviews:
- https://github.com/mozilla/application-services/issues/5247
- https://github.com/mozilla/application-services/issues/5387
- https://github.com/mozilla/application-services/issues/5830
- https://github.com/mozilla/application-services/pull/7336
notification_emails:
- synced-client-integrations@mozilla.com
- bdk@mozilla.com
- jrediger@mozilla.com
expires: 2026-11-13
data_sensitivity:
- technical

run_maintenance_chk_pnt_time_temp:
type: timing_distribution
description: |
Time taken to execute `PRAGMA_CHECKPOINT` inside `run_maintenance()`

Duplication of `run_maintenance_chk_pnt_time_temp` for glean-sym testing.
time_unit: millisecond
bugs:
- https://github.com/mozilla/application-services/issues/5246
- https://bugzilla.mozilla.org/show_bug.cgi?id=2034534
data_reviews:
- https://github.com/mozilla/application-services/issues/5247
- https://github.com/mozilla/application-services/issues/5387
- https://github.com/mozilla/application-services/issues/5830
- https://github.com/mozilla/application-services/pull/7336
notification_emails:
- synced-client-integrations@mozilla.com
- bdk@mozilla.com
- jrediger@mozilla.com
expires: 2026-11-13
data_sensitivity:
- technical
Loading
Loading