asyncapi / java-template

Java template for the AsyncAPI Generator
Apache License 2.0
14 stars 13 forks source link

feat: generate schema from example message #191

Closed dalelane closed 8 months ago

dalelane commented 8 months ago

The generator has been implemented assuming that all message objects include a payload with properties. This is used when generating Java classes to be able to create attributes that matching the expected message properties.

This causes the generator to fail with AsyncAPI documents that don't include payload properties. Some such documents will provide a sample message instead. For these documents, we can attempt to derive a schema from the sample, and use that schema to generate a usable set of properties.

sonarcloud[bot] commented 8 months ago

Quality Gate Passed Quality Gate passed

Issues
1 New issue
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
2.7% Duplication on New Code

See analysis details on SonarCloud

dalelane commented 8 months ago

/au

dalelane commented 8 months ago

/rtm

asyncapi-bot commented 8 months ago

:tada: This PR is included in version 0.3.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket: