You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We have a topic with ~55K posts and over 600 users have bookmarks (last read markers)
Fork the topic and select at least one post.
What you expected
New topic created, old posts were moved out of the original topic.
What happened instead
NodeBB crashes with out of memory error (currently running in a 4GB vm)
I tracked this down to src/topics.js:Topics.updateTopicBookmarks. In particular, using posts.getPostIndices inside async.map. A more scalable approach would be something like async.eachLimit and moving the stuff that uses the result of async.map into an async.waterfall within the async.eachLimit.
Please include the following information when submitting a bug report/issue:
I tracked this down to
src/topics.js:Topics.updateTopicBookmarks
. In particular, usingposts.getPostIndices
insideasync.map
. A more scalable approach would be something likeasync.eachLimit
and moving the stuff that uses the result ofasync.map
into anasync.waterfall
within theasync.eachLimit
.https://what.thedailywtf.com/topic/21071/fork-you-nodebb/
The text was updated successfully, but these errors were encountered: