Memory use is quadratic in the number of stacks
Bug #1455589 reported by
Zane Bitter
This bug affects 2 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Heat |
Fix Released
|
High
|
Steve Baker | ||
Juno |
Fix Released
|
High
|
Steve Baker | ||
Kilo |
Fix Released
|
High
|
Steve Baker |
Bug Description
Since the change to deal with nested stacks over RPC rather than work with the whole tree of stacks in-memory, we are using enormous amounts of memory.
This is partly because the Stack.root_stack property works by loading the parent *resource* from the parent stack - meaning the lazily-loaded resources are loaded even though we don't need them for the purposes of getting the parent stack.
That is irrelevant, however, because we then call total_resources() on the root stack, and that loads every single stack in the tree and all of their resources in order to count the total number resources. Thus, memory use is O(n^2) in the size of the tree :(
Changed in heat: | |
milestone: | none → liberty-1 |
Changed in heat: | |
importance: | Critical → High |
Changed in heat: | |
status: | New → Triaged |
Changed in heat: | |
assignee: | nobody → Rico Lin (rico-lin) |
Changed in heat: | |
assignee: | Rico Lin (rico-lin) → Steve Baker (steve-stevebaker) |
Changed in heat: | |
assignee: | Michał Jastrzębski (inc007) → Steve Baker (steve-stevebaker) |
Changed in heat: | |
assignee: | Steve Baker (steve-stevebaker) → Michał Jastrzębski (inc007) |
Changed in heat: | |
assignee: | Michał Jastrzębski (inc007) → Steve Baker (steve-stevebaker) |
Changed in heat: | |
assignee: | Steve Baker (steve-stevebaker) → Michał Jastrzębski (inc007) |
Changed in heat: | |
assignee: | Michał Jastrzębski (inc007) → Steve Baker (steve-stevebaker) |
tags: | added: kilo-backport-potential |
Changed in heat: | |
status: | Fix Committed → Fix Released |
tags: | removed: kilo-backport-potential |
tags: | added: juno-backport-potential |
tags: | removed: juno-backport-potential |
Changed in heat: | |
milestone: | liberty-1 → 5.0.0 |
To post a comment you must log in.
Fun fact: the total_resources() function was introduced (for bug 1215100) to prevent users from exhausting memory.