To determine whether you can run Prefect 2 flows in a Kubernetes cluster currently hosting Prefect 1, let me check the latest documentation and gather the relevant information. I'll be back shortly with an answer.
Let's search the Prefect documentation for compatibility and setup requirements for running Prefect 2 in a Kubernetes cluster.
It seems that the issues related to running Prefect 2 in a Kubernetes cluster indicate some level of complexity, particularly around memory management and pod handling. However, from the information mentioned, there's no direct evidence to suggest incompatibility between Prefect 1 and Prefect 2 within the same cluster, though some potential pain points need to be addressed.
Key observations:
-
Memory Usage: There's an issue with KubernetesWorker memory usage increasing over time with Prefect 2.
-
See more details here
-
Module Import Edge Cases: There are documented issues when trying to execute flows via deployment.
-
See more details here
-
Flow Cancellation: Cancelling flows does not terminate associated Dask Scheduler & Worker pods properly.
-
See more details here
Here’s what you should consider:
1.
Separate Environments: It is generally a good strategy to run different major versions of a tool in separate environments to avoid conflicts.
2.
Migration Path: Consult the
Prefect 2 migration guide (if available) to see if there are any specific Kubernetes directives.
3.
Testing: Conduct thorough testing on a lower environment before migrating to production.
For a more conclusive answer, verifying the documentation or consulting with Prefect support would be advisable.
Would you like me to explore migration strategies further or assist you with another issue?