Skip to content

sqlite: enable common flags - #57621

Merged
nodejs-github-bot merged 2 commits into
nodejs:mainfrom
geeksilva97:enable-common-sqlite-flags
Apr 4, 2025
Merged

sqlite: enable common flags#57621
nodejs-github-bot merged 2 commits into
nodejs:mainfrom
geeksilva97:enable-common-sqlite-flags

Conversation

@geeksilva97

@geeksilva97 geeksilva97 commented Mar 25, 2025

Copy link
Copy Markdown
Contributor

This PR enables flags that are common to other sqlite players in Node.js ecosystem:

This is related to #56476, even though it does not enable the RBU extension.

I see this as a good step toward the stabilization since it will make it easier for people from other dependencies.

@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Review requested:

  • @nodejs/gyp
  • @nodejs/security-wg
  • @nodejs/sqlite

@nodejs-github-bot nodejs-github-bot added dependencies PRs that add, update, or configure Node.js dependencies. needs-ci PRs that need a full CI run. sqlite Issues and PRs related to the SQLite subsystem. labels Mar 25, 2025
@geeksilva97

Copy link
Copy Markdown
Contributor Author

Not sure whether this will be a problem, but this increases the binary size by 600KB.

@geeksilva97
geeksilva97 force-pushed the enable-common-sqlite-flags branch from e4b93b9 to 9590dee Compare March 25, 2025 17:53

@cjihrig cjihrig left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not saying whether or not we should land this, but https://github.com/nodejs/node/blob/main/deps/sqlite/unofficial.gni should be updated, and there should be at least one test for each new API to prevent regressions.

@geeksilva97

Copy link
Copy Markdown
Contributor Author

Not saying whether or not we should land this, but https://github.com/nodejs/node/blob/main/deps/sqlite/unofficial.gni should be updated, and there should be at least one test for each new API to prevent regressions.

Good point. Also, I think it would be good to have some benchmarks on sqlite implementations.

@geeksilva97
geeksilva97 force-pushed the enable-common-sqlite-flags branch from 9590dee to 0c1ec86 Compare March 25, 2025 19:22
@geeksilva97

Copy link
Copy Markdown
Contributor Author

Not saying whether or not we should land this, but https://github.com/nodejs/node/blob/main/deps/sqlite/unofficial.gni should be updated, and there should be at least one test for each new API to prevent regressions.

@cjihrig , what's the difference between .gyp and .gni file?

Comment thread test/parallel/test-sqlite.js Outdated
@geeksilva97
geeksilva97 force-pushed the enable-common-sqlite-flags branch from 0c1ec86 to 31c5aa5 Compare March 25, 2025 19:28
@cjihrig

cjihrig commented Mar 25, 2025

Copy link
Copy Markdown
Contributor

what's the difference between .gyp and .gni file?

They are for two different build systems. The .gyp file is used by the official build. The .gni file is used by the unofficial GN build.

@geeksilva97

Copy link
Copy Markdown
Contributor Author

what's the difference between .gyp and .gni file?

They are for two different build systems. The .gyp file is used by the official build. The .gni file is used by the unofficial GN build.

Thank you!

@cjihrig

cjihrig commented Mar 25, 2025

Copy link
Copy Markdown
Contributor

even though it does not enable the RBU extension.

Why not? And why not the Geopoly extension?

@geeksilva97

geeksilva97 commented Mar 25, 2025

Copy link
Copy Markdown
Contributor Author

even though it does not enable the RBU extension.

Why not? And why not the Geopoly extension?

For RBU, I didn't see it in better-sqlite3 or node-sqlite3. Geopoly seems like a good extension to have.