element-hq / synapse

Synapse: Matrix homeserver written in Python/Twisted.
https://element-hq.github.io/synapse
GNU Affero General Public License v3.0
1.26k stars 156 forks source link

/_matrix/client/v3/sync never finishes #16845

Closed verymilan closed 3 months ago

verymilan commented 7 months ago

Description

Hi there, as of around january 9th, I have a botuser (mautrix-whatsapp) where the sync request seemingly never finishes. As of right now, it is taking about 8,5 hours and it's still going. Not even a goaway. If I reuse that since token with my auth token, it takes about 5s.

My workers don't seem to be under high load, but Redis curiously happily jumps to 500% cpu – which is not affected by that sync request as far as i can tell.

Steps to reproduce

unknown. since=s394247408_1207796618_5984102_309180540_44583100_66668_16267554_206909845_0_14158

Homeserver

https://matrix.tchncs.de

Synapse Version

1.99.0

Installation Method

pip (from PyPI)

Database

PostgreSQL

Workers

Multiple workers

Platform

Debian 12

Configuration

No response

Relevant log output

possibly


synapse.http.client - 928 - INFO - GET-545154 - Received response to POST synapse-replication://master/_synapse/replication/presence_set_state/%40whatsappbot%3Atchncs.de: 200
synapse.util.caches.response_cache - 274 - INFO - GET-545154 - [sync]: using incomplete cached result for [(@whatsappbot:tchncs.de, 30000, 's394247408_1207796618_5984102_309180540_44583100_66668_16267554_206909845_0_14158', '0', False, 'RDMCFJKLSJ', None)]

the testrequest from above is now on WARNING again, maybe should have left it INFO or something.

Anything else that would be useful to know?

No response

FlyveHest commented 7 months ago

Could this be somewhat related to #16843 ?

Its not entirely the same request, but my error is related to sync in some way. Its not BOT users, though, but regular ones.

TheArcaneBrony commented 7 months ago

Possibly related to #16873 ? Can you check if your logs contain anything related to FrozenEventV3?

reivilibre commented 3 months ago

Hi, first of all I'm sorry that we didn't get around to answering you timely!

However I will close this issue, because as two kind community members already linked, we had similar bugs earlier in the year and we believe those to be addressed. If the problem still happens on a later version please do reopen.

Thanks.