3.3.6 - One flow, many roads
Direct submission of workflows to dynamic infrastructure is in beta!
We're pleased to announce the beta release of new infrastructure decorators enabling the submission of workflows directly to dynamic infrastructure.
This feature enables you to easily execute workflows on various infrastructure environments without the need for multiple deployments or managing persistent workers. This simplifies workflow definitions and enhances portability.
Here's a small example of the new @kubernetes
decorator in action:
from prefect import flow
from prefect_kubernetes import kubernetes
@kubernetes(work_pool="olympic")
@flow(result_storage="s3-bucket/remote-result-storage")
def my_k8s_flow():
return "🏊♀️ Finished another lap!"
@flow
def parent_flow():
return my_k8s_flow() # will run in a Kubernetes cluster via the 'olympic' work pool
print(my_k8s_flow()) # prints "🏊♀️ Finished another lap!"
Check out the docs for more information on using this new feature.
Feedback is very important for us to help refine this feature while it's in beta. Give it a try, and share your feedback with us by opening an issue!
Enhancements ➕➕
- Add option to serve all tasks in a module by @zzstoatzz in #17858
- feat: Add support for a new
resolve_futures_to_results
function by @Andrew-S-Rosen in #17869 - Add global concurrency id to the create and update route for deployments by @cbelsole in #17826
- Add
submit
method to infrastructure-bound flows by @desertaxle in #17896 - Add deployment version info to
prefect deploy
by @kevingrismore in #17466 - Add infrastructure decorators by @desertaxle in #17863
- Link submitted flows to their parent flow by @desertaxle in #17894
- Add
@docker
decorator by @desertaxle in #17878 - Add
with_options
implementation toInfrastructureBoundFlow
by @desertaxle in #17900
Bug Fixes 🐞
- Update
pydantic-settings
version pin by @desertaxle in #17853 - Propagates the currently triggering event (if any) for composite triggers by @chrisguidry in #17854
- Polishes the experience with inferring versioning by @chrisguidry in #17901
- Fix warning on reconnect by @mslavoshevskii in #17876
Development & Tidiness 🧹
- Move decorated function discovery out of the cli by @zzstoatzz in #17840
Documentation 📓
- Add initial documentation for submitting workflows directly to dynamic infrastructure by @desertaxle in #17861
- Fix dead integration link by @zzstoatzz in #17831
- Nginx sample config + note about client API key/auth string precedence by @ColinMaudry in #17810
New Contributors
- @ColinMaudry made their first contribution in #17810
- @mslavoshevskii made their first contribution in #17876
- @cbelsole made their first contribution in #17826
Full Changelog: 3.3.5...3.3.6