Coder Social home page Coder Social logo

'Fast' dependency injection? about dagger HOT 4 CLOSED

square avatar square commented on August 27, 2024
'Fast' dependency injection?

from dagger.

Comments (4)

patrickbaumann avatar patrickbaumann commented on August 27, 2024

It's nothing official or scientific, but I threw together a couple of demo Android apps that are identical in function but built with RoboGuice in one implementation and Dagger in the other. Source and results are at http://github.com/patrickbaumann/daggervsroboguice

It's a simple example but in the worst case, Dagger sliced off about 350ms of start up time compared to Guice on a Galaxy Nexus.

from dagger.

scompt avatar scompt commented on August 27, 2024

Here's a tweet from @swankjesse where he mentions a couple numbers between Guice and Dagger.

from dagger.

swankjesse avatar swankjesse commented on August 27, 2024

On Fri, Dec 7, 2012 at 1:14 AM, Joe [email protected] wrote:

Are there any plans to benchmark or put numbers behind the 'fast' claim?
I'm curious how it compares to Guice specifically.

Yeah, the speed difference will depend on the size of your app. Suppose you
have a small app that spends 100ms in Guice each time it starts up. The
maximum improvement you could see in such an app is 100ms. Some of the apps
I've worked on spent a long time in Guice at startup: 3000ms or more (on
some older devices, anyway). This is where Dagger's avoidance of reflection
and runtime annotations pays off.

from dagger.

JakeWharton avatar JakeWharton commented on August 27, 2024

Closing. For further discussions please see the Google+ community or the mailing list.

from dagger.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.