users@jersey.java.net

Re: IoC-integration: injection based on annotation implemented (spring-integration branch)

From: Frank Martínez <mnesarco_at_gmail.com>
Date: Sat, 12 Apr 2008 11:53:06 -0500

Hi Martin,

On Sat, Apr 12, 2008 at 7:55 AM, Martin Grotzke
<martin.grotzke_at_freiheit.com> wrote:
> Hi,
>
> the spring-integration branch now supports annotation based injection.
>
> There's one annotation defined by jersey, that pulls instances from the
> component provider: @Inject. So it's possible to have a resource class
> that is managed by jersey with dependencies managed by some
> IoC-framework.
> @Paul: I defined the @Inject annotation in the package
> "com.sun.ws.rest.spi.resource". Is this ok, or is there a better place
> for it?
>
> Additionally it's possible to add an injectable per annotation to the
> WebApplication, so one could create its own @DAO annotation :)
>

Thanks a lot! Now one can integrate any IoC-framework easy with Jersey
managed resources.
Great work.

> These tests show and test both use scenarios:
> - com.sun.ws.rest.impl.inject.AnnotationInjectableTest
> - com.sun.ws.rest.impl.inject.InjectAnnotationInjectableTest
>
> The spring subproject in the spring-integration branch now contains
> tests (still some missing) - these tests make also use of the inject
> annotation.
>
> When I find some time I will add some notes about spring integration to
> the wiki...
>
> Cheers,
> Martin
>
>
>

Cheers,
Frank.

-- 
Frank D. Martínez M.
Asimov Technologies Ltda.
Blog: http://www.ibstaff.net/fmartinez/