Kiran
Kiran4d ago

Need help in understanding source code

Hi, I'm currently going through the windmill source code to contribute to it. I just wanted to know where is the job result is being saved. I found the following code in backend/windmill-worker/src/worker_flow.rs:
let nresult = match &new_status {
Some(FlowStatusModule::Success { flow_jobs: Some(jobs), .. })
| Some(FlowStatusModule::Failure { flow_jobs: Some(jobs), .. }) => {
Arc::new(retrieve_flow_jobs_results(db, w_id, jobs).await?)
}
_ => result.clone(),
};
let nresult = match &new_status {
Some(FlowStatusModule::Success { flow_jobs: Some(jobs), .. })
| Some(FlowStatusModule::Failure { flow_jobs: Some(jobs), .. }) => {
Arc::new(retrieve_flow_jobs_results(db, w_id, jobs).await?)
}
_ => result.clone(),
};
From where is this result being save from? Basically, I just wanted to understand the execution flow and how are the results being passed from one job to another. Thanks!
1 Reply
Hugo
Hugo3h ago
it's saved in the db, in the v2_job_completed table

Did you find this page helpful?