Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Track BigQuery costs of GVS python VS-480 #7915

Merged
merged 25 commits into from
Jun 29, 2022
Merged

Conversation

rsasch
Copy link

@rsasch rsasch commented Jun 23, 2022

  • restore job stats collection to create_ranges_cohort_extract_data_table.py
  • add writing of cost info to BigQuery table to create_ranges_cohort_extract_data_table.py and populate_alt_allele_table.py
  • add task to GvsQuickstartIntegration.wdl that checks that expected cost data was written to BigQuery table
  • tweaked schema for cost_observability table to include descriptions

Integration test run: https://app.terra.bio/#workspaces/gvs-dev/GVS%20Integration/job_history/30a2d8ee-13dd-4829-b3a8-4e6a67409705
Closes https://broadworkbench.atlassian.net/browse/VS-480

@codecov
Copy link

codecov bot commented Jun 23, 2022

Codecov Report

❗ No coverage uploaded for pull request base (ah_var_store@32a6106). Click here to learn what that means.
The diff coverage is n/a.

@@               Coverage Diff                @@
##             ah_var_store     #7915   +/-   ##
================================================
  Coverage                ?   86.288%           
  Complexity              ?     35194           
================================================
  Files                   ?      2170           
  Lines                   ?    164888           
  Branches                ?     17785           
================================================
  Hits                    ?    142278           
  Misses                  ?     16288           
  Partials                ?      6322           

scripts/variantstore/wdl/GvsAssignIds.wdl Show resolved Hide resolved
scripts/variantstore/wdl/GvsQuickstartIntegration.wdl Outdated Show resolved Hide resolved
scripts/variantstore/wdl/GvsQuickstartIntegration.wdl Outdated Show resolved Hide resolved
scripts/variantstore/wdl/GvsQuickstartIntegration.wdl Outdated Show resolved Hide resolved
scripts/variantstore/wdl/GvsQuickstartIntegration.wdl Outdated Show resolved Hide resolved
@@ -60,7 +61,7 @@ workflow GvsUnified {

File interval_weights_bed = "gs://broad-public-datasets/gvs/weights/gvs_vet_weights_1kb.bed"

String extract_output_file_base_name = filter_set_name
String extract_output_file_base_name = sub(filter_set_name, " ", "-")
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

are there any other characters we should be concerned about?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

at one point we were worried about underscores, but I think we ruled that out?

scripts/variantstore/wdl/extract/utils.py Outdated Show resolved Hide resolved
scripts/variantstore/wdl/extract/utils.py Outdated Show resolved Hide resolved

# populate cost_observability data
sql = f"""INSERT INTO `{fq_dataset}.cost_observability`
(call_set_identifier, step, call, shard_identifier, event_key, call_start_timestamp, event_timestamp, event_bytes)
Copy link
Collaborator

@mcovarr mcovarr Jun 23, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just realizing now that this is writing bytes and the datatype for event_bytes is INTEGER... happily BQ INTEGERS are unusually large at +/- 8 EiBs; if we overflow that we have bigger problems

@rsasch rsasch requested review from mcovarr and gbggrant June 23, 2022 18:30
# populate cost_observability data
sql = f"""INSERT INTO `{fq_dataset}.cost_observability`
(call_set_identifier, step, call, shard_identifier, event_key, call_start_timestamp, event_timestamp, event_bytes)
VALUES('{call_set_identifier}', '{step}', '{call}', '{shard_identifier}', 'BigQuery Query Billed',
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this supposed to be 'BigQuery Query Scanned' like in George's PR?

@rsasch rsasch merged commit d9cd014 into ah_var_store Jun 29, 2022
@rsasch rsasch deleted the rsa_metadata_from_python branch June 29, 2022 23:48
This was referenced Mar 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants