Skip to content

Conversation

@iamd3vil
Copy link
Owner

@iamd3vil iamd3vil commented Nov 3, 2025

  • Add [sqlite] configuration section with cache_size_mb, busy_timeout_ms, synchronous mode, and mmap_size options
  • Implement automatic per-shard calculation for cache and mmap settings with floor division
  • Update default synchronous mode to NORMAL for better safety in WAL mode
  • Increase migration cache to 1GB for better performance during shard migrations
  • Add comprehensive documentation in config.example.toml with tuning recommendations
  • Print SQLite configuration on server startup for visibility
  • Enable foreign_keys pragma for data integrity

- Add `[sqlite]` configuration section with cache_size_mb, busy_timeout_ms, synchronous mode, and mmap_size options
- Implement automatic per-shard calculation for cache and mmap settings with floor division
- Update default synchronous mode to NORMAL for better safety in WAL mode
- Increase migration cache to 1GB for better performance during shard migrations
- Add comprehensive documentation in config.example.toml with tuning recommendations
- Print SQLite configuration on server startup for visibility
- Enable foreign_keys pragma for data integrity
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

- Add max_connections config option for SQLite connection pool size (default: 10)
- Update cache and mmap calculation to divide by (shards * connections) instead of just shards
- Add helper methods for per-connection cache and mmap sizes
- Update startup output to show per-connection resource allocation
- Improve integer overflow safety with saturating arithmetic and clamping
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants