Skip to content

Embedded replica syncs a lot during UPDATE/INSERT/COMMIT #2079

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
Resonious opened this issue May 25, 2025 · 5 comments
Open

Embedded replica syncs a lot during UPDATE/INSERT/COMMIT #2079

Resonious opened this issue May 25, 2025 · 5 comments

Comments

@Resonious
Copy link

Resonious commented May 25, 2025

I have one server that's a little far from the database. Thus, I'd like to use embedded replica mode to speed things up a bit. Problem is, it actually slows things down most of the time. (Rust client)

Reads are very fast as expected (love it), but writes and transactions result in tons of frames being pulled in:

Image

Pretty much every mutation to the database looks like 👆, despite calling sync every 5 seconds, and no other traffic.

Additionally, I'm racking up sync bandwidth like crazy

Image

Image

The amount of syncs I've done looks like I could've downloaded every DB in my account 20 times... Is this expected? Let me know if there's anything I can do to further troubleshoot.

@Resonious Resonious changed the title Embedded replica syncs a lot during transaction Embedded replica syncs a lot during UPDATE/INSERT/COMMIT May 25, 2025
@glommer
Copy link
Contributor

glommer commented May 26, 2025

It will be helpful to understand the server stack you are syncing against to make sure everything is up2date.

It seems from your screenshot that you are syncing against the Turso Cloud. In that case it would be helpful to know the URL, and then we can check

@glommer
Copy link
Contributor

glommer commented May 26, 2025

Also would be interesting to understand your workload. Do you have enough writes to rewrite the database 20x over? Do you still see issues with high sync bandwidth if you stop writing for a period of time ?

@avinassh
Copy link
Member

@Resonious Are you on our discord server? (makes it easier to share private / sensitive information). if so, I'd like to debug this with your db and understand your workload.

@Resonious
Copy link
Author

Yes, Turso Cloud. I'll share some info on Discord.

Workload is mostly reads actually, which is why I'm a bit surprised / suspect something is wrong.

@Resonious
Copy link
Author

Actually I'll just share the DB URL here for now: libsql://main-staging-2-resonious.aws-us-east-1.turso.io

I am in the server under the name Resonious in case you want to send me a message!

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

No branches or pull requests

3 participants