-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sluggish startup times #6009
Comments
to biggest offenders are
|
ember-try was updated in ember-cli/ember-try#75, and that was released in v0.2.3. |
this was seems to not show up all the time.. |
updated:
|
@stefanpenner if we require the dependencies on demand how will this work with ES6 modules if we would switch at some point? My understanding is that import statements must be at the top level, correct? |
@Turbo87 Hopefully |
There will be a way to also require lazily/on-demand, it has not yet been fleshed out though. |
we could load some of the other deps lazily:
but something tells me this might not be the right avenue |
i think its fine for us to be mindful about require ordering and timing to ensuring it is pay as you go when possible. We should drive it based on identifying slow points and addressing them. |
Makes sure dependecies are loaded on demand results: https://gist.github.com/twokul/54542ed6783e20bbfd2f62bd9dfb89c7 before: ``` Total require(): 1375 Total time: 1.1s ``` after: ``` Total require(): 995 Total time: 832ms ``` depends on #6071 related to #6009
In my setup (ember 2.7, node 6.3.1), A signification amount of bottlenecks may also be found doing the same test with |
Flamegraph is also an interesting tool for performance instrumentation. Sam Saffron has been using flamegraph to pin point the bottlenecks of discourse rails server. He wrote a blog post about performance instrumentation and finding bottlenecks with flamegraph. Nodejs has some implemenations of flamegraph, for example stackvis, 0x. |
@musaffa yup! This issue outlines some things that should help many scenarios for you, as it goes to make sure we don't eagerly require too much. This should help. |
We have made progress. The original issue has improved, but we will continue to reduce dependency weight which will hopefully continue to help :) |
using: https://www.npmjs.com/package/time-require
The text was updated successfully, but these errors were encountered: