nodejs / nodejs/node

Web Storage Maybe leaks SQLite connections when database initialization fails

未关闭
#64,640 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

sqlite
主要语言
JavaScript
星标
122k
派生
37.3k
平均合并
4 天 2 小时
30 天内合并 PR
283

描述

Version

latest main branch

Platform

Subsystem

No response

What steps will reproduce the bug?

use broken db or many of condition

How often does it reproduce? Is there a required condition?

Every failed init

What is the expected behavior? Why is that the expected behavior?

A connection created by sqlite3_open() should be closed whenever database initialization fails. Repeated failed Web Storage operations should not increase the number of open file descriptors.

What do you see instead?

The number of open descriptors increases with every failed initialization attempt.

Additional information

No response

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

首先重现一次失败的 Web Storage 数据库初始化,并跟踪失败路径中的 sqlite3_open() 连接生命周期。完成标准是每次失败的初始化都会关闭其连接,并且重复执行失败的 Web Storage 操作不再增加打开的文件描述符数量。

由索引模型根据 Issue 内容生成。

评估

技术栈
sqlite
领域
databases
Issue 类型
缺陷
难度
3/5
预计耗时
1-2 天
活跃度
活跃
描述清晰度
基本清楚
新手友好度
48/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。