Commit graph

117 commits

Author SHA1 Message Date
pmcmanis
e63c563a0f Bug 1777638 - intermittent test failure caused by adding two cast values caused test result to fall below expected minimum r=chutten
Differential Revision: https://phabricator.services.mozilla.com/D155842
2022-08-29 14:29:07 +00:00
pmcmanis
9847bebbf2 Bug 1772537 - intermittent test failure caused by adding two numbers truncated by cast caused test value to fall below expected minimum r=chutten
Differential Revision: https://phabricator.services.mozilla.com/D155745
2022-08-29 14:29:07 +00:00
pmcmanis
709403b68a Bug 1780621 test size limits of updated Memory Distribution Accumulate r=Dexter
Also adds a small guardrail consistent with the implementation in Timing Distribution

Differential Revision: https://phabricator.services.mozilla.com/D153384
2022-08-03 14:52:16 +00:00
Norisz Fay
225a507f65 Backed out changeset 5fd037a32fc2 (bug 1780621) for causing xpcshell failures on test_GIFFT.js CLOSED TREE 2022-08-02 16:33:43 +03:00
pmcmanis
e744c1f7a6 Bug 1780621 test size limits of updated Memory Distribution Accumulate r=Dexter
Also adds a small guardrail consistent with the implementation in Timing Distribution

Differential Revision: https://phabricator.services.mozilla.com/D153384
2022-08-02 12:14:16 +00:00
Jan-Erik Rediger
94b2463ce2 Bug 1781030 - Upgrade to Glean v51.0.1. r=perry.mcmanis,supply-chain-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D152626
2022-08-01 10:50:47 +00:00
Joel Maher
bf4b875752 Bug 1781782 - Run frequent xpcshell parallel failing tests sequential by default. r=ahal,necko-reviewers,extension-reviewers,application-update-reviewers,bytesized,rpl,kershaw
Differential Revision: https://phabricator.services.mozilla.com/D153081
2022-07-30 01:33:28 +00:00
Chris H-C
8c397a412a Bug 1756057 - Write a rust-in-gtest instrumentation test for FOG r=janerik
Now that we're no longer testing FOG init instrumentation via rust-in-gtest, we
need a new thing to test in this manner or we'll delete this code and (in my
case) completely forget how we used to do this.

So let's replace the real instrumentation test with a boring one that doesn't
actually require all the boilerplate, but isn't harmed by it either.

Depends on D147450

Differential Revision: https://phabricator.services.mozilla.com/D147451
2022-07-20 14:54:58 +00:00
Chris H-C
3ab6f3551a Bug 1756057 - For GTest create FOGFixture for ensuring FOG is properly set up for your test case r=janerik
Depends on D147449

Differential Revision: https://phabricator.services.mozilla.com/D147450
2022-07-20 14:54:57 +00:00
Chris H-C
657d21502b Bug 1756057 - In GTest have FOG init when the runner runs, instead of in some random test r=janerik
Depends on D147448

Differential Revision: https://phabricator.services.mozilla.com/D147449
2022-07-20 14:54:57 +00:00
Chris H-C
464ec0c1df Bug 1756057 - Move FOG init instrumentation test to xpcshell. r=janerik
This instrumentation test has been disabled since bug 1763474 because delaying
init to this test meant that the preinit queue would overflow.

Because GoogleTest runs all at once and in its own decided order, we shouldn't
write any test that depends on FOG init happening at a specific time unless we
make it happen before the test suite even runs.

...and if we do that, the test resets that we perform in between will
obliterate the value in the init instrumentation, meaning we can't test it
anyway.

Note also that we skip-OK this test near local 4AM in case a properly-but-
inconveniently-timed "metrics" ping clears the value between FOG init and the
test run.

Now I thought we could put this in mochi, but it turns out that we reuse
browsers between test files. This means previous files' init of FOG and wiping
of all data causes the test to permafail when not run in isolation.

So here we are in xpcshell where we control init ourselves.

