【问题标题】:System freezes when parent and child connectivity父子连接时系统冻结
【发布时间】:2018-09-28 08:09:10
【问题描述】:

我已经将 Pouchdb 与 Electron 一起使用,通过本地 LAN 连接两个系统并使用作为父级的单个数据库,另一个子系统将使用相同的 pouchdb 数据库。

使用express-pouch使子系统连接父pouchdb。

将在父系统中从 couchDB 到 pouchDB 运行后台同步。

连接按预期工作,问题将是在连接系统在父母和孩子中冻结一段时间后。 检查任务管理器磁盘 100%,内存 100%。

两个系统 - windows 10 pro - Ram - 4GB

【问题讨论】:

  • 你有任何nodejs错误吗?
  • 有时我会收到possible EventEmitter memory leak detected. 11 listeners added. Use emitter.setMaxListeners() to increase limit.

标签: windows-10 couchdb electron pouchdb


【解决方案1】:

尝试使用--max_old_space_size=<size> 选项增加为您的脚本分配的内存。

尝试使用emitter.getMaxListeners()emitter.listenerCount(eventName) 方法监控您拥有的发射器数量,并使用emitter.setMaxListener(n) 增加数量

【讨论】:

  • 还有其他解决方案吗?
猜你喜欢
  • 2015-06-03
  • 2019-07-14
  • 1970-01-01
  • 1970-01-01
  • 2022-08-05
  • 1970-01-01
  • 2015-09-09
  • 2020-06-10
  • 1970-01-01
相关资源
最近更新 更多