#include <functional>
#include <string>
#include "error.hh"
Go to the source code of this file.
|
| nix::MakeError (SQLiteBusy, SQLiteError) |
|
void | nix::handleSQLiteBusy (const SQLiteBusy &e, time_t &nextWarning) |
|
template<typename T, typename F> |
T | nix::retrySQLite (F &&fun) |
|
◆ SQLiteOpenMode
Enumerator |
---|
Normal | Open the database in read-write mode. If the database does not exist, it will be created.
|
NoCreate | Open the database in read-write mode. Fails with an error if the database does not exist.
|
Immutable | Open the database in immutable mode. In addition to the database being read-only, no wal or journal files will be created by sqlite. Use this mode if the database is on a read-only filesystem. Fails with an error if the database does not exist.
|
◆ retrySQLite()
template<typename T, typename F>
T nix::retrySQLite |
( |
F && | fun | ) |
|
Convenience function for retrying a SQLite transaction when the database is busy.