Open vietj opened 7 years ago
Actually I believe it would be a good thing to do and provide a good basis for writing web app with Weld / Vert.x and JaxRS . cc @emmanuelbernard
@vietj FYI I've been able to modify the HelloWorldService
example resource to @Inject
a CDI bean. The problem is that the CDI request context is not activate when VertxRequestHandler
delegates to org.jboss.resteasy.plugins.server.vertx.RequestDispatcher
. And so @RequestScoped
resources (default) do not work. It would be great if we could wrap/intercept the body handler set by VertxRequestHandler
.
Steps to reproduce:
org.jboss.resteasy:resteasy-cdi
and org.jboss.weld.vertx:weld-vertx-core
on the class pathWeldVerticle
before the verticle starting VertxResteasyDeployment
VertxResteasyDeployment
is started, i.e. deployment.setInjectorFactoryClass("org.jboss.resteasy.cdi.CdiInjectorFactory")
I will create a branch of vertx-examples
so that we can play with code.
Another reason for integrating with RESTEasy is that it would allow the use of Enunciate's documentation generation for JAX-RS-annotated REST interfaces.
Resteasy provides a Vert.x web server implementation since Resteasy 3.1.
Would it make sense to provide an integration as a vertx-weld module to allow to combine that with service proxies and such ?