Skip to content

feat(asyncapi): Digest reply info from spec into Operation model - #1936

Merged
lbroudoux merged 3 commits into
microcks:1.13.xfrom
adamhicks:adam-reply
Jan 28, 2026
Merged

lbroudoux merged 3 commits into
microcks:1.13.xfrom
adamhicks:adam-reply

Conversation

@adamhicks

Copy link
Copy Markdown
Contributor

Description

  • Define ReplyInfo for holding asyncapi reply info
  • Refactor the AsyncAPICommons.complete[Model]Bindings to use an interface, BindingsHolder
    • So that we can put the reply bindings into the ReplyInfo instead of the Operation where they would overwrite the channel bindings.
    • I also combined the parsing of different binding types into one switch, it didn't look like the bindings should be parsed differently based on their parent node, i.e. channel, message, or operation.

Related issue(s)

See #1916

@github-actions

Copy link
Copy Markdown

👋 @adamhicks

Welcome to the Microcks community! 💖

Thanks and congrats 🎉 for opening your first pull request here! Be sure to follow the pull request template or please update it accordingly.

Hope you have a great time there!

@adamhicks

Copy link
Copy Markdown
Contributor Author
➜ mvn test -Dtest=AsyncAPI3ImporterTest -pl webapp 
[INFO] Scanning for projects...
[INFO] 
[INFO] ------------------< io.github.microcks:microcks-app >-------------------
[INFO] Building Microcks App 1.13.3-SNAPSHOT
[INFO]   from pom.xml
[INFO] --------------------------------[ jar ]---------------------------------
[INFO] 
[INFO] --- resources:3.1.0:resources (default-resources) @ microcks-app ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 13 resources
[INFO] Copying 3 resources
[INFO] 
[INFO] --- compiler:3.1:compile (default-compile) @ microcks-app ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] --- spotless:2.39.0:check (default) @ microcks-app ---
[INFO] Spotless.Java is keeping 316 files clean - 0 needs changes to be clean, 0 were already clean, 316 were skipped because caching determined they were already clean
[INFO] 
[INFO] --- resources:3.1.0:testResources (default-testResources) @ microcks-app ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 167 resources
[INFO] 
[INFO] --- compiler:3.1:testCompile (default-testCompile) @ microcks-app ---
[INFO] Nothing to compile - all classes are up to date
[INFO] 
[INFO] --- surefire:3.2.5:test (default-test) @ microcks-app ---
[INFO] Using auto detected provider org.apache.maven.surefire.junitplatform.JUnitPlatformProvider
[INFO] 
[INFO] -------------------------------------------------------
[INFO]  T E S T S
[INFO] -------------------------------------------------------
[INFO] Running io.github.microcks.util.asyncapi.AsyncAPI3ImporterTest
[INFO] Tests run: 8, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.874 s -- in io.github.microcks.util.asyncapi.AsyncAPI3ImporterTest
[INFO] 
[INFO] Results:
[INFO] 
[INFO] Tests run: 8, Failures: 0, Errors: 0, Skipped: 0
[INFO] 
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  2.051 s
[INFO] Finished at: 2026-01-27T14:34:38Z
[INFO] ------------------------------------------------------------------------

@adamhicks

Copy link
Copy Markdown
Contributor Author

I've created this as a small PR, planning to move onto the Message model next but if you'd rather have all the changes in one PR, then I can close this and open a bigger one later.

@lbroudoux

Copy link
Copy Markdown
Member

I've created this as a small PR, planning to move onto the Message model next but if you'd rather have all the changes in one PR, then I can close this and open a bigger one later.

Hey @adamhicks

Thanks for this one. Yes, small PR are easiest to merge and we know they're all part of a bigger epic.
Just one thing here: at the moment, developments are on the 1.13.x branch - this is not convenient and we're looking to change that in #1901 but that's how it is for now .... Could you rebase your work, starting and targeting the 1.13.x branch?

I'm gonna review your work now ;-)

@lbroudoux
lbroudoux changed the base branch from master to 1.13.x January 27, 2026 16:11

@lbroudoux lbroudoux left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Got one comment on the flattening of binding attributes import... I'd prefer to keep the extra controls to ensure we have a well-formed AsyncAPI file.

@lbroudoux lbroudoux left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Sorry, I didn't see that some Javadoc comments were missing. It makes the build fail. I think this is the last required changes then I'll merge.

@adamhicks adamhicks changed the title asyncapi: Digest reply info from spec into Operation model feat(asyncapi): Digest reply info from spec into Operation model Jan 28, 2026
Signed-off-by: Adam Hicks <[email protected]>
@adamhicks

Copy link
Copy Markdown
Contributor Author

Sorry, I didn't see that some Javadoc comments were missing. It makes the build fail. I think this is the last required changes then I'll merge.

whoops, i didn't see the build failure(s). fixed now

@lbroudoux lbroudoux left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks all good! Thanks @adamhicks for this PR!

@lbroudoux
lbroudoux merged commit 2c6a074 into microcks:1.13.x Jan 28, 2026
8 of 9 checks passed
@lbroudoux lbroudoux added this to the Next milestone Jan 28, 2026
@github-actions

Copy link
Copy Markdown

🎉 @adamhicks

You are now a Microcks community contributor! 💖

Thanks and congrats 🚀 on merging your first pull request! We are delighted and very proud of you! 👏

📢 If you're using Microcks in your organization, please add your company name to this list. 🙏 It really helps the project to gain momentum and credibility. It's a small contribution back to the project with a big impact.

If you need to know why and how to add yourself to the list, please read the blog post "Join the Microcks Adopters list and Empower the vibrant open source Community 🙌"

Kudos and please keep going, we need you 🙌

@adamhicks
adamhicks deleted the adam-reply branch January 29, 2026 09:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants