Drew You
03/28/2023, 2:06 PM# ensure table exists in db
last_record = #query db for the latest record of a timeseries
fill_data = #query api for data between last_record and time.now()
#optionally do very long running processing task
#append fill_data to database
In dagster, I'm confused. This is often a time partition, but it might be i.e. minute-partitioned data that I want to schedule every 5 minutes and the range nature of the airflow query means the setup/teardown work gets optimized for free in longer queries.Tobias Pankrath
03/28/2023, 2:16 PMDrew You
03/28/2023, 2:21 PMsean
03/28/2023, 2:46 PM@asset(
partitions_def=DailyPartitionsDefinition(start_date="2020-01-01"),
ins={
"a": AssetIn(
partition_mapping=TimeWindowPartitionMapping(start_offset=-1, end_offset=-1)
)
},
)
def a(a):
...