Skip to content

[hotfix] catch OOM error in `Manager.loadEnvelop`

aguestuser requested to merge hotfix-catch-oom-errors-in-load-envelope into master
  • context: experiencing bugs on startup that cause numbers to become completely unresponsive
  • likely cause:
    • Manager.loadEnvelop tries to allocate byteArray of contentLen
    • but contentLen is ridiculously large b/c file was garbage, causing in.readInt() to return nonsense value
    • :. when system tries to allocate byte array, it runs out of heap space
  • attempted fix:
    • catch the OOM and return null (which is handled gracefully by caller in `Manager.retryFailedMessages``

Merge request reports

Loading