Skip to content

Commit

Permalink
fix and update ddl test with plan type
Browse files Browse the repository at this point in the history
Signed-off-by: Harshit Gangal <harshit@planetscale.com>
  • Loading branch information
harshit-gangal committed Feb 10, 2025
1 parent d2062ea commit cfc2806
Show file tree
Hide file tree
Showing 5 changed files with 1,618 additions and 0 deletions.
3 changes: 3 additions & 0 deletions go/vt/vtgate/engine/ddl.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,9 @@ func (ddl *DDL) GetTableName() string {
func (ddl *DDL) isOnlineSchemaDDL() bool {
switch ddl.DDL.GetAction() {
case sqlparser.CreateDDLAction, sqlparser.DropDDLAction, sqlparser.AlterDDLAction:
if ddl.OnlineDDL == nil || ddl.OnlineDDL.DDLStrategySetting == nil {
return false
}
return !ddl.OnlineDDL.DDLStrategySetting.Strategy.IsDirect()
}
return false
Expand Down
Loading

0 comments on commit cfc2806

Please sign in to comment.