Skip to content

Commit

Permalink
update deployment UX
Browse files Browse the repository at this point in the history
  • Loading branch information
zzstoatzz authored Nov 7, 2023
1 parent 8fb2a4f commit ef61c3c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions flows-advanced/parent-orchestrator/pokemon_weight.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
orchestrator flow by awaiting `(FlowRun.state.result()).get()`.
The deployment commands below don't specify an infrastructure (and therefore
default to the `Process` infrastructure), since the code here is infrastructure
would automatically create a Process work pool), since the code here is infrastructure
agnostic and wouldn't need to change if the deployments used a different infra block.
"""

Expand Down Expand Up @@ -39,7 +39,7 @@ async def get_pokemon_info(pokemon_name: str) -> Dict[str, Any]:


# deploy this flow with:
# prefect deployment build pokemon_weight.py:get_total_pokemon_weight -n orchestrator -a
# prefect deploy pokemon_weight.py:get_total_pokemon_weight -n orchestrator
@flow(log_prints=True)
async def get_total_pokemon_weight(num_pokemon: int = 100, chunk_size: int = 10):
print(f"Processing {num_pokemon} pokemon in batches of {chunk_size}...")
Expand Down Expand Up @@ -73,7 +73,7 @@ async def get_total_pokemon_weight(num_pokemon: int = 100, chunk_size: int = 10)


# deploy this flow with:
# prefect deployment build pokemon_weight.py:process_pokemon_batch -n worker -a
# prefect deploy pokemon_weight.py:process_pokemon_batch -n worker
@flow(persist_result=True)
async def process_pokemon_batch(pokemon_names: List[str]) -> int:
pokemon_info = [
Expand Down

0 comments on commit ef61c3c

Please sign in to comment.