Граф коммитов

4676 Коммитов

Автор SHA1 Сообщение Дата
Jan-Erik Rediger 231a1e50b1 Remove already-deprecated JWE metric.
It's already disabled in the glean_parser and thus cannot be used
anyway.
2022-01-18 18:29:07 +01:00
Jan-Erik Rediger d32bb60065 [UniFFI] Migrate UUID metric type implementation
This requires a wrapper to transform it into the correct types
2022-01-18 18:29:07 +01:00
Jan-Erik Rediger 18e1b912bb [UniFFI] Migrate URL metric type implementation 2022-01-18 18:29:07 +01:00
Jan-Erik Rediger e6bc916439 [UniFFI] Migrate string list metric implementation 2022-01-18 18:29:07 +01:00
Jan-Erik Rediger 61779c1c9f [UniFFI] Migrate string metric implementation 2022-01-18 18:29:07 +01:00
Jan-Erik Rediger 2349905006 Port labeled submetric caching to new UniFFI-powered labeled metrics
This was added in glean-ffi after the recent crashes we encountered.
UniFFI already handles this by using `Arc`, this now adds proper
re-usage of the created `Arc`-wrapped metrics.
2022-01-18 16:37:45 +01:00
Jan-Erik Rediger bbef390a66 [UniFFI] Migrate labeled counters & boolean implementation 2022-01-18 16:37:45 +01:00
Jan-Erik Rediger 41f3d70e7c [UniFFI] Migrate boolean metric implementation 2021-12-13 15:44:25 +01:00
Jan-Erik Rediger dd8056d2aa [UniFFI] Migrate timespan metric implementation 2021-12-13 15:43:38 +01:00
Jan-Erik Rediger c5f9686bab Re-export internal enums and classes for use in the public API
These will only start making sense when they are actually added in the
UDL file, which will come along in later commits.
2021-12-13 15:41:43 +01:00
Jan-Erik Rediger e3914280e8 Re-export UniFFI-generated types 2021-12-13 15:41:43 +01:00
Jan-Erik Rediger 38cad9c168 Upgrade to UniFFI 0.15.2 2021-12-13 15:41:43 +01:00
Jan-Erik Rediger 126e3bdcbd
Merge pull request #1868 from mozilla/uniffi-merge-back-with-glean-core 2021-11-23 16:30:32 +01:00
Jan-Erik Rediger 0a607203fd [Kotlin] Use new counter metric in ping type tests
This should make them compile and pass.
2021-11-23 16:25:55 +01:00
Jan-Erik Rediger 0a5ca255e9 [Kotlin] Track testing mode to ensure intended MPS behavior 2021-11-23 16:25:55 +01:00
Jan-Erik Rediger db621820b1 [Rust] Make sure to trigger upload when a ping was submitted. 2021-11-23 16:25:55 +01:00
Jan-Erik Rediger 994fc6edd4 [Kotlin, Rust] Signal when the MPS submits a ping so we can upload it
This allows to only trigger ping upload if we know a ping was submitted.
2021-11-23 16:25:55 +01:00
Jan-Erik Rediger cbcdb618ac [Kotlin] Use new counter metric in tests
This starts using the UniFFI-exported Counter metric under a different
name for now.
The CounterMetricTypeTest pass with this.
2021-11-23 16:25:55 +01:00
Jan-Erik Rediger 7ba6878e7f [Rust] Store state on whether we're still queueing
This is really only relevant for testing mode, but still necessary for
correct inner workings.
2021-11-23 16:25:55 +01:00
Jan-Erik Rediger c0ca905c1a [Kotlin] Always skip the first metrics ping in tests with the GleanTestRule
Tests should explicitly destroy Glean and recreate it to test the metrics ping scheduler.
This is the same as `delayMetricsPing` from `TestUtils.kt`,
but now part of the publicly available test rule.
2021-11-23 16:25:54 +01:00
Jan-Erik Rediger ce35f312bf [Kotlin, Rust] Enable most high-level Glean tests 2021-11-23 16:25:54 +01:00
Jan-Erik Rediger dd6aadee34 [Kotlin] Don't record preinitTasksOverflow in Kotlin dispatcher
The API changed, so this doesn't compile.
The Kotlin dispatcher is going away soon.
2021-11-23 16:25:54 +01:00
Jan-Erik Rediger 738f347d6d [build] Use modified glean-parser 2021-11-23 16:25:54 +01:00
Jan-Erik Rediger 9c843ec279 [Kotlin, Rust] Enable upload process through new API 2021-11-23 16:25:54 +01:00
Jan-Erik Rediger 7cc543ed1b [build] Allow unsigned types and operations on them
This is required due to how we pass the request around for the uploader
2021-11-23 16:25:54 +01:00
Jan-Erik Rediger 23fe625876 [Rust] Run tasks right away on the dispatcher in test mode 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 4f024a9718 [Rust] Register built-in pings during initialization in Rust
Currently they don't auto-register, because that would block in tests.
Need to figure out how to properly do that.
2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 587a09527b [Kotlin, Rust] Provide ability to enable test mode for the dispatcher
In test mode the dispatcher will dispatch tasks but wait for them to
finish before returning, making their work essentially synchronous
2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 71848377ac [build] Don't format generated code on build 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger a8e3ebe8d1 [Kotlin, Rust] Expose ping type to Kotlin, backed fully by Rust 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 279456c220 [Kotlin, Rust] Allow destroying the Glean object for testing 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 3d30fc0db1 [Kotlin] Remove internal-test-only API
Testing if ping objects exists should happen inside the glean-core crate.
Getting a ping's JSON does not need to be exposed to the foreign language.
We have other tests that do this through a mock ping server instead.
2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 23d2a97d48 [Kotlin, Rust] Implement ping submission API 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 00989cfdb3 [Swift] Implement new initialize 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 9c6c59a55d [uniffi] Use correct cdylib name in UniFFI config 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger adbc8f7370 [Rust] Remove all of the glean-uniffi crate
This is now handled in glean-core fully
2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 5d4a40e9d8 [Rust] Correctly disable upload policies in tests again 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger de64da56f9 [Rust] Disable glean-core example for now 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger ecfdad0f3b [Rust] Get tests to compile & run 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 348df40833 [Rust] Implement timespan asynchronously 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 43d7dd115e [build] Start using UniFFI for the glean-core crate 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger b9da4a9776 [Rust] Split the glean-core crate into the user-facing part and internal implementation 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 7d91181cf7 [Rust] Rename string API to make it clear it's sync
The user-facing async API will follow
2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 584120927a [Rust] Port over arch and os version from the RLB 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 378fc05a23 [Rust] Add additional dependencies 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 27e1c2ad13 [Rust] Implement Experiments properly 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 5bc94bff0a [Rust] Cleanup: Move constant into the right module 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 9465806d14 [Rust] Cleanup: Move the macro to where it is used 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger 3c43f2c90a [Rust] Add dispatcher, copied from the RLB 2021-11-23 16:24:10 +01:00
Jan-Erik Rediger c00349d0dd [Rust] Handle labeled metrics with trait methods 2021-11-23 16:24:10 +01:00