Bigquery ETL
Перейти к файлу
kik-kik 055a5d96a6
pushing bqetl acoustic dags by 1 hour to see if that resolves sensor issues (#3002)
2022-06-02 15:18:41 +02:00
.circleci Remove redundant GOOGLE_APPLICATION_CREDENTIALS in integration (#2973) 2022-05-16 19:53:50 +00:00
.github Add CODEOWNERS and restricted access datasets documentation (#2524) 2021-12-21 20:25:05 +00:00
.vscode Remove .vscode settings and add to gitignore (#1929) 2021-03-30 12:25:05 -04:00
bigquery_etl DSRE-775 Add support for Rally Web Platform unenrollment ping in Shredder (#3001) 2022-06-01 19:59:19 +00:00
dags pushing bqetl acoustic dags by 1 hour to see if that resolves sensor issues (#3002) 2022-06-02 15:18:41 +02:00
docs removed link to Google Docs as public should not try to access it (#3000) 2022-06-01 14:45:37 +00:00
script Remove redundant GOOGLE_APPLICATION_CREDENTIALS in integration (#2973) 2022-05-16 19:53:50 +00:00
sql Decision support metrics for fog initial commit (#2984) 2022-06-01 16:00:29 -05:00
sql_generators Handle duplicates for fennec for baseline_clients_first_seen 2022-05-06 16:53:25 -07:00
src/main/java/com/mozilla/telemetry Reapply "Update to zetasql 2022.02.1 (#2862)" (#2881) 2022-04-07 14:02:20 -07:00
stored_procedures Improvements for CRC32 stored procedure 2020-01-21 14:58:24 -08:00
tests Remove support for importing stripe resources in favor of fivetran (#2815) 2022-04-19 16:15:15 -07:00
.bigqueryrc Create ~/.bigqueryrc without GCLOUD_SERVICE_KEY (#112) 2019-05-01 13:38:31 -07:00
.dockerignore Use zetasql to get dependencies for dag generation (#1817) 2021-02-18 17:49:46 -05:00
.eslintrc.yml Ran YAMLlint on all yaml files and resolved linting issues (fixes #1297) (#1481) 2020-10-29 17:24:55 -07:00
.flake8 Dryrun stored procedures (#1367) 2020-10-01 16:48:28 -04:00
.gitignore Update bigquery-etl cookbooks (#2935) 2022-05-04 11:10:34 +02:00
.isort.cfg Automatically sort python imports (#1840) 2021-02-24 17:11:52 -05:00
.pre-commit-config.yaml Bump click from 8.0.4 to 8.1.0 (#2838) 2022-03-29 20:46:31 +02:00
.yamllint.yaml Move search to sql_generators/ 2022-01-03 14:15:02 -08:00
CODEOWNERS Add CODEOWNERS and restricted access datasets documentation (#2524) 2021-12-21 20:25:05 +00:00
CODE_OF_CONDUCT.md Create CODE_OF_CONDUCT.md (#50) 2019-03-30 10:01:54 -07:00
CONTRIBUTING.md Add CODEOWNERS and restricted access datasets documentation (#2524) 2021-12-21 20:25:05 +00:00
Dockerfile Specify pyjnius in `requirements.in` (#2924) 2022-04-29 12:23:47 -07:00
GRAVEYARD.md Remove asn_aggregates ETL (#2580) 2021-12-15 18:28:29 +00:00
LICENSE Add MPL license (#2353) 2021-09-20 17:59:47 +00:00
README.md Specify pyjnius in `requirements.in` (#2924) 2022-04-29 12:23:47 -07:00
bqetl Use --no-deps when installing compiled requirements files (#2752) 2022-02-24 21:36:47 +00:00
conftest.py Reapply "Update to zetasql 2022.02.1 (#2862)" (#2881) 2022-04-07 14:02:20 -07:00
dags.yaml pushing bqetl acoustic dags by 1 hour to see if that resolves sensor issues (#3002) 2022-06-02 15:18:41 +02:00
netlify.toml Fail Netlify build if any subcommand fails (#2926) 2022-04-29 16:26:00 -04:00
pom.xml Support java 8 for Netlify compat (#2923) 2022-04-29 11:00:46 -07:00
pytest.ini Use zetasql to find sql dependencies (#1802) 2021-02-17 11:48:40 -08:00
requirements.in Bump pathos from 0.2.8 to 0.2.9 (#2993) 2022-05-31 16:38:25 +00:00
requirements.txt Bump pathos from 0.2.8 to 0.2.9 (#2993) 2022-05-31 16:38:25 +00:00
setup.py Specify pyjnius in `requirements.in` (#2924) 2022-04-29 12:23:47 -07:00

README.md

CircleCI

BigQuery ETL

This repository contains Mozilla Data Team's:

  • Derived ETL jobs that do not require a custom container
  • User-defined functions (UDFs)
  • Airflow DAGs for scheduled bigquery-etl queries
  • Tools for query & UDF deployment, management and scheduling

For more information, see https://mozilla.github.io/bigquery-etl/

Quick Start

Apple Silicon (M1) user requirement

Enable Rosetta mode for your terminal BEFORE installing below tools using your terminal. It'll save you a lot of headaches. For tips on maintaining parallel stacks of python and homebrew running with and without Rosetta, see blog posts from Thinknum and Sixty North.

Pre-requisites

  • Pyenv (optional) Recommended if you want to install different versions of python, see instructions here. After the installation of pyenv, make sure that your terminal app is configured to run the shell as a login shell.
  • Homebrew (not required, but useful for Mac) - Follow the instructions here to install homebrew on your Mac.
  • Python 3.8+ - (see this guide for instructions if you're on a mac and haven't installed anything other than the default system Python).
  • Java JDK 8+ - (required for some functionality, e.g. AdoptOpenJDK) with $JAVA_HOME set.
  • Maven - (needed for downloading jar dependencies). Available via your package manager in most Linux distributions and from homebrew on mac, or you can install yourself by downloading a binary and following maven's install instructions.

GCP CLI tools

  • For Mozilla Employees or Contributors (not in Data Engineering) - Set up GCP command line tools, as described on docs.telemetry.mozilla.org. Note that some functionality (e.g. writing UDFs or backfilling queries) may not be allowed.
  • For Data Engineering - In addition to setting up the command line tools, you will want to log in to shared-prod if making changes to production systems. Run gcloud auth login --update-adc --project=moz-fx-data-shared-prod (if you have not run it previously).

Installing bqetl

  1. Clone the repository
git clone git@github.com:mozilla/bigquery-etl.git
cd bigquery-etl
  1. Install the bqetl command line tool
./bqetl bootstrap
  1. Install standard pre-commit hooks
venv/bin/pre-commit install
  1. Build and install java dependencies
mvn package
# specify `<(echo mozilla-bigquery-etl)` to retain bqetl from `./bqetl bootstrap`
venv/bin/pip-sync --pip-args=--no-deps requirements.txt <(echo mozilla-bigquery-etl)

Finally, if you are using Visual Studio Code, you may also wish to use our recommended defaults:

cp .vscode/settings.json.default .vscode/settings.json

And you should now be set up to start working in the repo! The easiest way to do this is for many tasks is to use bqetl. You may also want to read up on common workflows.