🎄 Happy Holidays! 🥳

Most of Solace is closed December 24–January 1 so our employees can spend time with their families. We will re-open Thursday, January 2, 2024. Please expect slower response times during this period and open a support ticket for anything needing immediate assistance.

Happy Holidays!

Please note: most of Solace is closed December 25–January 2, and will re-open Tuesday, January 3, 2023.

An error occurred The event RideUpdated has a topic that is not supported by the AsyncAPI specificat

mewren
mewren Member Posts: 2
edited March 2022 in PubSub+ Event Portal #1

I am doing the tutorial:

Be Real-Time: Design, Document, Discover and Develop Event...https://codelabs.solace.dev/codelabs/design-document-discover-develop-event-driven-apis/index.html?index=..%2F..index#10

I am on Step 11 and exporting the YAML from the ProcessPayment application

I get this error after I select YAML and click the button:

An error occurredThe event RideUpdated has a topic that is not supported by the AsyncAPI specification. Topic addresses must only contain letters, numbers and one or more of the following special characters: !#$&()*+,-./:;=[]_~

My RideUpdated topic still has the placeholder ids in it:

"taxinyc/ops/ride/updated/v1/${ride_status}/${driver_id}/${passenger_id}/${current_latitude}/${current_longitude}"

So then I realized that the $ ones were literals, not variables. So I created new variables (I was not able to edit and change from literal to variable).

Now my RideUpdated topic is:

taxinyc/ops/ride/updated/v1/{${ride_status3}}/{${driver_id}}/{${passenger_id}}/{${current_latitude}}/{${current_longitude} }


However I still get the error.

The tutorial seems a bit out of date visually, all the other changes were fine. But not sure what I am doing wrong here.

Update: -

I changed the topic again, using just the base strings (as variables)

taxinyc/ops/ride/updated/v1/{ride_status}/{driver_id}/{passenger_id}/{current_latitude}/current_longitude

Now that part passes, but now I get an error on PaymentCharged.

I did the tutorial along with the SolaceAcademy video (not the written down steps) - so that is probably just an old version.

Video needs updating. "Event Portal - getting started" @Dishant Langayan @dishantlangayan

Best Answer

  • giri
    giri Member, Administrator, Employee Posts: 116 admin
    #2 Answer ✓

    Hi @mewren, Thanks for pointing this out. There have been some changes in the Event Portal & the AsyncAPI spec compatibility requires fixing in this codelab. Let us explore this codelab in full context and amend it as necessary at the earliest. Will update you when ready.

Answers

  • giri
    giri Member, Administrator, Employee Posts: 116 admin
    #3 Answer ✓

    Hi @mewren, Thanks for pointing this out. There have been some changes in the Event Portal & the AsyncAPI spec compatibility requires fixing in this codelab. Let us explore this codelab in full context and amend it as necessary at the earliest. Will update you when ready.

  • mewren
    mewren Member Posts: 2

    Thanks, please also look into the ag command in step 11

    ag -o ProcessPayment -p binder=solace -p artifactId=ProcessPayment -p groupId=org.taxi.nyc -p javaPackage=org.taxi.nyc -p host=taxi.messaging.solace.cloud:55555 -p username=public-taxi-user -p password=iliketaxis -p msgVpn=nyc-modern-taxi ProcessPayment.yaml @asyncapi/java-spring-cloud-stream-template

    Something went wrong:

    Error: ENOENT: no such file or directory, copyfile '/xxx/solace_training/ProcessPayment/src/main/java/#/properties/driver.java' -> '/xxx/solace_training/ProcessPayment/src/main/java/org/taxi/nyc/#/properties/driver.java'

       at Object.copyFileSync (node:fs:2802:3)

       at moveFile (/usr/local/lib/node_modules/@asyncapi/generator/node_modules/@asyncapi/java-spring-cloud-stream-template/hooks/post-process.js:134:6)

       at processSchema (/usr/local/lib/node_modules/@asyncapi/generator/node_modules/@asyncapi/java-spring-cloud-stream-template/hooks/post-process.js:90:7)

       at /usr/local/lib/node_modules/@asyncapi/generator/node_modules/@asyncapi/java-spring-cloud-stream-template/hooks/post-process.js:22:7

       at Map.forEach (<anonymous>)

       at generate:after (/usr/local/lib/node_modules/@asyncapi/generator/node_modules/@asyncapi/java-spring-cloud-stream-template/hooks/post-process.js:21:27)

       at /usr/local/lib/node_modules/@asyncapi/generator/lib/generator.js:793:20

       at Array.map (<anonymous>)

       at Generator.launchHook (/usr/local/lib/node_modules/@asyncapi/generator/lib/generator.js:790:28)

       at Generator.generate (/usr/local/lib/node_modules/@asyncapi/generator/lib/generator.js:205:18)

       at /usr/local/lib/node_modules/@asyncapi/generator/cli.js:154:9

  • giri
    giri Member, Administrator, Employee Posts: 116 admin

    Hi @mewren - please check the codelab now. Following changes have been made to bring the codelab up-to-date and working.

    a) We now have updated files that are ready for import (have fixes around handling the "$Id" filed issue in the asyncapi codegen tool)

    b) An issue in the python-paho template has prevented us from completing the InvoiceSystem microservice build action - we have switched this step to use nodejs-template

    Please review it when you can, and let us know if you encounter any issues.

    Thanks!!