Differential Revision: https://phabricator.services.mozilla.com/D147448
2022-07-20 14:54:56 +00:00
smolnar
dbaa55f2e3 Backed out 4 changesets (bug 1756057) for causing xpc failures in toolkit/components/glean/tests/xpcshell/test_FOGInit.js CLOSED TREE
Backed out changeset 9a0c99591eb4 (bug 1756057)
Backed out changeset 414e2fb866f2 (bug 1756057)
Backed out changeset f56dc6857da7 (bug 1756057)
Backed out changeset 76096ec38942 (bug 1756057)
2022-07-18 18:51:20 +03:00
pmcmanis
564d06ab60 Bug 1696388 - Add tests for labled metric accessors including custom accessors for JS style accessors r=chutten
Differential Revision: https://phabricator.services.mozilla.com/D151922
2022-07-18 14:53:19 +00:00
Chris H-C
7b2f38b3b3 Bug 1756057 - Write a rust-in-gtest instrumentation test for FOG r=janerik
Now that we're no longer testing FOG init instrumentation via rust-in-gtest, we
need a new thing to test in this manner or we'll delete this code and (in my
case) completely forget how we used to do this.

So let's replace the real instrumentation test with a boring one that doesn't
actually require all the boilerplate, but isn't harmed by it either.

Depends on D147450

Differential Revision: https://phabricator.services.mozilla.com/D147451
2022-07-18 14:24:33 +00:00
Chris H-C
e11473aa2e Bug 1756057 - For GTest create FOGFixture for ensuring FOG is properly set up for your test case r=janerik
Depends on D147449

Differential Revision: https://phabricator.services.mozilla.com/D147450
2022-07-18 14:24:33 +00:00
Chris H-C
b4a877fed5 Bug 1756057 - In GTest have FOG init when the runner runs, instead of in some random test r=janerik
Depends on D147448

Differential Revision: https://phabricator.services.mozilla.com/D147449
2022-07-18 14:24:32 +00:00
Chris H-C
41067177bd Bug 1756057 - Move FOG init instrumentation test to xpcshell. r=janerik
This instrumentation test has been disabled since bug 1763474 because delaying
init to this test meant that the preinit queue would overflow.

Because GoogleTest runs all at once and in its own decided order, we shouldn't
write any test that depends on FOG init happening at a specific time unless we
make it happen before the test suite even runs.

...and if we do that, the test resets that we perform in between will
obliterate the value in the init instrumentation, meaning we can't test it
anyway.

Note also that we skip-OK this test near local 4AM in case a properly-but-
inconveniently-timed "metrics" ping clears the value between FOG init and the
test run.

Now I thought we could put this in mochi, but it turns out that we reuse
browsers between test files. This means previous files' init of FOG and wiping
of all data causes the test to permafail when not run in isolation.

So here we are in xpcshell where we control init ourselves.

