Skip to content

Commit

Permalink
Merge branch 'master' into staging/smtr-subsidio-insere-task-qualidad…
Browse files Browse the repository at this point in the history
…e-dados
  • Loading branch information
mergify[bot] authored Jun 21, 2024
2 parents 59a5d1e + a449316 commit dc66ceb
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 21 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@
image=emd_constants.DOCKER_IMAGE.value,
labels=[emd_constants.RJ_SMTR_AGENT_LABEL.value],
)
realocacao_sppo_zirix.schedule = every_10_minutes
# realocacao_sppo_zirix.schedule = every_10_minutes


with Flow(
Expand Down Expand Up @@ -273,7 +273,7 @@
image=emd_constants.DOCKER_IMAGE.value,
labels=[emd_constants.RJ_SMTR_AGENT_LABEL.value],
)
captura_sppo_zirix.schedule = every_minute
# captura_sppo_zirix.schedule = every_minute


with Flow(
Expand Down Expand Up @@ -379,4 +379,4 @@
image=emd_constants.DOCKER_IMAGE.value,
labels=[emd_constants.RJ_SMTR_AGENT_LABEL.value],
)
recaptura_zirix.schedule = every_hour_minute_six
# recaptura_zirix.schedule = every_hour_minute_six
13 changes: 8 additions & 5 deletions pipelines/rj_smtr/br_rj_riodejaneiro_recursos/flows.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@
from pipelines.rj_smtr.tasks import get_current_timestamp

from pipelines.rj_smtr.flows import default_capture_flow, default_materialization_flow
from pipelines.rj_smtr.schedules import every_day

# from pipelines.rj_smtr.schedules import every_day


# CAPTURA DOS TICKETS #
Expand Down Expand Up @@ -106,9 +107,11 @@
]

table_params = task(
lambda tables, exclude: [t for t in tables if t["table_id"] not in exclude]
if exclude is not None
else tables,
lambda tables, exclude: (
[t for t in tables if t["table_id"] not in exclude]
if exclude is not None
else tables
),
checkpoint=False,
name="get_tables_to_run",
)(tables=constants.SUBSIDIO_SPPO_RECURSOS_TABLE_IDS.value, exclude=exclude)
Expand Down Expand Up @@ -197,4 +200,4 @@
)

# Schedule
subsidio_sppo_recurso.schedule = every_day
# subsidio_sppo_recurso.schedule = every_day
25 changes: 12 additions & 13 deletions pipelines/rj_smtr/br_rj_riodejaneiro_viagem_zirix/flows.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,28 +7,27 @@
from prefect.run_configs import KubernetesRun
from prefect.storage import GCS

from pipelines.constants import constants as emd_constants
from pipelines.rj_smtr.br_rj_riodejaneiro_viagem_zirix.constants import (
constants as zirix_constants,
)
from pipelines.rj_smtr.flows import default_capture_flow

# from pipelines.utils.decorators import Flow
from pipelines.utils.utils import set_default_parameters

# from prefect.tasks.prefect import create_flow_run, wait_for_flow_run


# EMD Imports #

from pipelines.constants import constants as emd_constants

from pipelines.utils.decorators import Flow
from pipelines.utils.utils import set_default_parameters

# from pipelines.utils.execute_dbt_model.tasks import get_k8s_dbt_client

# SMTR Imports #

from pipelines.rj_smtr.flows import default_capture_flow


from pipelines.rj_smtr.br_rj_riodejaneiro_viagem_zirix.constants import (
constants as zirix_constants,
)

from pipelines.rj_smtr.schedules import every_10_minutes, every_hour
# from pipelines.rj_smtr.schedules import every_10_minutes, every_hour

# from pipelines.utils.execute_dbt_model.tasks import run_dbt_model

Expand All @@ -47,7 +46,7 @@
default_parameters=zirix_constants.VIAGEM_CAPTURE_PARAMETERS.value,
)

viagens_captura.schedule = every_10_minutes
# viagens_captura.schedule = every_10_minutes


viagens_recaptura = deepcopy(default_capture_flow)
Expand All @@ -64,4 +63,4 @@
| {"recapture": True},
)

viagens_recaptura.schedule = every_hour
# viagens_recaptura.schedule = every_hour

0 comments on commit dc66ceb

Please sign in to comment.