-
-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: parse message payload of any type other than map of String to Object #208
fix: parse message payload of any type other than map of String to Object #208
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Welcome to AsyncAPI. Thanks a lot for creating your first pull request. Please check out our contributors guide useful for opening a pull request.
Keep in mind there are also other channels you can use to interact with AsyncAPI community. For more details check out this issue.
ade6db2
to
fa7c8e3
Compare
…o fix the failure where the spec with an array payload was not getting parsed properly
fa7c8e3
to
3dfe458
Compare
@yogeshnikam671 hi! Let's remember for what That's why But here is a clash between MessageExample JSON Schema and MessageExample definition in our docs It's main reason, why it's take a while to review and analyze proposed change Right now, I'm figuring out which type is valid and how it can be changed in lib Will be awesome, if you provide as much of different examples, as it possible |
@Pakisan Thanks a lot for the clarification. Primary we foresee below schema types as payloads.
The priority / blocker at the moment is the "Array of objects" use case for which @yogeshnikam671 has added sample spec in this PR and we have also made code changes to achieve this capability. Kindly review. |
@harikrishnan83 I'm working on PR to our JSON Schemas and documentation repositories Yep, looks like payload and headers can be of any type, so 'Object' is a valid type for this fields in class And they must be validated through schema in Message class Once I open PR, I'll attach them to this PR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Currently the asyncAPI parser expects the example payload to be an object and hence if it is an array, it does not parse the message associated with such array message.