aws-lambda-event-sources: KafkaEventSourceProps does not support startingPosition AT_TIMESTAMP correctly? #32235
Labels
@aws-cdk/aws-lambda-event-sources
bug
This issue is a bug.
p3
response-requested
Waiting on additional info and feedback. Will move to "closing-soon" in 7 days.
Describe the bug
Getting a synth error:
Error: startingPositionTimestamp must be provided when startingPosition is AT_TIMESTAMP
when instantiatingSelfManagedKafkaEventSource()
withstartingPosition: StartingPosition.AT_TIMESTAMP
Regression Issue
Last Known Working CDK Version
No response
Expected Behavior
KafkaEventSourceProps chain of inheritance should allow for passing in
startingPositionTimestamp
Current Behavior
You cannot provide startingPositionTimestamp anywhere on that constructor prop... if you do it will error and even if you do something like ts-ignore-error it will give you an error when running synth:
Error: startingPositionTimestamp must be provided when startingPosition is AT_TIMESTAMP
Reproduction Steps
Instantiate
SelfManagedKafkaEventSource()
and in the props providestartingPosition: StartingPosition.AT_TIMESTAMP,
which appears to be a valid option based on the types. This will cause an error when running synth... and you cannot provide requiredstartingPositionTimestamp
as it is not on the interfaces.Possible Solution
No response
Additional Information/Context
No response
CDK CLI Version
2.142.1
Framework Version
No response
Node.js Version
20
OS
macos
Language
TypeScript
Language Version
5.4
Other information
using latest aws-cdk-lib version
The text was updated successfully, but these errors were encountered: