Hi everyone, I drafted this design sketch to help ...
# ask-community
k
Hi everyone, I drafted this design sketch to help better illustrated my question. This is a standard deployment from Dagster docs. What I want to add is to allow business people to modify the job configuration on demand. The modifications can be adding new jobs, deleting a job, turn off schedule for a job, set new schedule for a job, change some parameters for a job. As I understood, the jobs are registered by exposing @repository to dagit and dagster-daemon. In my case, for initial startup, I suppose I can load the configs from database to construct the jobs programatically. I am not sure how to handle update from this point. Note that we are not changing any user code. My question is, how can I reflect my on-demand config changes to Dagster? https://www.figma.com/file/5s1DJLQatpF0TxG0DOCOyI/Dagster-arch?node-id=0%3A1
d
Hi Kha - If you have a way to restart the user code server periodically (either when you know changes have been made or on some regular schedule), dagit will automatically reload your code, pick up any changes, and include them in the UI and in new runs
k
Hi Daniel, thank you for the reply. So the key is to restart the user code server.
Yes, I know when changes have been made
d
That's right - that won't disrupt any ongoing runs if you're using one of the run launchers that launches each run in its own container (like docker / k8s / ecs)
k
If I have about 3000+ jobs (and the number can grow more), would this still be realistic?
I only have 1 graph, and from this graph, I can have thousands of different config parameters for it.
d
That does sound like a bit more than average (might be a lot to manage all the different jobs in the dagit UI), but we'd be happy to talk through any scaling challenges that come up
k
As a consultant gig?
d
sorry, I don't totally follow
If you run into trouble, we'd be happy to answer any questions or clarifications about the system here, like i'm doing now
but we don't currently have a more formal consultant program
k
Ah I see.
I will be back with more questions 🙂
condagster 1
d
sounds good! one thing to consider is that if the only difference between the jobs is the config, they don't necessarily all have to be different jobs - jobs can specify default config at definition time, but you can also specify config at runtime in the launchpad or over the graphql API.
k
I run these 3000+ jobs on cron schedule
So I think it is more like I have 1 job, but 3000+ schedules
d
I see - a job can have multiple schedules, and the schedule can supply the config, so that could work well
k
Okay, I will check the API
THanks Daniel 🙂
condagster 1
In the API, I see apis for executing, even for reloading repository, but no apis for updating schedules
d
Schedules are loaded from code, just like jobs
k
Would a call to reload repository rerun the code defined in @repository block?
d
there's an API for turning schedules on and off, and you can set the default status of a schedule to be running as soon as its loaded
Not currently - you need to restart the process if you're running your own gRPC server (this is a known deficiency that we're hoping to make better)
k
I see. Thanks! 😊