Tunemygc2x TuneMyGC optimal MRI Ruby 2.1+ Garbage Collection

App discourse ActionController on Ruby 2.2.0


Suggested GC config (recommended based on 11 samples)  

Variable Value
RUBY_GC_HEAP_INIT_SLOTS 330667
RUBY_GC_HEAP_FREE_SLOTS 992001
RUBY_GC_HEAP_GROWTH_FACTOR 1.03
RUBY_GC_HEAP_GROWTH_MAX_SLOTS 132267
RUBY_GC_HEAP_OLDOBJECT_LIMIT_FACTOR 1.2
RUBY_GC_MALLOC_LIMIT 28554243
RUBY_GC_MALLOC_LIMIT_MAX 51397637
RUBY_GC_MALLOC_LIMIT_GROWTH_FACTOR 1.32
RUBY_GC_OLDMALLOC_LIMIT 32139872
RUBY_GC_OLDMALLOC_LIMIT_MAX 57851770
RUBY_GC_OLDMALLOC_LIMIT_GROWTH_FACTOR 1.2

  Memory usage (peak and current RSS values across all samples)

  GC cycles (overview of GC cycle frequency and types)

  GC reasons (what triggered GC?)

  Request duration (processing overhead)

  Request GC activity (the number of minor and major GCs during processing)

  Request Objects (allocation rate and promotion during processing)

  Request Slots (distribution of objects into slots during processing)

  Request leak suspects (allocation rates of different controller actions)

  Request Malloc activity (off-heap memory allocation and limits during processing)

  GC cycle duration (overhead of a GC cycle (affected by lazy sweep))

  GC cycle activity (major and minor GC distribution)

  GC cycle Objects (relationship of per GC cycle allocation rate and promotion)

  GC cycle Slots (per GC cycle distribution of objects into slots)

  GC cycle Malloc activity (per GC cycle off-heap memory allocation and limits)

  ObjectSpace progression (growth of object types on the Ruby heap)