gpt4 book ai didi

smartfoxserver - 线程一直在增加

转载 作者:行者123 更新时间:2023-12-04 02:27:15 25 4
gpt4 key购买 nike

我刚刚安装了 SmartFoxServer。

Dashboard 线程池中的线程数在重新启动 Sfs 后不断增加,并且在下次重新启动之前不再减少。如果我增加线程池限制,线程数会增加到该限制。

任何扩展或服务尚未运行,线程数在 10 分钟内增加到 1232。所以这看起来不像是内存泄漏,因为不涉及扩展代码,只是普通的 SmartFox。

我试过 2.9 版,但结果没有改变。

什么可能导致 Sfs 线程在不运行扩展的情况下出现这种行为?

最佳答案

你有内存泄漏。

» Memory leaks

In Java a memory leak occurs when objects in memory are not released even though the application itself no longer needs them. A common example is unused event listeners that aren't removed from their event source.

If the program keeps adding new listener objects but never gets rid of those that are no longer used, we will end up with potentially lots of memory waste. The GC won't be able to regain such memory because the unused listeners are still referenced. If these objects keep piling up we will see a progressive performance degradation which may end up in a JVM crash.

Memory leaks are not always very obvious to find, lurking in the code for quite some time before they are spotted. In other instances the leaks can become very nasty very quickly causing major spikes in the memory usage and ultimately the death of the process.
Source: http://docs2x.smartfoxserver.com/AdvancedTopics/troubleshooting-live-server#mem

关于smartfoxserver - 线程一直在增加,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39356775/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com