Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

Conversation

@clokep
Copy link
Member

@clokep clokep commented Nov 7, 2023

Right now when we use simple_update_many_txn (or simple_update_many) it appends the arguments twice meaning each row is found and updated twice.

I noticed this while writing the tests in #16596.

Logic has existed since it was added in #12252.

This is used when:

  • Adding client IPs to the database.
  • Updating unread counts based on processing of receipts.
  • The set_device_id_for_pushers background update.

Copy link
Contributor

@DMRobertson DMRobertson left a comment

Choose a reason for hiding this comment

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

Looking forward to the universal 2x speedup. (/s)

More seriously: nice find.

@clokep clokep marked this pull request as ready for review November 7, 2023 18:39
@clokep clokep requested a review from a team as a code owner November 7, 2023 18:39
@clokep clokep removed the request for review from a team November 7, 2023 18:39
@clokep clokep merged commit 455ef04 into develop Nov 7, 2023
@clokep clokep deleted the clokep/update-once branch November 7, 2023 19:02
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants