Skip to content

Commit 5cbbca2

Browse files
committed
Don't use CSV table engine for status table
1 parent d40ceb8 commit 5cbbca2

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

pkg/sidecar/appconf.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,12 +180,14 @@ func initFileQuery(cfg *Config, gtidPurged string) []byte {
180180
[]string{"REPLICATION CLIENT"}, "*.*")...)
181181

182182
// create the status table used by the operator to configure or to mask MySQL node ready
183+
// CSV engine for this table can't be used because we use REPLACE statement that requires PRIMARY KEY or
184+
// UNIQUE KEY index
183185
// nolint: gosec
184186
queries = append(queries, fmt.Sprintf(`
185187
CREATE TABLE IF NOT EXISTS %[1]s.%[2]s (
186188
name varchar(64) PRIMARY KEY,
187189
value varchar(512) NOT NULL
188-
) ENGINE=CSV `, constants.OperatorDbName, constants.OperatorStatusTableName))
190+
)`, constants.OperatorDbName, constants.OperatorStatusTableName))
189191

190192
// mark node as not configured at startup, the operator will mark it configured
191193
// nolint: gosec

0 commit comments

Comments
 (0)