Bangle.js: fix memory leak from HTTP requests #3148
No reviewers
Labels
No Label
device mi band 7
activity post processing
activity/health
Android 12
Android 13
android integrations
architecture
Bangle.js
bug
changes requested
charts
details not provided
developer documentation
device amazfit band 5
device amazfit bip
device amazfit cor
device Casio
device fossil
device garmin
device gtr 2e
device gts 2 mini
device h30
device hplus
device huami
device Huawei
device liveview
device mi band
device mi band 2
device mi band 3
device mi band 4
device mi band 5
device mi band 6
device no.1 f1
device pace
device pebble
device pebble 2
device pinetime infinitime
device request
device sony
device support
device watch 9
device xiaomi
discussion
documentation
duplicate
enhancement
feature request
Gadgetbridge
good first issue
help wanted
i am developing my own app can you help
icebox
intent api
internationalisation
invalid
needs work
network companion app
new device
no feedback
not a bug
notifications
one of the 1000 issues about disconnection
pairing/connecting
potentially fixed / confirm and close
question
research
security
seems abandoned
Solved, waiting for F-Droid release
suggest to close
task
user interface / UX
wear os
weather
wontfix
Zepp OS
No Milestone
No Assignees
3 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: Freeyourgadget/Gadgetbridge#3148
Loading…
Reference in New Issue
No description provided.
Delete Branch "rigrig/Gadgetbridge:banglejs-fix-http-memory-leak"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Every call to Volley.newRequestQueue() creates a new global thread pool, which isn't automatically cleaned up once the request completes.
With this commit we create a RequestQueue around on first use, and reuse it for subsequent requests.
It leaked memory at about 1MB/request according to this post: https://forum.espruino.com/conversations/386933
This looks great - thanks!
@rigrig I merged the changes, but accidentally rebased your commit, which broke the signature.. Please let me know if this is OK, or whether I should revert the commit so that you can re-open a MR with a signed one
Thanks!
The rebase is fine with me.