Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sisu-users] Sisu and Dagger

On 15 February 2014 16:43, Benson Margulies <benson@xxxxxxxxxxxxx> wrote:
JvZ expressed the opinion recently that Dagger might qualify as a superior comestible to Guice.

Dagger was written for constrained devices where reflection is expensive. There are Guice features that don't exist in Dagger such as method injection, which would make it impossible to use Dagger as a replacement for features like the Plexus compatibility layer. Dagger also relies on code-generation rather than reflection and its SPI is limited, which makes it harder to introspect bindings at runtime.
 
But looks to me as if Sisu's feature-set includes might lead to a Sisu+Dagger idea just like Sisu+Guice: the lifecycle module, if nothing else, looks relevant. Any thoughts here?

I think it's still early days, the SPI (http://square.github.io/dagger/javadoc/index.html) needs more work. But there are things we can do in the meantime to improve Sisu's portability, such as minimising use of Guice types where possible. This has been done for the top-level org.eclipse.sisu package, but there are a few other places where we could be more decoupled from Guice.

Right now my focus is on implementing the various service/extension registry support, but if someone wants to investigate Dagger further (especially how any Sisu integration might work with the code-generation aspect) and report back to the list that would be great :)

--
Cheers, Stuart

Back to the top