[undertow-dev] Access JBoss MSC service from ServletExtension

Tomaž Cerar tomaz.cerar at gmail.com
Fri Jan 23 12:17:45 EST 2015


ServletExtension is not really meant to be also WildFly extension... but
there is some overlap.
As ServletExtension would work also outside wildfly deployment.

what you could do is use Service Activator that implements
*org.jboss.msc.service.ServiceActivator*
and register it as a service in your deployment.

This service activator will be than activated with deployment is started.
And example how to use this can be found at:
http://management-platform.blogspot.com/2012/07/co-located-management-client-for.html

other option would be to write proper WildFly extension which is bit more
work.
take a look at
https://docs.jboss.org/author/display/WFLY8/Extending+WildFly+8
for how to do that.

--
tomaz

On Fri, Jan 23, 2015 at 1:25 PM, Harris, Carl <ceharris at vt.edu> wrote:

> I made a ServletExtension that adds an AuthenticationMethod to an Undertow
> servlet deployment.  I have a basic mock up of the authentication method
> working.
>
> In order to move beyond the mock up, my authentication mechanism needs to
> use a service that my Wildfly extension puts into the (JBoss MSC) service
> registry.  I’m not seeing how to put the pieces together to get a reference
> to the service registry so I can locate my service.
>
> Does someone have an example that I could reference or tips on how I might
> go about this?
>
> Thanks,
>
> Carl
>
>
>> Carl Harris
> Chief Technology Architect
> Virginia Tech
>
>
> _______________________________________________
> undertow-dev mailing list
> undertow-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/undertow-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/undertow-dev/attachments/20150123/c1c2b386/attachment-0001.html 


More information about the undertow-dev mailing list