Skip to content

Improving performance of posting a comment by reducing memory + CPU

Tim Zallmann requested to merge tz-mr-refactor-mem-posting into master

What does this MR do?

In the current implementation after saving a note the getter cache is invalidated 6 times. With the changes of this MR it is reduced to at most 4 as we do Object.assign instead of slice so if nothing changed on a specific note, nothing happens. At the moment even exactly the same object will cause a full invalidation as the old object is sliced out. This should reduce through less cache invalidations the memory spike + according CPU cycles.

Are there points in the code the reviewer needs to double check?

Is everything still working as expected?

Why was this MR needed?

Reduce the memory spike after posting a new note.

Does this MR meet the acceptance criteria?

What are the relevant issue numbers?

#49059 (closed)

Edited by Tim Zallmann

Merge request reports