fix: replace named locks with Galera-compatible row locks
This commit is contained in:
1 parent
ee07866d1c
commit
65d16c2fc6
22 files changed
+314
-365
No files matched your search
+2
-4
@@ -173,10 +173,8 @@ func (s *sqlWebStore) InTx(ctx context.Context, fn func(tx webTx) error) error {
|
||||
}
|
||||
|
||||
func (s *sqlWebStore) InZoneTx(ctx context.Context, zone string, log *slog.Logger, fn func(tx webTx) error) error {
|
||||
return withZoneLock(ctx, s.db, s.tables, zone, log, func(conn *sql.Conn) error {
|
||||
return runInTx(ctx, conn, func(tx *sql.Tx) error {
|
||||
return fn(newSQLWebTx(tx, s.tables))
|
||||
})
|
||||
return runZoneTx(ctx, s.db, s.tables, zone, log, func(tx *sql.Tx) error {
|
||||
return fn(newSQLWebTx(tx, s.tables))
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user