Comments (10)
Huh, okay, can you export the profiling results and email them to me?
from crater.
I've seen some background node processes get stuck at 100% cpu on my comp but I haven't figured out why, or if it's related.
from crater.
Ok. I can finally reproduce it! It's definitely something with the Meteor login code. I'll try to outline the steps to reproduce it again:
- git clone a fresh crater
- add accounts-base to meteor packages
- run crater server
- access crater from browser (leave tab open), observe normal server cpu usage
- stop crater server
- In browser's tab add the following to local storage:
Meteor.userId <some random id>
Meteor.loginToken <some random code>
Meteor.loginTokenExpires <some date>
- close tab
- start crater server again
- access crater from browser, observe high server cpu usage
There is another way to trigger the problem:
- git clone a fresh crater
- add accounts-base to meteor packages (I think you also need accounts-password for this too)
- add a link on one of the pages to run Meteor.loginWithPassword('random user', 'random password')
- run crater server
- access crater from browser (local storage should be blank), observe normal server cpu usage
- click on link that runs Meteor.loginWithPassword(), observe high server cpu usage
- note that local storage is still blank because of non existent random user in login call
I have two profiles recorded, on that is good (with normal cpu usage) and one that is bad (with high cpu usage). I'll email them over to you.
from crater.
Oh, I'll just upload the profiles here.
from crater.
Hmmm, I wonder if I'm doing something dumb in the way I sync mongo data into redux that's churning unnecessarily. Expanding the worst offenders doesn't yield much specific information...here's what I see. Did you see high CPU usage from the browser too?
from crater.
No. My if I profile my browser it seems fine. Mostly (idle). In fact, if I close my browser the cpu on the server stays pinned.
from crater.
Weird. Any idea if you see the same thing with an equivalent pure-meteor app?
from crater.
I'll check it out and report back.
from crater.
Ok. I thought I had tried this already but I obviously didn't. I tried using Node 4 instead of 6. And it's fine now.
Node: v4.7.3
Npm: v2.15.11
This is working fine. I guess Meteor is still on node v4 so there is no real way to test a plain Meteor app with node v6. I'm guessing that if I could it would cause the same problem. Maybe, anyways.
You may want to change the line in the README that says tested on Node 6.
from crater.
Hmm. Well the CI setup does perform integration tests on Node 6, not that they would catch an issue like this. When I find time I'll try to figure out exactly what's going on
from crater.
Related Issues (20)
- An in-range update of meteor-node-stubs is breaking the build 🚨 HOT 2
- An in-range update of fibers is breaking the build 🚨
- "Meteor code must always run within a Fiber" Production Server SSR only. HOT 12
- Meteor 1.5 HOT 7
- An in-range update of babel-core is breaking the build 🚨 HOT 1
- Can't resolve 'fs' from debug package HOT 3
- An in-range update of react is breaking the build 🚨 HOT 2
- An in-range update of eslint-watch is breaking the build 🚨 HOT 2
- An in-range update of redux is breaking the build 🚨 HOT 3
- An in-range update of webpack-dev-middleware is breaking the build 🚨 HOT 2
- An in-range update of defaultenv is breaking the build 🚨 HOT 1
- An in-range update of progress-bar-webpack-plugin is breaking the build 🚨 HOT 1
- An in-range update of json-loader is breaking the build 🚨 HOT 3
- An in-range update of eslint-plugin-babel is breaking the build 🚨 HOT 1
- An in-range update of babel-runtime is breaking the build 🚨 HOT 2
- An in-range update of mocha is breaking the build 🚨 HOT 4
- An in-range update of babel-register is breaking the build 🚨 HOT 1
- An in-range update of babel-cli is breaking the build 🚨 HOT 1
- An in-range update of bcrypt is breaking the build 🚨 HOT 1
- An in-range update of rimraf is breaking the build 🚨 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from crater.