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

WIP: Billing graphql #673

Draft
wants to merge 36 commits into
base: dev
Choose a base branch
from
Draft

WIP: Billing graphql #673

wants to merge 36 commits into from

Conversation

milo-hyben
Copy link
Contributor

No description provided.

milo-hyben and others added 30 commits November 22, 2023 18:53
* Added compute_category, cromwell_sub_workflow_name, cromwell_workflow_id, goog_pipelines_worker and wdl_task_name to extended view and created relevant filters and API points.

* Added labels to all BQ queries, refactoring billing layer.

* Added examples to billing-total-cost API regarding the new filters.
* Temporarily disable seqr and hail from /topics API.

* Autoselect 1st topic / 1st project value from the DDL.

* Merging Billing.css into index.css

* Small fix - reusing extRecords in FieldSelector component.

* Refactoring duplicated code in FieldSelector.

* Added Stages to the Group by DDL.
* Added API point to check if billing is enabled.
* Added simple Total Cost By Batch Page.
* Added simple Total Cost By Batch Page.

* Fixed autoselect day format.

* Fixing day format for autoselect (missing leading 0)

* Added first draft of billing page to show detail SKU per selected cost category over selected time periods (day, week, month or invoice month)

* Small fix for BillingCostByBatch page, disable search if searchBy is empty or < 6 chars.

* New: Billing API GET namespaces, added namespace to allowed fields for total cost.

* Implemented HorizontalStackedBarChart, updated Billing By Invoice Month page to enable toggle between chart and table view.
* Implemented Stacked bars with option to accumulate data.

* Added budget bar to billing horizontal bar chart, added background color for the billing table to reflect the chart colours.

* Added simple prediction of billing stacked bar chart.
* Added simple Total Cost By Batch Page.

* Removing debug prints.

* Fixed autoselect day format.

* Fixing day format for autoselect (missing leading 0)

* Added first draft of billing page to show detail SKU per selected cost category over selected time periods (day, week, month or invoice month)

* Small fix for BillingCostByBatch page, disable search if searchBy is empty or < 6 chars.

* New: Billing API GET namespaces, added namespace to allowed fields for total cost.

* Implemented HorizontalStackedBarChart, updated Billing By Invoice Month page to enable toggle between chart and table view.

* ADD: Cost by Analysis page

* ADD: add start of Analysis grid

* ADD: add start of Analysis grid

* FIX: table fixes for the HailBatchGrid

* API: api changes to enable query of the raw table

* API: fixed and working with updated get_total_cost endpoint

* API: fix typing of get_total_cost (default return is now a list[dict] and can be converted in the layer/route to a specific output type

* API: add endpoint to get costs by batch_id

* API: done

* IN PROGRESS: modifying Cost By Analysis to use new endpoints

* IN PROGRESS: changes to Cost By Analysis, linking with backend API.

* IN PROGRESS: changes to Cost By Analysis, grid grouping by ar/batch/job.

* NEW: finalising Cost By Analysis page

* ADD: durations to Cost By Analysis page

---------

Co-authored-by: Milo Hyben <milo.hyben@gmail.com>
@codecov-commenter
Copy link

codecov-commenter commented Jan 31, 2024

Codecov Report

Attention: 492 lines in your changes are missing coverage. Please review.

Comparison is base (6134af9) 68.67% compared to head (0318d5e) 69.82%.

❗ Current head 0318d5e differs from pull request most recent head 3f658ee. Consider uploading reports for the commit 3f658ee to get more accurate results

Files Patch % Lines
db/python/tables/bq/billing_base.py 17.78% 171 Missing ⚠️
api/graphql/schema.py 38.09% 78 Missing ⚠️
db/python/layers/billing.py 19.73% 61 Missing ⚠️
db/python/tables/bq/function_bq_filter.py 30.43% 32 Missing ⚠️
api/routes/billing.py 48.33% 31 Missing ⚠️
db/python/tables/bq/billing_daily.py 26.31% 28 Missing ⚠️
db/python/tables/bq/generic_bq_filter_model.py 57.14% 24 Missing ⚠️
db/python/tables/bq/billing_gcp_daily.py 40.00% 21 Missing ⚠️
db/python/tables/bq/billing_ar_batch.py 37.50% 15 Missing ⚠️
models/models/billing.py 82.71% 14 Missing ⚠️
... and 4 more
Additional details and impacted files
@@            Coverage Diff             @@
##              dev     #673      +/-   ##
==========================================
+ Coverage   68.67%   69.82%   +1.15%     
==========================================
  Files         131      134       +3     
  Lines       10198    10455     +257     
==========================================
+ Hits         7003     7300     +297     
+ Misses       3195     3155      -40     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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.

3 participants