Differential Revision: https://phabricator.services.mozilla.com/D147448
2022-07-18 14:24:32 +00:00
Tooru Fujisawa
54623364da Bug 1777486 - Part 2: Migrate XPCOMUtils.jsm consumers with automatic migration. r=webdriver-reviewers,geckoview-reviewers,preferences-reviewers,application-update-reviewers,pip-reviewers,kmag,owlish,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D151214
2022-07-12 04:21:34 +00:00
Andreea Pavel
7738a75fdd Backed out 11 changesets (Bug 1777486) for failing bc at browser_startup.js on a CLOSED TREE
Backed out changeset b6c4c386f1a6 (Bug 1777486)
Backed out changeset 195cc2de8433 (Bug 1777486)
Backed out changeset 20c746fb1648 (Bug 1777486)
Backed out changeset d5fd8173d62d (Bug 1777486)
Backed out changeset 6d758fab5a3e (Bug 1777486)
Backed out changeset e938b601ba15 (Bug 1777486)
Backed out changeset 0c4ea0b9416b (Bug 1777486)
Backed out changeset 0559c53cc668 (Bug 1777486)
Backed out changeset eea573d3a9f9 (Bug 1777486)
Backed out changeset 9ce3a6496a49 (bug 1777486)
Backed out changeset b0867652fc48 (bug 1777486)
2022-07-11 22:24:40 +03:00
Tooru Fujisawa
8cd6ed7409 Bug 1777486 - Part 2: Migrate XPCOMUtils.jsm consumers with automatic migration. r=webdriver-reviewers,geckoview-reviewers,preferences-reviewers,application-update-reviewers,pip-reviewers,kmag,owlish,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D151214
2022-07-11 15:09:13 +00:00
Tooru Fujisawa
bf93d07148 Bug 1667455 - Part 5: Stop importing Services.jsm from chrome-priv JS code, top-level single-line cases. r=kmag,webdriver-reviewers,perftest-reviewers,webcompat-reviewers,geckoview-reviewers,extension-reviewers,application-update-reviewers,pip-reviewers,twisniewski,m_kato,jdescottes,mconley,AlexandruIonescu,mossop
Differential Revision: https://phabricator.services.mozilla.com/D150894
2022-07-11 12:41:50 +00:00
pmcmanis
117485bdc9 Bug 1766515 - Implemented new glean Boolean error handling behavior on Labeled Booleans collected in Glean, and updated tests r=chutten
Differential Revision: https://phabricator.services.mozilla.com/D150493
2022-07-06 15:49:16 +00:00
Bogdan Szekely
6519e604a7 Backed out changeset 4dd17a60cad0 (bug 1766515) for causing xpcshell failures on test_JOG.js 2022-06-28 12:48:36 +03:00
pmcmanis
d779bb0acd Bug 1766515 - Implemented new glean Boolean error handling behavior on Labeled Booleans collected in Glean, and updated tests r=chutten
Differential Revision: https://phabricator.services.mozilla.com/D149569
2022-06-28 08:45:57 +00:00
Noemi Erli
9e7f8fbe32 Backed out changeset 37a07f2d420d (bug 1766515) for causing failures in test_GIFFT.js CLOSED TREE 2022-06-22 18:31:00 +03:00
pmcmanis
9240ee3749 Bug 1766515 - Implemented new glean Boolean error handling behavior on Labeled Booleans collected in Glean, and updated tests r=chutten
Differential Revision: https://phabricator.services.mozilla.com/D149569
2022-06-22 13:41:18 +00:00
Chris H-C
557f0cf57b Bug 1698184 - Test runtime registration of FOG metrics r=janerik
Adds a test-only method to JS that permits the runtime registration of metrics.
Also uses that to cover JOG with tests: registering and smoke-testing metrics
of each metric type.
(Events being a notable (temporary) exception)

Instead of writing parsers, use serde_json for the optional extra metric args.

Differential Revision: https://phabricator.services.mozilla.com/D143051
2022-06-21 20:34:56 +00:00
Chris H-C
6a8e5cb0fb Bug 1698184 - Move submetrics to 2^25 to make room for dynamic metrics r=janerik
Previously we used the 27th bit to signal if a metric instance was actually a
labeled_* metric's "submetric". This bit is actually part of the metric type
part of the lower (upper?) 32 bits of the metric_entry_t, but that was okay
because builtin metrics all have their top 5 bits scrubbed.

itsFreeRealEstate.jpg

This can no longer work, though, since JOG will need to be able to have its
own submetrics that don't conflict _and_ will need to keep the type bits
around so we know what instances to build.

(( Yes, yes, I could've designed the system so that we didn't need to,
but this was the less complicated way. We can go down this route when we
provision the 34 Millionth metric and run out of space. ))

So that means taking two bits away from the id portion: one for runtime (we'll
give it 2^26) and one for submetric (2^25).

Differential Revision: https://phabricator.services.mozilla.com/D143044
2022-06-21 20:34:52 +00:00
Chris H-C
df8e663426 Bug 1771348 - Bolster FOG IPC test against timing intermittents r=janerik
Differential Revision: https://phabricator.services.mozilla.com/D148315
2022-06-20 14:58:18 +00:00
Chris H-C
0e4b106ace Bug 1774847 - Fix TV intermittent event leak testfail r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D149667
2022-06-20 14:07:45 +00:00
Emilio Cobos Álvarez
f78640597e Bug 1774489 - Fix fog event test APIs to not leak. r=chutten
This is also simpler.

