Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NullStr ¶
func NullStr(s string) sql.NullString
NullStr returns a valid sql.NullString if s is non-empty, otherwise null.
func RollbackTx ¶
Types ¶
type Handle ¶
func OpenNoMigrate ¶
OpenNoMigrate opens the database without running migrations. Use this on hot paths (e.g., broker observation emission) where the database is expected to already exist and be at the current schema version. Returns an error if the database file does not exist.
type OpenOptions ¶
type OpenOptions struct {
BusyTimeout time.Duration
Synchronous string
TxImmediate bool // if true, all BEGIN statements use IMMEDIATE locking
}
func DefaultOpenOptions ¶
func DefaultOpenOptions() OpenOptions
DefaultOpenOptions returns the standard options used by most callers: BusyTimeout 250ms, Synchronous "NORMAL".
Click to show internal directories.
Click to hide internal directories.