Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4: Seperate read and write instances for sqlite #19

Merged
merged 2 commits into from
Mar 25, 2024

Conversation

willemschots
Copy link
Owner

@willemschots willemschots commented Mar 25, 2024

This PR improves the configuration we use for SQLite. Due to the way the SQLite, Go database/sql package and mattn/go-sqlite3 work we should adjust our settings a little bit for better performance.

This PR adds the db.OpenSQLite function. It enables us to create two different kinds of *sql.DB instances:

  • One for reading.
  • One for writing.

See this this comment for information on the why.

@willemschots willemschots self-assigned this Mar 25, 2024
@willemschots willemschots changed the title 4: Seperate read and write connection pools for sqlite 4: Seperate read and write instances for sqlite Mar 25, 2024
@willemschots willemschots merged commit ad49c0c into main Mar 25, 2024
2 checks passed
@willemschots willemschots deleted the 4-sqlite-settings branch March 25, 2024 10:58
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.

1 participant