Skip to content

Audit Memory Leaks #63979

@mountiny

Description

@mountiny

Coming from here

Background:

Some third party libraries used in App (like RNPerformance or Airship) set up app lifecycle listeners. Failure to cleanup these listeners on React Native instance destruction results in memory leaks (memory was allocated for the listeners but never released). Memory leaks can result in reduced performance and degraded app responsiveness over time.

Problem:

When navigating between OD and ND or reloading the Expensify App, many global listeners leak through RN instance destruction, which degrades app performance.

Solution:

We should:

  • Conduct a comprehensive audit of the app to find all the memory leaks we can. This includes profiling the app in different scenarios (reloading, navigating) to pinpoint exactly where leaks occur.
  • Implement fixes for each identified issue incrementally.
  • (optional) After solving all leaking scenarios, repeat the audit in 6 months to ensure no new memory leaks have been introduced.
Issue OwnerCurrent Issue Owner: @mateuuszzzzz

Metadata

Metadata

Labels

AutoAssignerNewDotQualityUsed to assign quality issues to engineersBugSomething is broken. Auto assigns a BugZero manager.ReviewingHas a PR in reviewWeeklyKSv2

Type

No type

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions