Scott Zelenka
04/01/2020, 7:28 PMLocalDaskExecutor
locally via flow.run(executor=LocalDaskExecutor())
, to get it to spawn multiple threads to execute in parallel, but when I register the same flow to Cloud, it seems to execute the mapped tasks in sequence.Zachary Hughes
04/01/2020, 7:48 PMScott Zelenka
04/01/2020, 7:53 PMKubernetesJobEnvironment
with a job_spec_file
.
Is there a way to specify the executor within the K8 Pod it creates?
I don't think it needs to spawn a full Dask cluster .. the Flow in question needs to ping an off-network API for a lot of observations, which one Pod should be able to handle.josh
04/01/2020, 8:04 PM- name: PREFECT__ENGINE__EXECUTOR__DEFAULT_CLASS
value: "prefect.engine.executors.DaskExecutor"
- name: PREFECT__ENGINE__EXECUTOR__DASK__ADDRESS
value: "<tcp://your-scheduler:8786>"
Scott Zelenka
04/01/2020, 8:37 PM- name: PREFECT__ENGINE__EXECUTOR__DEFAULT_CLASS
value: "prefect.engine.executors.LocalDaskExecutor"
Thanks for a heads-up on the environment variable configuration.
Are there other environment variables I should be aware of (are they all documented somewhere)?josh
04/01/2020, 8:38 PMScott Zelenka
04/01/2020, 8:57 PMjosh
04/01/2020, 8:57 PMjosh
04/01/2020, 8:58 PMScott Zelenka
04/01/2020, 9:04 PMscheduler
for LocalDaskExecutor
is "synchronous", and I don't see a way to specify the scheduler
parameter for the executor via config.toml (I want to set it to threads
).
Guess I'll play around with DaskExecutor