-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Create quarkus hal extension for resteasy and reactive #25396
Conversation
This comment has been minimized.
This comment has been minimized.
Thanks a lot @Sgitario. I'll have a look next week. |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
And another solution could be to change |
<dependency> | ||
<groupId>io.quarkus</groupId> | ||
<artifactId>quarkus-resteasy-links-deployment</artifactId> | ||
<scope>test</scope> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had to explicitly add this dependency, I guess because we had to use the -deployment
version. However, this is not necessary to be added when using quarkus-hibernate-orm-rest-data-panache
(there are tests to verify this).
<dependency> | ||
<groupId>io.quarkus</groupId> | ||
<artifactId>quarkus-resteasy-links-deployment</artifactId> | ||
<scope>test</scope> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I had to explicitly add this dependency, I guess because we had to use the -deployment
version. However, this is not necessary to be added when using quarkus-spring-data-rest
(there are tests to verify this).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great work, thanks!
I've just added a few comments
extensions/hal/runtime/src/main/java/io/quarkus/hal/HalService.java
Outdated
Show resolved
Hide resolved
extensions/hal/runtime/src/main/java/io/quarkus/hal/HalService.java
Outdated
Show resolved
Hide resolved
...easy-links/deployment/src/main/java/io/quarkus/resteasy/links/deployment/LinksProcessor.java
Outdated
Show resolved
Hide resolved
return acceptMediaType.contains(RestMediaType.APPLICATION_HAL_JSON); | ||
} | ||
|
||
private Class<?> findEntityClass() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can leave addressing this for a following PR, but in RESTEasy Reactive we generally try to avoid performing reflection as much as possible as it has a negative effect on both the execution speed and memory consumption. This data is generally available at build time, so we try to leverage it as much as possible.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've removed the second part of this method. For the first part, we can do it in the next iteration.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So the second part was not needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, it wasn't needed at all.
...s/deployment/src/main/java/io/quarkus/resteasy/reactive/links/deployment/LinksProcessor.java
Outdated
Show resolved
Hide resolved
...oyment/src/test/java/io/quarkus/resteasy/reactive/links/deployment/AbstractHalLinksTest.java
Outdated
Show resolved
Hide resolved
The quarkus-hal is a new extension that supports both resteasy and resteasy reactive.
This comment has been minimized.
This comment has been minimized.
@gsmet this wasn't mentioned in https://quarkus.io/blog/quarkus-2-10-0-final-released/ |
The quarkus-hal is a new extension that supports both resteasy and resteasy reactive.
This is a follow-up action from #25217 (comment)