0

I have the following configuration for serverless Lambda which is supposed to be triggered by a Kafka MSK.

Using Serverless 2.72.2

Yet when deploying I get the error event[0] unsupported function event

  kafkaConsumer:
    role: 'some_arn'
    handler: kafkaConsumer.trigger
    name: some-kafka-consumer
    events:
      - msk:
          arn: 'kafka_cluster_arn'
          topic: 'kafka_topic_name'

Please advise what I'm not configuring properly.

1 Answer 1

2

it seems like you might be using a version of the Framework that does not support msk event definition. It was added in 2.3.0 release: https://github.com/serverless/serverless/blob/master/CHANGELOG.md#230-2020-09-25

Sign up to request clarification or add additional context in comments.

4 Comments

Upgraded to serverless 2.72.0, and still getting the same error
Please share a reproducible example of the bug you're getting, along with detailed output from sls deploy command - otherwise it's hard to help and reason about your issue.
You were correct, after upgrading I discovered an indentation issue which caused the error.
Great to hear that you've been able to resolve the issue!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.