Skip to content

Commit

Permalink
ddl: change some param for cdc (pingcap#56624)
Browse files Browse the repository at this point in the history
  • Loading branch information
D3Hunter authored Oct 14, 2024
1 parent 6af2863 commit 94b2ac0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/ddl/ddl_history.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ func GetHistoryJobByID(sess sessionctx.Context, id int64) (*model.Job, error) {

// GetLastNHistoryDDLJobs returns the DDL history jobs and an error.
// The maximum count of history jobs is num.
func GetLastNHistoryDDLJobs(t *meta.Mutator, maxNumJobs int) ([]*model.Job, error) {
func GetLastNHistoryDDLJobs(t meta.Reader, maxNumJobs int) ([]*model.Job, error) {
iterator, err := GetLastHistoryDDLJobsIterator(t)
if err != nil {
return nil, errors.Trace(err)
Expand All @@ -101,7 +101,7 @@ func GetLastNHistoryDDLJobs(t *meta.Mutator, maxNumJobs int) ([]*model.Job, erro

// IterHistoryDDLJobs iterates history DDL jobs until the `finishFn` return true or error.
func IterHistoryDDLJobs(txn kv.Transaction, finishFn func([]*model.Job) (bool, error)) error {
txnMeta := meta.NewMutator(txn)
txnMeta := meta.NewReader(txn)
iter, err := GetLastHistoryDDLJobsIterator(txnMeta)
if err != nil {
return err
Expand Down

0 comments on commit 94b2ac0

Please sign in to comment.