You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to generate the example single-channel.yml i get the feedback the version of the asyncapi is incorrect.
The example asyncapi is v 2.2.2 and the generator and the java-template should be able to use this version.
Expected behavior
I would expect the example to be generated flawlesly
asyncapi: 2.2.0
info:
title: Record Label Service
version: 1.0.0
description: This service is in charge of processing music
servers:
production:
url: ibmmq://localhost:1414/QM1/DEV.APP.SVRCONN
protocol: ibmmq-secure
description: Production Instance 1
bindings:
ibmmq:
cipherSpec: ANY_TLS12
channels:
song/released:
publish:
message:
$ref: '#/components/messages/song'
subscribe:
message:
$ref: '#/components/messages/song'
components:
messages:
song:
payload:
type: object
properties:
title:
type: string
description: Song title
artist:
type: string
description: Song artist
album:
type: string
description: Song album
genre:
type: string
description: Primary song genre
length:
type: integer
description: Track length in seconds
jhartman micro-service]$ ag --version
2.6.0
jhartman micro-service]$ /pub/git/AsyncAPI/asyncapi/generator/apps/generator/cli.js ./src/main/contracts/single-channel.yml @asyncapi/java-template -o ./target/docs -p server=production
Warning: The "ag" CLI is deprecated and will be removed in a future release. Please use the AsyncAPI CLI instead. See release notes for details: https://github.com/asyncapi/generator/releases/tag/%40asyncapi%2Fgenerator%402.6.0. You can hide this working using --disable-warning flag.
(node:1634413) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
Something went wrong:
Error: This template is not compatible with the current version of the generator (2.6.0). This template is compatible with the following version range: >=1.3.0 <2.0.0.
at isTemplateCompatible (/pub/git/AsyncAPI/asyncapi/generator/apps/generator/lib/templateConfigValidator.js:57:11)
at module.exports.validateTemplateConfig (/pub/git/AsyncAPI/asyncapi/generator/apps/generator/lib/templateConfigValidator.js:30:3)
at Generator.configureTemplateWorkflow (/pub/git/AsyncAPI/asyncapi/generator/apps/generator/lib/generator.js:311:5)
at async Generator.generate (/pub/git/AsyncAPI/asyncapi/generator/apps/generator/lib/generator.js:199:5)
at async Generator.generateFromFile (/pub/git/AsyncAPI/asyncapi/generator/apps/generator/lib/generator.js:500:12)
at async /pub/git/AsyncAPI/asyncapi/generator/apps/generator/cli.js:164:9
[[email protected]@v2l1-jhartman micro-service]$
async /home/users/jhartman/.nvm/versions/node/v22.12.0/lib/node_modules/@asyncapi/generator/cli.js:164:9
How to Reproduce
generate the example single-channel.yml as described in the readme
Welcome to AsyncAPI. Thanks a lot for reporting your first issue. Please check out our contributors guide and the instructions about a basic recommended setup 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.
@hartmanjan1970 you use latest generator, so @dalelane or other maintainer needs to agree to update above setting and enable support for generator v2
@dalelane fyi Generator v2 was released as we had to drop support for older Nodejs versions, and they also are not on long term support anymore either -> https://github.com/asyncapi/generator/releases/tag/v2.0.0 so you just need to update "generator": ">=1.3.0 <2.0.0", to "generator": ">=1.3.0 <3.0.0", to make sure people using latest generator can still use this java template. For you it is simple minor release as old versions of generator will still work
Describe the bug.
I want to generate the example
single-channel.yml
i get the feedback the version of the asyncapi is incorrect.The example asyncapi is v 2.2.2 and the generator and the
java-template
should be able to use this version.Expected behavior
I would expect the example to be generated flawlesly
Screenshots
my yaml file used is from: https://raw.githubusercontent.com/asyncapi/java-template/master/test/mocks/single-channel.yml
How to Reproduce
generate the example
single-channel.yml
as described in the readme🥦 Browser
None
👀 Have you checked for similar open issues?
🏢 Have you read the Contributing Guidelines?
Are you willing to work on this issue ?
None
The text was updated successfully, but these errors were encountered: