Skip to content

Commit

Permalink
force query
Browse files Browse the repository at this point in the history
  • Loading branch information
serprex committed Jan 10, 2025
1 parent a57eb9b commit e9f68cd
Showing 1 changed file with 12 additions and 9 deletions.
21 changes: 12 additions & 9 deletions flow/connectors/mysql/qrep.go
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ func (c *MySqlConnector) PullQRepRecords(
if err != nil {
return 0, err
}
query = fmt.Sprintf("select * from %s", config.WatermarkTable)

Check failure on line 153 in flow/connectors/mysql/qrep.go

View workflow job for this annotation

GitHub Actions / lint

fmt.Sprintf can be replaced with string concatenation (perfsprint)

totalRecords := 0
onResult := func(rs *mysql.Result) error {
Expand Down Expand Up @@ -178,16 +179,18 @@ func (c *MySqlConnector) PullQRepRecords(
return nil
}

// testing
rs, err := c.Execute(ctx, "show databases")
if err != nil {
return 0, fmt.Errorf("mymymy err %w", err)
}
for rowIdx, row := range rs.Values {
for idx, val := range row {
c.logger.Info("mymymy show", slog.Int("rowIdx", rowIdx), slog.Int("idx", idx), slog.Any("field", string(val.AsString())))
/*

Check failure on line 182 in flow/connectors/mysql/qrep.go

View workflow job for this annotation

GitHub Actions / lint

commentedOutCode: may want to remove commented-out code (gocritic)
// testing
rs, err := c.Execute(ctx, "show databases")
if err != nil {
return 0, fmt.Errorf("mymymy err %w", err)
}
}
for rowIdx, row := range rs.Values {
for idx, val := range row {
c.logger.Info("mymymy show", slog.Int("rowIdx", rowIdx), slog.Int("idx", idx), slog.Any("field", string(val.AsString())))
}
}
*/

if last.FullTablePartition {
// this is a full table partition, so just run the query
Expand Down

0 comments on commit e9f68cd

Please sign in to comment.