[PR #4272] [CLOSED] Add support for different journal modes #17311

Closed
opened 2025-11-02 12:32:18 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/go-gitea/gitea/pull/4272
Author: @jonasfranz
Created: 6/18/2018
Status: Closed

Base: masterHead: journal_mode


📝 Commits (3)

  • f06e9c6 Add support for different journal modes
  • c5e50c4 Move journal mode to connection string
  • c58e2c5 Replace WLA with WAL

📊 Changes

21 files changed (+23169 additions, -11071 deletions)

View changed files

📝 Gopkg.lock (+2 -1)
📝 custom/conf/app.ini.sample (+2 -0)
📝 docs/content/doc/advanced/config-cheat-sheet.en-us.md (+3 -0)
📝 models/models.go (+4 -4)
📝 modules/indexer/issue.go (+1 -1)
📝 vendor/github.com/mattn/go-sqlite3/callback.go (+34 -0)
📝 vendor/github.com/mattn/go-sqlite3/sqlite3-binding.c (+20685 -9869)
📝 vendor/github.com/mattn/go-sqlite3/sqlite3-binding.h (+1330 -270)
📝 vendor/github.com/mattn/go-sqlite3/sqlite3.go (+1021 -71)
vendor/github.com/mattn/go-sqlite3/sqlite3_fts5.go (+0 -13)
📝 vendor/github.com/mattn/go-sqlite3/sqlite3_go18.go (+1 -0)
vendor/github.com/mattn/go-sqlite3/sqlite3_icu.go (+0 -13)
vendor/github.com/mattn/go-sqlite3/sqlite3_json1.go (+0 -12)
📝 vendor/github.com/mattn/go-sqlite3/sqlite3_libsqlite3.go (+3 -0)
📝 vendor/github.com/mattn/go-sqlite3/sqlite3_load_extension.go (+1 -0)
vendor/github.com/mattn/go-sqlite3/sqlite3_omit_load_extension.go (+0 -23)
📝 vendor/github.com/mattn/go-sqlite3/sqlite3_other.go (+1 -0)
📝 vendor/github.com/mattn/go-sqlite3/sqlite3_trace.go (+14 -140)
vendor/github.com/mattn/go-sqlite3/sqlite3_vtable.go (+0 -646)
📝 vendor/github.com/mattn/go-sqlite3/sqlite3_windows.go (+6 -2)

...and 1 more files

📄 Description

Fixes #2040 (partially)

Add the ability to set the journal mode used by SQLite3. The new default journal mode is WAL, since it produces more less database locked errors (nearly no errors).

Learn more about WAL: https://www.sqlite.org/wal.html

https://github.com/mattn/go-sqlite3/issues/569#issuecomment-393202136

Maybe should we also add SetMaxOpenConnection(1). But I'm not sure about that.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/go-gitea/gitea/pull/4272 **Author:** [@jonasfranz](https://github.com/jonasfranz) **Created:** 6/18/2018 **Status:** ❌ Closed **Base:** `master` ← **Head:** `journal_mode` --- ### 📝 Commits (3) - [`f06e9c6`](https://github.com/go-gitea/gitea/commit/f06e9c66b28fb61a8ee13c1899a381b8e98d9d61) Add support for different journal modes - [`c5e50c4`](https://github.com/go-gitea/gitea/commit/c5e50c48da2d4a4f0409cc510861e449510f5c23) Move journal mode to connection string - [`c58e2c5`](https://github.com/go-gitea/gitea/commit/c58e2c5ce48b357dcf159c7759d61ab14c42e60d) Replace WLA with WAL ### 📊 Changes **21 files changed** (+23169 additions, -11071 deletions) <details> <summary>View changed files</summary> 📝 `Gopkg.lock` (+2 -1) 📝 `custom/conf/app.ini.sample` (+2 -0) 📝 `docs/content/doc/advanced/config-cheat-sheet.en-us.md` (+3 -0) 📝 `models/models.go` (+4 -4) 📝 `modules/indexer/issue.go` (+1 -1) 📝 `vendor/github.com/mattn/go-sqlite3/callback.go` (+34 -0) 📝 `vendor/github.com/mattn/go-sqlite3/sqlite3-binding.c` (+20685 -9869) 📝 `vendor/github.com/mattn/go-sqlite3/sqlite3-binding.h` (+1330 -270) 📝 `vendor/github.com/mattn/go-sqlite3/sqlite3.go` (+1021 -71) ➖ `vendor/github.com/mattn/go-sqlite3/sqlite3_fts5.go` (+0 -13) 📝 `vendor/github.com/mattn/go-sqlite3/sqlite3_go18.go` (+1 -0) ➖ `vendor/github.com/mattn/go-sqlite3/sqlite3_icu.go` (+0 -13) ➖ `vendor/github.com/mattn/go-sqlite3/sqlite3_json1.go` (+0 -12) 📝 `vendor/github.com/mattn/go-sqlite3/sqlite3_libsqlite3.go` (+3 -0) 📝 `vendor/github.com/mattn/go-sqlite3/sqlite3_load_extension.go` (+1 -0) ➖ `vendor/github.com/mattn/go-sqlite3/sqlite3_omit_load_extension.go` (+0 -23) 📝 `vendor/github.com/mattn/go-sqlite3/sqlite3_other.go` (+1 -0) 📝 `vendor/github.com/mattn/go-sqlite3/sqlite3_trace.go` (+14 -140) ➖ `vendor/github.com/mattn/go-sqlite3/sqlite3_vtable.go` (+0 -646) 📝 `vendor/github.com/mattn/go-sqlite3/sqlite3_windows.go` (+6 -2) _...and 1 more files_ </details> ### 📄 Description Fixes #2040 (partially) Add the ability to set the journal mode used by SQLite3. The new default journal mode is WAL, since it produces more less database locked errors (nearly no errors). Learn more about WAL: https://www.sqlite.org/wal.html https://github.com/mattn/go-sqlite3/issues/569#issuecomment-393202136 Maybe should we also add `SetMaxOpenConnection(1)`. But I'm not sure about that. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2025-11-02 12:32:18 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#17311