matrix-org / dendrite

Dendrite is a second-generation Matrix homeserver written in Go!
https://matrix-org.github.io/dendrite/
Apache License 2.0
5.54k stars 660 forks source link

Dendrite sends presence multiple times per second #3235

Open Fale opened 9 months ago

Fale commented 9 months ago

Background information

Description

time="2023-10-15T13:24:07.151689353Z" level=info msg="Sending EDU event" destinations=429 edu_type=m.presence
time="2023-10-15T13:24:07.614874549Z" level=info msg="Sending EDU event" destinations=429 edu_type=m.presence
time="2023-10-15T13:24:08.076643337Z" level=info msg="Sending EDU event" destinations=429 edu_type=m.presence
time="2023-10-15T13:24:08.671475521Z" level=info msg="Sending EDU event" destinations=429 edu_type=m.presence
Oct 15 16:24:08 omega systemd-chat-synapse[4122]: 2023-10-15 14:24:08,959 - synapse.access.http.8008 - 465 - INFO - PUT-129397 - 10.89.4.4 - 8008 - {fale.io} Processed request: 0.020sec/0.002sec (0.005sec, 0.001sec) (0.003sec/0.009sec/5) 11B 200 "PUT /_matrix/federation/v1/send/1697379832052-35685 HTTP/1.1" "Dendrite/0.13.2+57ddbe0.57ddbe0" [0 dbevts]
Oct 15 16:24:08 omega systemd-chat-synapse[4122]: 2023-10-15 14:24:08,511 - synapse.access.http.8008 - 465 - INFO - PUT-129396 - 10.89.4.4 - 8008 - {fale.io} Processed request: 0.008sec/0.001sec (0.004sec, 0.000sec) (0.001sec/0.003sec/2) 11B 200 "PUT /_matrix/federation/v1/send/1697379831617-35684 HTTP/1.1" "Dendrite/0.13.2+57ddbe0.57ddbe0" [0 dbevts]
Oct 15 16:24:08 omega systemd-chat-synapse[4122]: 2023-10-15 14:24:08,086 - synapse.access.http.8008 - 465 - INFO - PUT-129395 - 10.89.4.4 - 8008 - {fale.io} Processed request: 0.010sec/0.001sec (0.003sec, 0.001sec) (0.001sec/0.003sec/2) 11B 200 "PUT /_matrix/federation/v1/send/1697379831190-35683 HTTP/1.1" "Dendrite/0.13.2+57ddbe0.57ddbe0" [0 dbevts]
Oct 15 16:24:07 omega systemd-chat-synapse[4122]: 2023-10-15 14:24:07,595 - synapse.access.http.8008 - 465 - INFO - PUT-129394 - 10.89.4.4 - 8008 - {fale.io} Processed request: 0.006sec/0.000sec (0.001sec, 0.000sec) (0.001sec/0.002sec/2) 11B 200 "PUT /_matrix/federation/v1/send/1697379830703-35682 HTTP/1.1" "Dendrite/0.13.2+57ddbe0.57ddbe0" [0 dbevts]

Steps to reproduce

Workaround

To avoid to flood everyone while this issue is being looked at, I've changed the dendrite config as:

  presence:
    enable_inbound: true
    enable_outbound: false

so now those messages are not sent anymore

jjj333-p commented 7 months ago

hijacking this issue since its highly related;

i went into #element-web:matrix.org because i was having this issue whenever i opened element, and if i let element go into the background while using cinny my presence would freak out and rapidly alternate.

it appears that this is the same issue synapse had, #16057, just i guess less catastrophic due to smaller instance sizes

image