[SERVER-25559] ImplScope should preemptively gc as we approach the soft limit for memory utilization Created: 11/Aug/16  Updated: 02/Sep/16  Resolved: 18/Aug/16

Status: Closed
Project: Core Server
Component/s: JavaScript
Affects Version/s: 3.3.10
Fix Version/s: 3.3.12

Type: Improvement Priority: Major - P3
Reporter: Mira Carey Assignee: Matt Cotter
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
is depended on by SERVER-25477 JS does not GC properly Closed
Duplicate
is duplicated by SERVER-25477 JS does not GC properly Closed
Backwards Compatibility: Fully Compatible
Sprint: Platforms 2016-08-26
Participants:

 Description   

We've currently implemented soft limits on memory consumption that attempt to catch out of memory conditions and unwind gracefully by throwing javascript exceptions. This may not be good enough however (as it still kills the running javascript job and memory use ramps higher than we like, which may cause actual ooms if many js jobs each settle at the 1gb limit).

We should periodically force a hard gc during the interrupt callback if we're above some high water mark instead.



 Comments   
Comment by Githook User [ 18/Aug/16 ]

Author:

{u'username': u'Machyne', u'name': u'Matt Cotter', u'email': u'matt.cotter@mongodb.com'}

Message: SERVER-25559 periodically call gc durring interrupt

When we are nearing our soft memory limit, calls garbage collect
during interrupt to reclaim some memory.
Branch: master
https://github.com/mongodb/mongo/commit/c3eeba479a8765394b399fc0837f45e95a8f3f6e

Generated at Thu Feb 08 04:09:33 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.