0

In Spyder, i am trying the Hello World application from the official Faust website:

import faust

app = faust.App(
    'hello-world',
    broker='kafka://localhost:9092',
    value_serializer='raw',
)

greetings_topic = app.topic('greetings')

@app.agent(greetings_topic)
async def greet(greetings):
    async for greeting in greetings:
        print(greeting)

I start Zookeeper and Kafka (kafka works in Spyder with Consumer/Producer example)

I am stuck at this stage to start a worker

$ faust -A hello_world worker -l info

i tried this in the command line but $ faust is not recognized; i tried in the Python interpreter as well but doesnt work (I was not expecting any of this to work).

I read about daeamonization so i imagine this has something to do with that but once again i could run the Kafka consumer/producer example just with python interpreter.

thank you

pam
  • 676
  • 1
  • 7
  • 27

0 Answers0