Jeremy
09/28/2022, 5:30 PMgateway_pings_group_prod = AssetGroup(
[gateway_pings, get_unique_ip_addresses],
resource_defs=RESOURCES_PRODUCTION
)
gateway_pings_prod = gateway_pings_group_prod.build_job(
name="splunk_gateway_pings",
tags={"notify": "slack"}
)
gateway_pings_schedule = build_schedule_from_partitioned_job(
gateway_pings_prod
)
how do i do this now? I see that AssetGroup is deprecated and I should use load_assets_from_package_module
but I don;t see how to set resource_defs
and how should I rewrite the build_job part?
also, i don’t have my assets split into modules. do I need to do that? [gateway_pings, get_unique_ip_addresses]
are just 2 assets in a file with several others.claire
09/28/2022, 7:32 PMwith_resources
function: https://docs.dagster.io/concepts/resources#providing-resources-to-software-defined-assets
In order to build a job from a group of assets, you could use the AssetSelection
API: https://docs.dagster.io/_apidocs/assets#dagster.AssetSelection
and build a job by doing something like:
define_asset_job("my_job", AssetSelection.groups("group_name"))