Replies: 2 comments 4 replies
-
This is really exciting stuff. One note, here you do target=load_assets_from_modules([assets]), Often I don't want to load everything from a module, but select particular assets. One feature jobs provided was a way to put a little circle around some group of assets I care about and then say run this thing. Here are some ways I would expect this to work, without knowing anything about the underlying API: @asset
def my_asset(): ...
@asset
def my_other_asset(): ...
my_selection = AssetSelection.groups("marketing")
...
target=[my_asset, my_other_asset]
...
target=['my_asset', 'my_other_asset']
...
target=[my_selection] Would this work with the new jobless API? |
Beta Was this translation helpful? Give feedback.
2 replies
-
One more question, how would this work with partitions? |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Summary
In the past Dagster has emphasized the concept of jobs. Jobs appear at the top of our left nav, and user-defined jobs are currently required to leverage Dagster’s schedules and sensors.
We are moving towards a world where users typically only need to think about assets, rather than how assets and jobs interrelate. In the Dagster UI this is already the case. In the asset graph view, users can directly materialize assets without reference to any job. We are now continuing this theme in our core python APIs.
Going forward, jobs will fully leave center stage and become an “advanced” Dagster concept. “Automation” (a category encompassing schedules and sensors) will swap places with “jobs” in proximity to the core Dagster experience. Below are some specific planned changes:
Jobless schedules/sensors
Currently, schedules and sensors need to target a job. If you want to define a target that will only ever be executed by a schedule/sensor, you need to first define a separate job. Here is a basic example from our current schedule tutorial:
After the planned changes to schedule/sensor APIs:
Notable differences between two examples:
define_asset_job
andAssetSelection
.assets
parameter ofDefinitions
target
instead ofjob
argument ofScheduleDefinition
, and therefore the entire notion of “job” is not introduced in simple use cases.Assets passed to schedules and sensors automatically included in Definitions
Currently, every asset referenced by another definition needs to be passed to the
assets
argument ofDefinitions
. With the ability to pass assets directly as an automation target, we can relax this constraint. Assets passed only as automation targets will be automatically included in the set of assets stored on aDefinitions
object and thus able to be referenced by other definitions:New top-level “Automation” page and elimination of the left nav
Dagster’s left nav currently puts jobs front and center and references the schedules/sensors that target them as an afterthought. We are making changes to instead emphasize automation (schedules/sensors) and de-emphasize jobs.
The Timeline will now be organized by automations by default:
The left nav is being removed, and the “Sensors”, “Schedules”, and “Auto-materialization” views from “Overview” will be merged into a single top-level “Automation” view. The contents of “Automation” are grouped by code location and can be filtered by Name, Status, Type, or Tag:
A top level “Jobs” view will be accessible from the main nav. If the user has not defined any jobs (a likely scenario in a world with jobless automation), this view will be hidden. Jobs are grouped by code location and can be filtered by Name or Tag:
These changes will begin to roll out experimentally in 1.8 and you can enable them by enabling the
Experimental Nav
feature flag in your user settings:Conclusion
The Python changes outlined above will ship with Dagster 1.8. We believe these changes will simplify the experience of most Dagster users. Please post any questions, comments or concerns below.
Beta Was this translation helpful? Give feedback.
All reactions