Differential Revision: https://phabricator.services.mozilla.com/D149638
2022-06-17 15:58:18 +00:00
Csoregi Natalia
8662f38c59 Backed out 4 changesets (bug 1756057) for failures on browser_fog_init.js. CLOSED TREE
Backed out changeset afeabbc80268 (bug 1756057)
Backed out changeset 1db54f4136a2 (bug 1756057)
Backed out changeset 9364dd7f20bb (bug 1756057)
Backed out changeset f7f1f73d38cd (bug 1756057)
2022-06-15 18:53:17 +03:00
Chris H-C
46b27ef663 Bug 1756057 - Write a rust-in-gtest instrumentation test for FOG r=janerik
Now that we're no longer testing FOG init instrumentation via rust-in-gtest, we
need a new thing to test in this manner or we'll delete this code and (in my
case) completely forget how we used to do this.

So let's replace the real instrumentation test with a boring one that doesn't
actually require all the boilerplate, but isn't harmed by it either.

Differential Revision: https://phabricator.services.mozilla.com/D147451
2022-06-15 14:59:15 +00:00
Chris H-C
543cd1408e Bug 1756057 - For GTest create FOGFixture for ensuring FOG is properly set up for your test case r=janerik
Differential Revision: https://phabricator.services.mozilla.com/D147450
2022-06-15 14:59:13 +00:00
Chris H-C
bc56340a4f Bug 1756057 - In GTest have FOG init when the runner runs, instead of in some random test r=janerik
Depends on D147448

Differential Revision: https://phabricator.services.mozilla.com/D147449
2022-06-15 14:59:12 +00:00
Chris H-C
cbc469a5c2 Bug 1756057 - Move FOG init instrumentation test to mochi. r=janerik
This instrumentation test has been disabled since bug 1763474 because delaying
init to this test meant that the preinit queue would overflow.

Because GoogleTest runs all at once and in its own decided order, we shouldn't
write any test that depends on FOG init happening at a specific time unless we
make it happen before the test suite even runs.

...and if we do that, the test resets that we perform in between will
obliterate the value in the init instrumentation, meaning we can't test it
anyway.

So let's test this instrumentation in mochi where there's a little more...
control? Certainty, anyway, about how often test resets happen (never) and
whether FOG init happens (it does).

The only thing we then have to worry about that could delete this information
before we can test it is an ill-timed "metrics" ping being sent. Which is why
we skip the test between the hours of 3AM and 5AM (local).

Differential Revision: https://phabricator.services.mozilla.com/D147448
2022-06-15 14:59:11 +00:00
Jan-Erik Rediger
8182bee632 Bug 1768834 - Switch to Glean with UniFFI integration r=glandium,chutten
Upgrades to Glean v50.0.1, which comes with a rewritten core and
UniFFI-powered bindings.
Glean has some API changes, so we swap it over to that. Mostly mechanical changes.
Also upgrades to inherent v1.0 in fog.
This matches what Glean uses internally and gets rid of one duplicated crate.

Also upgrades to glean-parser==6.0.1

One crate duplication now (change in `python/mozbuild/mozbuild/vendor/vendor_rust.py` required).
Some new crates now vendored.
These are transitive dependencies of Glean dependencies, all with valid
licenses and already used in other products (mobile).

