Skip to content

Commit

Permalink
Make check for RESTEasy Classic stricter
Browse files Browse the repository at this point in the history
  • Loading branch information
geoand authored and manofthepeace committed May 16, 2023
1 parent 2bc7f4e commit 3aa6382
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
import io.quarkus.arc.deployment.BeanContainerBuildItem;
import io.quarkus.arc.deployment.BuildTimeConditionBuildItem;
import io.quarkus.arc.deployment.GeneratedBeanBuildItem;
import io.quarkus.bootstrap.classloading.QuarkusClassLoader;
import io.quarkus.deployment.Capabilities;
import io.quarkus.deployment.Capability;
import io.quarkus.deployment.annotations.BuildProducer;
Expand Down Expand Up @@ -79,7 +80,9 @@ public class ResteasyReactiveCommonProcessor {
@BuildStep
void searchForProviders(Capabilities capabilities,
BuildProducer<AdditionalApplicationArchiveMarkerBuildItem> producer) {
if (capabilities.isPresent(Capability.RESTEASY) || capabilities.isPresent(Capability.REST_CLIENT)) {
if (capabilities.isPresent(Capability.RESTEASY) || capabilities.isPresent(Capability.REST_CLIENT)
|| QuarkusClassLoader.isClassPresentAtRuntime(
"org.jboss.resteasy.reactive.server.injection.JaxrsServerFormUrlEncodedProvider")) { // RESTEasy Classic could be imported via non-Quarkus dependencies
// in this weird case we don't want the providers to be registered automatically as this would lead to multiple bean definitions
return;
}
Expand Down

0 comments on commit 3aa6382

Please sign in to comment.