Compiling with meteor when developing can be sooooo slow. I know this is a known issue. Is this something the meteor team is looking to rectify? Any insight would be appreciated.
What OS are you using?
I’ve got a macbook pro. 8GB ram 2.7 GHz i5
OS - macOS Sierra
Other than making sure you are using the latest version of meteor, and disabling any anti-virus/anti-malware scanning, you might try suggestions from the following:
None of this seems to be making a difference. If I run
METEOR_PROFILE=1 meteor the majority of the build time appears to be coming from
(#1) Profiling: Server startup
(#1) Total: 9,090 ms (Server startup)
This seems to be related to all the packages. Does this need to update everytime I alter front end code?
It shouldn’t need to unless you have code being updated that both the client and server depend on.
Ooo - I like that!
Now, if we only had a tool to analyse the output of the
meteor process when using the various debugging environment variables…
What do you mean? This package allows you to take profiles of both the meteor build and server process at any time
My point was more about how to digest the information provided by something like
METEOR_DEBUG_BUILD=1 METEOR_PROFILE=10 meteor run
and to some extent
meteor list --tree --weak
as another aid to problem solving.
I’m going to do a blog post on performance analysis of CPU profiles soon; has vastly more info than the debug output
Ok, I’ve done my best here. I haven’t been able to get it to produce
I’m wondering if this is related to my folder structure.
pages folders are located in the
imports folder. Should it be:
imports client ui pages
The latter two links aren’t working for me; I suspect that the
startup.cpuprofile will be the most relevant one. Happy to take a look once you’ve re-uploaded it
When you save changes to code, what does the terminal say?
Client modified -- refreshing or
Meteor server restarted?
If you’re only modifying client code it sd say the former.
Client modifications take way less time than server restarts.
Sorry about that. Not sure why they didn’t work. Links have now been fixed.
Yeah it’s meteor server restarted. I don’t understand why the imports folder would cause a full server restart.
clientfolder inside of
- Put everything client related (ui, startup, etc) there. Then it will only refresh the browser, not the whole server process.
- Bang! PROFIT
Everything that’s not inside
server folders is loaded both on client and server. And changes to server code require restarts.
Thanks for that. Driving me crazy.
I think there’s something wrong with your dev DB (or your connection to the dev DB). In the server startup profile, it spends 1.5 seconds actually starting up and then around 9 seconds very occasionally making DB related calls and waiting a long time.