AsyncAPI spec v3 support in Modelina
Reason/Context
This Issue is used to track changes needed to support AsyncAPI v3. As a code owner, please edit this list of TODO tasks in order to properly track the progress 🙂 Once this issue is closed it means that v3 is now fully supported in this library.
Remaining tasks:
- [x] Once https://github.com/asyncapi/parser-js/issues/780 is solved, update parser dependency (might be automated)
- [x] https://github.com/asyncapi/modelina/issues/1493
- [x] Make small changes to the input processor to enable v3 (can be drafted right now)
- [ ] Update CLI dependency
@jonaslagoni can you please add the following task to the list?
- [ ] https://github.com/asyncapi/modelina/issues/1493
:tada: This issue has been resolved in version 3.0.0-next.2 :tada:
The release is available on:
Your semantic-release bot :package::rocket:
Still need to update CLI
Do you/you have any estimate on when the CLI dependency will be updated?
@krelde probably in the end of the month when v3 of Modelina is out 🙂
Thanks!
What about mentioning here the issue related to the CLI update?
https://github.com/asyncapi/cli/issues/629
Should be fixed as soon as https://github.com/asyncapi/cli/pull/1155 is merged
:tada: This issue has been resolved in version 4.0.0-next.1 :tada:
The release is available on:
Your semantic-release bot :package::rocket:
Or https://github.com/asyncapi/modelina/pull/1785 is merged before.
guys, thanks a lot for the great work you doing for the community. Is there any chance to know what are the estimates when asyncapi/cli will fully support 3.0.0 specs and specifically typescript types generation out of asyncapi.yaml as current version as there is still hard check in cli https://github.com/asyncapi/cli/blob/71b45b4c176e6ea3949d1569dfd9ef776d85657f/src/commands/generate/models.ts#L174
Honestly, it's hard to guess, there are a few scenarios that are running in parallel right now.
- Modelina gets its own CLI: https://github.com/asyncapi/modelina/pull/1849
- AsyncAPI CLI gets updated: https://github.com/asyncapi/cli/pull/1155
Which ever comes first will enable v3 🤷
Modelina has it's own CLI install it through @asyncapi/modelina-cli or see https://github.com/asyncapi/modelina/tree/next/modelina-cli, and the AsyncAPI at some point is gonna be updated to support AsyncAPI v3 for model generation, depending on the maintainers.
Closing.
@jonaslagoni I can't really follow. Does Modelina understand AsyncAPI v3 now? The readme doesn't reflect that. Only if I don't use the asyncapi CLI and rather the Modelina CLI? Could you elaborate please? :)
Hi, I search the doc, but could not find a way to generate model for asyncapi v3 files. Is this supported or not? Many AsyncAPI v3 issues are 'closed' here.. so this means this feature is available?
Right now you can do the following to generate models for AsyncAPI v3 (at least until the AsyncAPI Cli gets updated)npm install -g @asyncapi/[email protected]
Then run it like with the AsyncAPI CLI: modelina generate xxx
@jonaslagoni it works: thanks a lot :-) Any idea about [email protected] 's ETA ?
Also, this question, a bit off topic.. I hope you don't mind, I'm asking you this: I am trying to create an asyncapi.yaml file starting from really simple Java Spring RabbitMQ code, but I am a bit lost. Can I kindly ask you to help me find the resources / pointers that could bring some light to me regarding that matter? The full question is here: https://stackoverflow.com/questions/78581918/async-api-bare-minimum-asyncapi-yaml-for-simple-rabbitlistener