Files
meteor/tools/utils/gc.js
Ben Newman 1389db4631 Increase garbage collection throttling delay.
May help with this problem, which seems to stem from too much GC:
https://github.com/meteor/meteor/pull/8728#issuecomment-337636773

If this isn't enough, we could include this commit in 1.6.1:
5d212926e7
2017-10-19 11:31:23 -04:00

11 lines
434 B
JavaScript

import { throttle } from "underscore";
export const requestGarbageCollection =
// For this global function to be defined, the --expose-gc flag must
// have been passed to node at the bottom of the ../../meteor script,
// probably via the TOOL_NODE_FLAGS environment variable.
typeof global.gc === "function"
// Restrict actual garbage collections to once per second.
? throttle(global.gc, 1000)
: function () {};