Skip to content

Start "full" faust worker inside fast-api #2

@ndrfrr

Description

@ndrfrr

Hi, I see that in this example only a faust worker in client mode is started in the fast-api app.
Would it be possible to have a full faust worker running inside the fast-api app?

I tried changing your code by doing:
asyncio.create_task(faust_app.main()) instead of asyncio.create_task(faust_app.start_client()) in api.py.
Doing that I get an error related to the event loop: RuntimeError: this event loop is already running.

Digged online but wasn't able to find much. Have you met this usecase before?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions