summaryrefslogtreecommitdiffstats
path: root/server/authentication.js
diff options
context:
space:
mode:
authorLauri Ojansivu <x@xet7.org>2018-04-16 21:18:09 +0300
committerLauri Ojansivu <x@xet7.org>2018-04-16 21:18:09 +0300
commite26a4824cfb119a15767c4827190a6b9ab65b904 (patch)
tree201b388b93bda3ae29728861993bbf01ab879acc /server/authentication.js
parentc12e003fd3ecc50bee64931bc19febee1b99c103 (diff)
downloadwekan-e26a4824cfb119a15767c4827190a6b9ab65b904.tar.gz
wekan-e26a4824cfb119a15767c4827190a6b9ab65b904.tar.bz2
wekan-e26a4824cfb119a15767c4827190a6b9ab65b904.zip
Fix Node Fibers 100% CPU issue.
Thanks to kentonv ! Related wekan/wekan-mongodb#2, related meteor/meteor#9796
Diffstat (limited to 'server/authentication.js')
-rw-r--r--server/authentication.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/server/authentication.js b/server/authentication.js
index acc101cc..efe95015 100644
--- a/server/authentication.js
+++ b/server/authentication.js
@@ -1,5 +1,12 @@
Meteor.startup(() => {
+ // Node Fibers 100% CPU usage issue
+ // https://github.com/wekan/wekan-mongodb/issues/2#issuecomment-381453161
+ // https://github.com/meteor/meteor/issues/9796#issuecomment-381676326
+ // https://github.com/sandstorm-io/sandstorm/blob/0f1fec013fe7208ed0fd97eb88b31b77e3c61f42/shell/server/00-startup.js#L99-L129
+ import Fiber from "fibers";
+ Fiber.poolSize = 1e9;
+
Accounts.validateLoginAttempt(function (options) {
const user = options.user || {};
return !user.loginDisabled;