Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Kotlin extensions for reactive link builders #2244

Open
huberchrigu opened this issue Oct 15, 2024 · 2 comments
Open

Add Kotlin extensions for reactive link builders #2244

huberchrigu opened this issue Oct 15, 2024 · 2 comments

Comments

@huberchrigu
Copy link

The MVC link builder has some great Kotlin extensions that reduce the boilerplate code quite a lot. But when using reactive, which is quite a valid use case when using Kotlin, there is no such support. Writing model assemblers for both reactive and coroutine controllers is cumbersome.
This pull request would simplify model assemblers in these cases: #2228.

Here's a sample diff of how I could change an existing reactive model assembler with the PR:
image

Here's a another example for the introduced coroutine assembler:
image
Also, in the controller, I do not have to add awaitSingle() after every call of the assembler.

@huberchrigu huberchrigu changed the title Improve Add Kotlin extensions for reactive link builders Oct 15, 2024
@huberchrigu
Copy link
Author

I started my own library for these extensions: https://github.com/huberchrigu/spring-hateoas-extensions. If you're ever interested in merge my PR, I can update it with my latest changes before.

@rishiraj88
Copy link

Looks interesting; I would like to have a deeper look by weekend.
Keep on developing and inspiring, @huberchrigu !

For now, I have started "watching" and have forked off your repo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants