Skip to content

Feature: add multiprocessing worker_id to CLI extra options #2178

Open
@Lancetnik

Description

@Lancetnik

faststream run main:app --workers 3

@app.on_startup
async def start(worker_id: int):
     print(worker_id)  # 0 / 1 / 2

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions