1

While working on a simple gallery app I realized that my ember app is slowly eating up memory.

I created a very simple app to demonstrate the issue: index.html app.js test.js.

Test setup:

From what I can see via Chrome->Profile->Snapshot Test 2 consumes significantly more memory then Test 1.

Can somebody help me understand what's causing that issue?

david8401
  • 379
  • 1
  • 3
  • 11
  • Do you see the same issue with the production build of ember? – Kingpin2k Aug 20 '13 at 00:57
  • How much memory is consumed in each test for you? I follow your steps and I am getting 11.2MB for test1 and 12.3MB for test2. – Marcio Junior Aug 20 '13 at 01:59
  • @Daniel Yes, I see the same issue also with the production build of ember.js. The amount of memory consumed depends on several things. But my point is that test2 is always higher although it should theoretically be about the same size, isn't it? – david8401 Aug 20 '13 at 11:04
  • Theoretically, but you don't know when garbage collection occurs in the browser. It isn't guaranteed that old references from Ember will be destroyed immediately or in an hour. – Kingpin2k Aug 20 '13 at 22:09

1 Answers1

0

It isn't Ember Model, I can tell you that much. I just stalked through the code a few times and Ember Model is returning from cache and not instantiating anything new each time. I would recommend running the production build of ember js.

Kingpin2k
  • 47,277
  • 10
  • 78
  • 96