projects
/
bucardo.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
070eace
)
Enforce sane isolation levels
author
Greg Sabino Mullane
<greg@endpoint.com>
Fri, 18 Oct 2013 03:41:20 +0000
(23:41 -0400)
committer
Greg Sabino Mullane
<greg@endpoint.com>
Fri, 18 Oct 2013 03:41:20 +0000
(23:41 -0400)
bucardo.schema
patch
|
blob
|
blame
|
history
diff --git
a/bucardo.schema
b/bucardo.schema
index 7ec921f68a3f9c2a274ba905b4175f73147b0338..ee8dfc3147ee3b30b5d496326ade69880c7aed1a 100644
(file)
--- a/
bucardo.schema
+++ b/
bucardo.schema
@@
-63,6
+63,9
@@
CREATE UNIQUE INDEX bucardo_config_unique_name ON bucardo.bucardo_config(name,it
ALTER TABLE bucardo.bucardo_config ADD CONSTRAINT valid_config_type CHECK (type IN ('sync','goat'));
+ALTER TABLE bucardo.bucardo_config ADD CONSTRAINT valid_config_isolation_level
+ CHECK (name <> 'isolation_level' OR setting IN ('serializable','repeatable read'));
+
CREATE FUNCTION bucardo.check_bucardo_config()
RETURNS TRIGGER
LANGUAGE plpgsql