I analyze the memory of my app with rack-mini-profilers:
?pp=analyze-memory
At the very first beginning of my analyzation I find this section:
Total allocated: 11701453 bytes (143079 objects) Total retained: 1380491 bytes (15087 objects)
allocated memory by gem
-----------------------------------
1959594 sprockets-3.7.1
1520426 activesupport-5.0.2
1324106 other
1120203 bson-4.2.1
1111010 scout_apm-3.0.0.pre9
1030375 actionview-5.0.2
781675 2.4.1/lib
583067 gn2016/app
495216 mongoid-6.1.0
380060 actionpack-5.0.2
375379 erubis-2.7.0
370934 mongo-2.4.1
174568 i18n-0.8.1
72385 webrat-0.7.3
57638 cancancan-1.16.0
45136 countries-7404f9774051
40912 dalli-2.7.6
33412 nokogiri-1.7.1
1000 Largest strings:
.select2-container {
box-sizing: border-box;
display: inline-block;
margin: 0;
# and all of my CSS comes here
.......
......
.....
....
...
..
.
It lists the whole select2 CSS file followed by the whole bootstrap CSS and so on...
in my application.scss I have this:
/*
*
*= require select2
*= require select2-bootstrap
*/
@import 'font-awesome';
@import 'custom';
Is this normal behaviour that the CSS is in memory as a string? Is this a misconfiguration?
I am searching for a memory leak in my app and thought that this could be a starting point to look at.