Differential Revision: https://phabricator.services.mozilla.com/D146062
2022-06-07 12:37:20 +00:00
Tooru Fujisawa
27b6845115 Bug 1772313 - Part 1: Remove duplicate lazy getter vs import in toolkit/components/glean/. r=kmag
Differential Revision: https://phabricator.services.mozilla.com/D148154
2022-06-06 04:42:04 +00:00
Molnar Sandor
77402a5caa Backed out 15 changesets (bug 1772313, bug 1772351, bug 1772360) for causing xpc failures in telemetry/tests/unit/test_SocketScalars.js CLOSED TREE
Backed out changeset c8b0a2ed239e (bug 1772360)
Backed out changeset 1922adad6abe (bug 1772351)
Backed out changeset 6d3634cce489 (bug 1772351)
Backed out changeset f03968a9d053 (bug 1772351)
Backed out changeset e7a38ef90fe4 (bug 1772351)
Backed out changeset b389e7654771 (bug 1772313)
Backed out changeset 59a33598ff51 (bug 1772313)
Backed out changeset ab60885a8a93 (bug 1772313)
Backed out changeset aad8efac9d05 (bug 1772313)
Backed out changeset 4378e519a8e7 (bug 1772313)
Backed out changeset 302ac54741f8 (bug 1772313)
Backed out changeset 74c59f9fd51c (bug 1772313)
Backed out changeset 575fb877c56c (bug 1772313)
Backed out changeset 2eaa68f10b19 (bug 1772313)
Backed out changeset 4a8b3ba193dc (bug 1772313)
2022-06-06 07:04:25 +03:00
Tooru Fujisawa
c04d365cc6 Bug 1772313 - Part 1: Remove duplicate lazy getter vs import in toolkit/components/glean/. r=kmag
Differential Revision: https://phabricator.services.mozilla.com/D148154
2022-06-06 02:49:08 +00:00
Chris H-C
bf32c3eb40 Bug 1768714 - Use add_setup for setup task in FOG xpcshell tests r=Dexter
Differential Revision: https://phabricator.services.mozilla.com/D147431
2022-05-26 15:32:32 +00:00
Chris H-C
14fee064de Bug 1768636 - Scope GIFFT timer maps to metrics r=TravisLong
TimerIds are only unique for a given metric, not globally.

Differential Revision: https://phabricator.services.mozilla.com/D145988
2022-05-10 20:38:30 +00:00
Chris H-C
94867a6ae6 Bug 1763235 - Update metrics.yamls to file-level tags, new front matter r=perry.mcmanis,application-update-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D145141
2022-05-04 14:16:19 +00:00
Chris H-C
e1a0c33051 Bug 1763235 - Enforce lexicographical order of glean definitions files in index r=perry.mcmanis
Differential Revision: https://phabricator.services.mozilla.com/D145140
2022-05-04 14:16:18 +00:00
Alessio Placitelli
80ec444c16 Bug 1766980 - Add test coverage for the URL FOG type. r=chutten
This adds the required test coverage for the new type
and updates the GIFFT docs.

Depends on D145215

Differential Revision: https://phabricator.services.mozilla.com/D145216
2022-05-02 16:05:56 +00:00
Florian Quèze
34c0c5a32a Bug 1763474 - Report thread wake-ups and CPU time per thread through glean, r=gerald,chutten
Differential Revision: https://phabricator.services.mozilla.com/D141147
2022-04-23 11:38:19 +00:00
Chris H-C
e3d4d5098d Bug 1763593 - Bypass NS_DispatchToMainThread's assert while handling the leak. r=TravisLong
Differential Revision: https://phabricator.services.mozilla.com/D144175
2022-04-21 20:57:41 +00:00
Chris H-C
bb93306954 Bug 1763593 - Clear the map immediately if already late in shutdown r=TravisLong
Differential Revision: https://phabricator.services.mozilla.com/D144174
2022-04-21 20:57:41 +00:00
Chris H-C
80631a305a Bug 1763593 - GIFFT mirroring is now fallible r=janerik
We need to clear state at shutdown that we hold for GIFFT mirroring purposes.
However, more data can come in even later (there's nothing stopping it. Plus,
Glean can meaningfully record later given its shutdown happens in a later
phase), so the naive approach of lazy-instantiate and RunOnShutdown-clear
doesn't work.

Since Telemetry is only good to AppShutdownTelemetry, we now fail to mirror to
it after AppShutdownTelemetry and clear state in the immediately-next phase.

Also, data can come in earlier than we have a main thread to dispatch to,
requiring some careful finagling of threads to ensure our cleanup routine
is appropriately registered.

Differential Revision: https://phabricator.services.mozilla.com/D143522
2022-04-14 15:17:29 +00:00
Chris H-C
e8dc037828 Bug 1759863 - Test new timing_distribution raw API r=TravisLong,bas
And document it.

Depends on D142290

Differential Revision: https://phabricator.services.mozilla.com/D142465
2022-03-31 20:17:03 +00:00