blocks workflow (#270)

This commit is contained in:
drethereum 2024-07-23 09:55:03 -06:00 committed by GitHub
parent 62697a84da
commit 2e47dc070a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
8 changed files with 7 additions and 54 deletions

View File

@ -1,47 +0,0 @@
name: dbt_run_streamline_dexalot_blocks
run-name: dbt_run_streamline_dexalot_blocks
on:
workflow_dispatch:
branches:
- "main"
env:
DBT_PROFILES_DIR: ./
ACCOUNT: "${{ vars.ACCOUNT }}"
ROLE: "${{ vars.ROLE }}"
USER: "${{ vars.USER }}"
PASSWORD: "${{ secrets.PASSWORD }}"
REGION: "${{ vars.REGION }}"
DATABASE: "${{ vars.DATABASE }}"
WAREHOUSE: "${{ vars.WAREHOUSE }}"
SCHEMA: "${{ vars.SCHEMA }}"
concurrency:
group: ${{ github.workflow }}
cancel-in-progress: true
jobs:
run_dbt_jobs:
runs-on: ubuntu-latest
environment:
name: workflow_prod
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: "3.10"
cache: "pip"
- name: install dependencies
run: |
pip install -r requirements.txt
dbt deps
- name: Run DBT Jobs
run: |
dbt run --vars '{"STREAMLINE_INVOKE_STREAMS":True}' -m "avalanche_models,tag:streamline_dexalot_blocks"

View File

@ -6,5 +6,4 @@ dbt_run_scheduled_curated,"35 * * * *"
dbt_test_intraday,"37 */4 * * *"
dbt_test_tasks,"10 * * * *"
dbt_run_streamline_dexalot_chainhead,"50 * * * *"
dbt_run_streamline_dexalot_blocks,"8,38 * * * *"
dbt_run_streamline_dexalot_non_realtime,"5 * * * *"
1 workflow_name workflow_schedule
6 dbt_test_intraday 37 */4 * * *
7 dbt_test_tasks 10 * * * *
8 dbt_run_streamline_dexalot_chainhead 50 * * * *
dbt_run_streamline_dexalot_blocks 8,38 * * * *
9 dbt_run_streamline_dexalot_non_realtime 5 * * * *

View File

@ -4,7 +4,7 @@
unique_key = "block_number",
cluster_by = "ROUND(block_number, -3)",
post_hook = "ALTER TABLE {{ this }} ADD SEARCH OPTIMIZATION on equality(block_number)",
tags = ['streamline_dexalot_complete', 'streamline_dexalot_blocks']
tags = ['streamline_dexalot_complete']
) }}
SELECT

View File

@ -3,7 +3,8 @@
materialized = "incremental",
unique_key = "block_number",
cluster_by = "ROUND(block_number, -3)",
post_hook = "ALTER TABLE {{ this }} ADD SEARCH OPTIMIZATION on equality(block_number)"
post_hook = "ALTER TABLE {{ this }} ADD SEARCH OPTIMIZATION on equality(block_number)",
tags = ['streamline_dexalot_complete']
) }}
SELECT

View File

@ -9,7 +9,7 @@
"worker_batch_size" :"1000",
"sql_source" :"{{this.identifier}}" }
),
tags = ['streamline_dexalot_blocks']
tags = ['streamline_dexalot_realtime']
) }}
WITH last_3_days AS (

View File

@ -1,6 +1,6 @@
{{ config (
materialized = "view",
tags = ['streamline_dexalot_complete','streamline_dexalot_blocks']
tags = ['streamline_dexalot_complete']
) }}
SELECT

View File

@ -1,6 +1,6 @@
{{ config (
materialized = "view",
tags = ['streamline_dexalot_complete','streamline_dexalot_blocks']
tags = ['streamline_dexalot_complete']
) }}
SELECT

View File

@ -1,6 +1,6 @@
{{ config (
materialized = 'table',
tags = ['streamline_dexalot_blocks']
tags = ['streamline_dexalot_complete']
) }}
SELECT