Skip to content

meta/sql: batch chunk_ref updates to reduce SQL round-trips#7018

Open
Xuyuchao-juice wants to merge 3 commits into
mainfrom
batch_update
Open

meta/sql: batch chunk_ref updates to reduce SQL round-trips#7018
Xuyuchao-juice wants to merge 3 commits into
mainfrom
batch_update

Conversation

@Xuyuchao-juice
Copy link
Copy Markdown
Contributor

No description provided.

@Xuyuchao-juice Xuyuchao-juice marked this pull request as ready for review May 13, 2026 03:01
Comment thread pkg/meta/sql.go Outdated
if _, err := ses.Exec(m.sqlConv("update chunk_ref set refs=refs+1 where chunkid = ? AND size = ?"), id, size); err != nil {
return err
}
chunkRefDeltas[id]++
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

size维度丢失了, 其他地方也是. 后台任务做下处理就可以, 其他地方先不修改

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants