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

104 Коммитов

Автор SHA1 Сообщение Дата
Winnie Chan 61b9b2ffe3
DENG-772: Fenix population with first_session ping and min seq (#4090)
* Changed to min seq and capture null seq
2023-07-28 08:55:39 -07:00
Eduardo Filho 25d4ab4042
Bug 1844886: Add non-norm cols to glam scalar tbls (#4111)
* Add non-norm cols to scalar tbls

* Add missing schema to scalar_percentiles_v1

* Add missing schema to scalar_percentiles_v1
2023-07-25 11:13:20 -04:00
Eduardo Filho 144a508ee6
Glam non norm agg (#3873)
* glam: Partition clients_histogram_aggregates by sample_id (has been running like this since April 3 from a different branch)

* glam: Non normalized aggregations to legacy histograms

* glam: add non-normalized aggs to probe counts extract

* glam: add init.sql to relevant tbls for non-norm aggs

* glam: ignore dryrun histogram_percentiles

* glam: add description and eol to init

* glam: Partition clients_histogram_aggregates by sample_id (has been running like this since April 3 from a different branch)

* glam: Non normalized aggregations to legacy histograms

* glam: add non-normalized aggs to probe counts extract

* glam: add init.sql to relevant tbls for non-norm aggs

* glam: ignore dryrun histogram_percentiles

* glam: add description and eol to init

* fix schema files

* fix clients_histogram_probe_counts schema

* remove another init.sql

* fix dryrun ignore order

* fix table name

* change dryrun ignore order to try avoiding fenix for being on path

* another change in dryrun

* Move glam queries from dryrun to bqetl_project.yaml to ignore

* add tbl deps on tests
2023-07-19 17:01:58 -04:00
Rebecca BurWei 4ffdb8484a
Add has_adblocker_addon to search_clients_daily (#3558)
* feat: adblocker addons field

* Update sql/moz-fx-data-shared-prod/search_derived/search_clients_daily_v8/query.sql

Co-authored-by: Curtis Morales <cmorales@mozilla.com>

* fix: use private table

* fix: where clause for private table

* Reference static addons table

* Switch to new monetization_blocking_addons table

* Drop project name in reference to monetization_blocking_addons

* Don't dry-run search_clients_daily

* Add has_adblocker_addons to search_clients_daily_v8 tests

---------

Co-authored-by: Curtis Morales <cmorales@mozilla.com>
2023-07-19 12:04:38 -04:00
Sean Rose a4fdf3c65e
Include new fields for SubPlat in FxA events views (DENG-1006) (#3926)
* Include new fields for SubPlat in `fxa_content_auth_stdout_events`.

* Include new fields for SubPlat in `nonprod_fxa_content_auth_stdout_events`.

* Include new fields for SubPlat in `fxa_all_events`.

* Move new `time` column to be by the other timestamp columns.

* Keep `subscribed_plan_ids` as a string so it's accessible in Looker.

* Add `schema.yaml` files for FxA events ETLs.

So the tables can be successfully staged for CI for downstream ETLs/views to pass.

* Fully qualify view in `fxa_users_daily_v1` to try to get test to pass.

* Rename `time` column `event_time`.

* Include new fields for SubPlat in `nonprod_fxa_all_events`.

---------

Co-authored-by: Daniel Thorn <dthorn@mozilla.com>
2023-06-23 15:41:13 +00:00
Alexander 8423c7ad2e
Use baseline_clients_daily instead of ping and first_seen for fenix_android_clients (#3910)
* Change source for first_seen and baseline to baseline_clients_daily

* Edit tests and schemas

* Update to fenix.baseline_clients_daily
2023-06-08 14:50:14 +00:00
Alexander 505c895f62
GROWTH-41 Add last_seen columns to firefox_android_clients (#3863)
* Added last_reported columns

* Fixed tests

* Added missing locale field
2023-06-05 16:37:59 +00:00
Lucia cbe42ab9a9
Deng 850 firefox android clients reported ping (#3789)
* DENG-850 Retrieve FALSE instead of NULL in the in metadata when there isn't first_session or metrics ping.

* DENG-850 Unitest for no first session ping.

* DENG-850 syntax fix

* DENG-850 Tests for first session ping, and no baseline ping.

* DENG-850 Tests suite.

* DENG-850 YAML fixes.

* DENG-850 Adjustment to the case of reported first_session and metrics ping. The unitests are adjusted to get the value for reported pings.

* DENG-850 Add sample id to test.

---------

Co-authored-by: Lucia Vargas <lvargas@mozilla.com>
2023-05-26 12:50:08 +02:00
Alexander db604e4b3d
DENG-796 - newtab_visits (#3762)
Add new table - Newtab Visits
2023-05-25 09:32:25 -04:00
Glenda Leonard a31072d408
DENG-775 downloads_with_attribution_v2 (#3716)
* DENG-775 Added session_id to JOIN between GA data and stub_attr.stdout.  Also expanded date range on GA session data to [download_date - 2 days, download_date + 1 day]

* Updated query to handle missing GA download_session_id.  It effectively applies V1 logic to the MISSING_GA_CLIENT dl_tokens.
2023-04-26 14:47:34 -04:00
Anna Scholtz 48d8c7603d
Metric hub integration - rewrite SSL ratios to use metrics (#3698)
* Add metrics.data_source()

* Rewrite SSL ratios to use metrics

* Fix docs formatting
2023-04-04 15:41:44 -07:00
Glenda Leonard b13f45bc63
DENG-658 - Initial table definitions for dl_token processing. (#3644)
* Initial table definitions for dl_token processing.  Includes update to sql pytest_plugin to account for tablenames with date suffixes.

* Removed cluster reference and shortened description

* Added sql/moz-fx-data-marketing-prod/ga_derived/downloads_with_attribution_v1/query.sql to dryrun skip

* Added time_on_site

* Moved country_names sample test data file.

* Update bigquery_etl/pytest_plugin/sql.py

Co-authored-by: Daniel Thorn <dthorn@mozilla.com>

* Update sql/moz-fx-data-marketing-prod/ga_derived/downloads_with_attribution_v1/query.sql

Co-authored-by: Frank Bertsch <frank.bertsch@gmail.com>

* Update sql/moz-fx-data-marketing-prod/ga_derived/downloads_with_attribution_v1/query.sql

Co-authored-by: Frank Bertsch <frank.bertsch@gmail.com>

* Updated based on PR feedback.  Added LEFT JOIN to ensure sessions without pageviews are not dropped.

* Set has_ga_download_event = null if exception=GA_UNRESOLVABLE

* Standardized logic for time_on_site

* - Added test for multiple downloads for 1 session
- Added detailed description of table.

* Updated to use mode_last_retain_nulls instead of ANY_VALUE

* Set pageviews, unique_pageviews = 0 if null.

* Added boolean additional_download_occurred to indicate if another download occurred in the same session.

---------

Co-authored-by: Daniel Thorn <dthorn@mozilla.com>
Co-authored-by: Frank Bertsch <frank.bertsch@gmail.com>
2023-03-23 16:45:58 -04:00
kik-kik ed1317cb7d
bug(): added org_mozilla_firefox_derived/client_deduplication_v1 to dry run skip (#3667)
* added org_mozilla_firefox_derived/client_deduplication_v1 to dry run skip

* fixing fxa_users_daily_v1 test
2023-03-16 15:42:04 +00:00
Rebecca BurWei 26366152b9
RS-595 (#3518)
* feat: new field in search clients daily - is_sap_monetizable

* Added column to tests

---------

Co-authored-by: Alexander Nicholson <anicholson@mozilla.com>
2023-03-10 12:38:52 -05:00
Alexander 60c85e7c54
Revert CI changes for private UDFs and add stub documentation - DENG-735 (#3652)
* Revert "CI fixes for supporting private UDFs in bigquery-etl - DENG-735 (#3631)"

This reverts commit edcfe758f7.

* Added stub UDF for monetized_search

* Add docs for using a private internal UDF
2023-03-10 11:41:46 -05:00
Alexander edcfe758f7
CI fixes for supporting private UDFs in bigquery-etl - DENG-735 (#3631)
* Minimize stub normalize_search_engine UDF and usage in search_clients_last_seen tests
* Move sql tests downstream of private-generate-sql and copy UDFs into sql-dir for tests
2023-03-09 16:54:42 -05:00
m-d-bowerman 69c0c1d5fc
[DS-2566] Add sidebar search probes to clients_daily tables (#3629)
* Add sidebar search probes to clients_daily tables

* update downstream schemas

* Format fix

* Add new field to test

* Update schemas with hist fields

* Remove duplicated field from schema

---------

Co-authored-by: Glenda Leonard <75265513+gleonard-m@users.noreply.github.com>
2023-03-08 18:14:58 -05:00
Leli 05975e88ff
Fivetran remove dev (#3619)
* remove dev destination

* fivetran - daily_connector_costs restructure CTEs for clearer GROUP BY
2023-03-02 13:00:48 +01:00
Leli 5aebf9cae9
fivetran costs change tables (#3599)
* fivetran costs change tables

* fivetran costs - incorporate code review

* fivetran costs - change monthly_costs back to coalesce

* fivetran costs - fix query
2023-02-27 19:26:21 +01:00
Leli 5108c2d307
add daily_active_rows to fivetran_costs (#3570)
* add daily_active_rows to fivetran_costs

* regenerate dag

* regenerate dag with black 23.1.0
2023-02-08 13:45:49 +01:00
Daniel Thorn ac053c326a
Update dependencies missed by dependabot (#3566) 2023-02-06 12:14:32 -08:00
Curtis Morales 570f3bbab3
Fix urlbar_clients_daily_v1 (#3549)
* Fix urlbar_clients_daily_v1

* Rename test file

* Fix new name

* Rename one more test case file
2023-02-01 10:57:57 -05:00
Leli d161c02ef1
Fix Fivetran Costs calculations (#3547)
* Add fivetran_costs

* Add fivetran_costs - adding schemas to all tables and adressing other suggestions

* Add fivetran_costs - renaming tables, adding to the schema

* Add fivetran_costs - adding fivetran-dev

* Add fivetran_costs - adding tests

* Add fivetran_costs - adding tests

* Add fivetran_costs - adding tests

* Add fivetran_costs - adding tests

* implementing suggestions

* rerun dag creation

* fixing the tests

* fixing errors

* change position of rounding
2023-02-01 13:30:09 +01:00
Leli 8b0158c8dc
Add fivetran_costs (#3509)
* Add fivetran_costs

* Add fivetran_costs - adding schemas to all tables and adressing other suggestions

* Add fivetran_costs - renaming tables, adding to the schema

* Add fivetran_costs - adding fivetran-dev

* Add fivetran_costs - adding tests

* Add fivetran_costs - adding tests

* Add fivetran_costs - adding tests

* Add fivetran_costs - adding tests

* implementing suggestions

* rerun dag creation
2023-01-31 16:27:29 +01:00
kik-kik 794ae7b22e Update sql/moz-fx-data-shared-prod/firefox_accounts_derived/funnel_events_source_v1/query.sql
Co-authored-by: Sean Rose <1994030+sean-rose@users.noreply.github.com>
2022-12-15 13:11:07 +01:00
Chelsea Troy a1a155a22f
Add urlbar_persisted to query for daily search client table (#3349)
* Add urlbar_persisted to query for daily search client table

* Add column to schema (not backward breaking)

* Address test expectations

* Update schemata and queries for companion tables

* Make adjustments that Alex identified in the PR to make sure the new fields get ingested properly

* Run schema update for clients_daily_v6
2022-12-05 15:33:43 -05:00
Anna Scholtz a05e0dd80c Update event_aggregates_v1 tests 2022-11-17 08:34:36 -08:00
Alekhya 56983f3e8d
Add Glean iOS Focus and Klar to search metrics (#3285)
correct the column for default search engine

add tests and  ios to views
2022-10-18 13:52:53 -04:00
Frank Bertsch ce992ca411
Bug 1791580 - Add qualified use to clients_last_seen (#3232)
* Bug 1791580 - Add qualified use to clients_last_seen

* Add new fields for private/normal browsing URIs

* Update clients_last_seen_joined schema

* Reformat view

* Update and extend tests
2022-10-11 09:27:40 -04:00
Alexander 588d468dc8
Hoist schemas in SQL tests up to table dir (#3145) 2022-08-17 13:11:24 -04:00
wil stuckey 4034b1a93d
Update table declarations to include session_id, sequence_no in sanitized and impression tables (#3092)
Co-authored-by: whd <whd@users.noreply.github.com>
2022-08-09 16:40:09 +00:00
Nan Jiang 2b67d988d7
CONSVC 1898: Add suggest_data_sharing_enabled to event_aggregates (#3116) 2022-07-26 16:55:49 -04:00
Alexander f99f112336
Android Focus search ETL - DO-824, Bug 1749833 (#2682)
Added glean data for Focus on Android to `mobile_search_clients_daily_v1`
2022-07-26 16:25:32 -04:00
Nan Jiang 8aa9596ff4
CONSVC 1813: Include iOS data into Contextual Services derived dataset (#3049) 2022-06-30 11:05:04 -04:00
wil stuckey a78127a050
#1775029 Update the suggest_impression_sanitized_v3 query (#3041)
* Update the suggest_impression_sanitized_v3 query

* exclude region and country when preparing for the join
* filter `impressions.request_id` to non null to drop queries without a
  corresponding impression.
* Add tests? Haven't figured out bootstraping issues on my M1 yet so not
  sure how well these will work. TO CI!

* Swap the left and right and remove the conditional on the final join

* Align expectations

* Will this fix the tests? tune in to find out.

* Fix expectations AGAIN

* Update based on review comments and formatter changes
2022-06-23 15:50:16 +00:00
Anna Scholtz 2f5c6ac41a Generate ExternalTaskMarkers for Airflow downstream dependencies 2022-06-22 11:05:25 -07:00
akkomar ceda6dd35f
Use approximate client count in GLAM scalar_percentiles_v1 (#3039)
This is a follow-up to https://github.com/mozilla/bigquery-etl/pull/3037 which unblocked `scalar_bucket_counts_v1`.
`scalar_percentiles_v1` uses the same source table (`clients_scalar_aggregates_v1`) and started failing today with the same error (disk/memory limits exceeded for shuffle operations).

`APPROX_COUNT_DISTINCT` used here runs HLL under the hood. The reason for using it here is that we can't split the aggregation here into two stages as in the aforementioned PR due to quantiles calculation.

I have run this query locally and confirmed that it works.
2022-06-21 10:55:08 -04:00
Nan Jiang 97f676cc8e
CONSVC 1800: Add os to the Contextual Services derived dataset (#3027)
* CONSVC 1800: Add os to the Contextual Services derived dataset

* Review fixes

Co-authored-by: Jeff Klukas <jklukas@mozilla.com>
2022-06-16 23:31:17 +00:00
Nan Jiang e4b180dbbc
Bug 1757768 (follow-up): Fix test failures (#3017) 2022-06-13 21:34:04 +00:00
Nan Jiang 44399cd7af
Bug 1757768: add match_type to contextual services derived dataset (#2897)
* Bug 1757768: add match_type to contextual services derived dataset

* f test
2022-06-08 17:52:41 +00:00
Rebecca BurWei 997708a74f
Add country to urlbar_clients_daily (#3009)
* Add country to urlbar_clients_daily
2022-06-03 15:26:59 -04:00
Jeff Klukas 3db4633376
CONSVC-1681 Add mobile data to contextual services event_aggregates (#2805)
* CONSVC-1681 Add mobile data to contextual services event_aggregates

See https://mozilla-hub.atlassian.net/browse/CONSVC-1681

* Use 'phone' instead of 'mobile'

* Update init.sql

* Commentary on filter

* Aggregation test update

* Update overactive filter test

* Dry run exemptions

* Update sql/moz-fx-data-shared-prod/contextual_services_derived/event_aggregates_v1/query.sql

* format
2022-03-31 10:53:29 -04:00
Rebecca BurWei 78885a77dd
Add experiments field from clients_daily to urlbar_clients_daily (#2814)
* Add experiments field

* Updated urlbar_clients_daily schema

* Updated tests

Co-authored-by: Jeff Klukas <jklukas@mozilla.com>
Co-authored-by: Alexander Nicholson <anicholson@mozilla.com>
2022-03-23 16:48:16 -04:00
Alekhya a76cd01efa
add minimum client count for fenix (#2642)
add minimum client count for fenix

add minimum client count for fenix

add minimum client count for fenix

add minimum client count for fenix
2022-01-12 11:49:59 -05:00
Alekhya 4b178bc49b
Minimum client counts (#2628)
* added minimum client count for desktop

added minimum client count for desktop

added minimum client count for desktop

added minimum client count for desktop

added minimum client count for desktop

* Update the sql query

* Updated the total_users > 375 than 100
2022-01-06 14:50:29 -05:00
Jeff Klukas 59e16919aa
Lowercase and trim in suggest_impressions_sanitized_v2 (#2581)
This better matches the current client behavior for matching.
We're currently getting `<disallowed>` in results and results with uppercase
letters. I don't think preserving these differences has analytical value,
and it makes the results harder to work with.
2021-12-16 08:16:19 -05:00
Jeff Klukas ec7e68f213
ROAD-85 Simple sanitization job for Merino logs (#2522)
* ROAD-85 Simple sanitization job for Merino logs

See https://mozilla-hub.atlassian.net/browse/ROAD-85

This uses the adM allowlist of queries for sanitization, so can be expressed
entirely in a single query. Future iterations will involve python logic and
will likely need to be held elsewhere.

* Separate external query and query to copy data into shared-prod
2021-12-14 16:18:24 -05:00
Alekhya 2f1413fee1
Revert "correcting minimum client count - desktop and fenix (#2544)" (#2566)
This reverts commit 5b743090b4.
2021-12-10 10:15:52 -05:00
Alekhya 5b743090b4
correcting minimum client count - desktop and fenix (#2544)
* correcting minimum client count - desktop and fenix

* corrected test cases for desktop

* corrected the join for desktop
2021-12-06 10:14:42 -05:00
Alexander Nicholson 48d3ac3f60
Bug 1742183 Added iOS probes to mobile_search_clients_daily (#2526) 2021-11-25 17:19:49 -05:00