Skip to content
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

Include validation in the asyncapi.http.proxy generator #574

Merged
merged 10 commits into from
Nov 16, 2023

Conversation

attilakreiner
Copy link
Contributor

Description

Include validation in the generate command in the asyncapi.http.proxy template

Fixes #460

Message firstMessage = messages.entrySet().stream().findFirst().get().getValue();
String contentType = MessageView.of(asyncApi.components.messages, firstMessage).contentType();
if (APPLICATION_JSON.equals(contentType))
if (APPLICATION_JSON.equals(resolveContentType()))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we need a pattern matcher here to cover all the possibilities for json messages, as there are many more than just application/json.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done, pls chk

@jfallows jfallows merged commit eaac6bb into aklivity:develop Nov 16, 2023
5 checks passed
@attilakreiner attilakreiner deleted the asyncapi-gen-validator branch November 16, 2023 21:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Generate http server request validators from AsyncAPI specification
2 participants