Simon-Initiative / oli-torus

Next Generation OLI Authoring and Delivery Platform
https://proton.oli.cmu.edu
MIT License
83 stars 35 forks source link

[ENHANCEMENT] [NG23-253] Optimize memory usage of lesson live #4929

Closed nicocirio closed 3 months ago

nicocirio commented 3 months ago

Link to the ticket

The base branch for this ticket is NG23-246-content-on-page-is-not-visible-on-begin-attempt because that branch has the refactor that splits the prologue from the lesson liveview. => This PR should be merged after the NG23-246 PR gets merged.

The memory usage optimization was implemented for the lesson live -as the ticket asked- and also for the prologue live and the review live, since I noticed those 2 other liveviews also had high memory usage.

The strategy for the optimization was:

Lesson Live

On mount before

lesson_live_mount_before

On mount after

lesson_live_mount_after

Hibernation before

lesson_live_hibernate_before

Hibernation after

lesson_live_hibernate_after

Review Live

On mount before

review_live_mount_before

On mount after

review_live_mount_after

Hibernation before

review_live_hibernate_before

Hibernation after

review_live_hibernate_after

Prologue Live

On mount before

prologue_live_mount_before

On mount after

prologue_live_mount_after

Hibernation before

prologue_live_hibernate_before

Hibernation after

prologue_live_hibernate_after