-
Notifications
You must be signed in to change notification settings - Fork 3
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
Add no-downtime migrations support for composite types #21
Conversation
77059bc
to
b81ddb5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM modulo minor comments.
tableHasLess :: Show t => Text -> t -> Text | ||
tableHasLess ptype missing = | ||
"Table in the database has *less*" <+> ptype <+> | ||
objectHasLess :: Show t => Text -> Text -> t -> Text |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor: ptype
seems to always be "columns", maybe these two should be objectHas{Less,More}Columns
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's leave it as-is, I don't think it's a big deal.
@@ -15,7 +15,7 @@ import Prelude | |||
data Check = Check { | |||
chkName :: RawSQL () | |||
, chkCondition :: RawSQL () | |||
, chkValidated :: Bool -- ^ Set to 'True' if check is created as NOT VALID and | |||
, chkValidated :: Bool -- ^ Set to 'False' if check is created as NOT VALID and | |||
-- not validated afterwards. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/not validated/validated/? We're supposed to call sqlValidateCheck
at some future point after all.
Maybe rephrase as: "When set to 'False', the check is initially created as NOT VALID. It should be eventually validated with 'sqlValidateCheck'.".
Similarly for fkValidated
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fkValidated
should be set to False
if check is created as NOT VALID and left like this (for whatever reason), so the current description is imo alright.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fkValidated should be set to False if check is created as NOT VALID and left like this (for whatever reason)
OK, maybe change both comments to say this instead of current wording? I find it less confusing than the current one (with the double negative).
I pushed additional commit with support for concurrent index creation, please take a look at it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Latest changes look OK, but there's a compile failure on GHC <= 8.2 which seems easy enough to fix (missing import).
@23Skidoo Things seem to be good now. Would you mind merging and creating a release? |
Merged, will cut a release shortly. |
New release is now on Hackage. |
No description provided.