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

Improve ServerNoticeServlet to avoid duplicate requests each creating a server-notices-room #9544

Closed
dklimpel opened this issue Mar 4, 2021 · 2 comments · Fixed by #10679
Labels
good first issue Good for newcomers S-Minor Blocks non-critical functionality, workarounds exist. T-Defect Bugs, crashes, hangs, security vulnerabilities, or other reported issues.

Comments

@dklimpel
Copy link
Contributor

dklimpel commented Mar 4, 2021

Improve ServerNoticeServlet

class SendServerNoticeServlet(RestServlet):

We chatted a bit about this in #synapse-dev:matrix.org and realize that this is highlighting a bug in the servlet!

  • The txn_id should be passed into send_notice method and then passed through into create_and_send_nonmember_event (see RoomSendEventRestServlet for the proper way to do this).

It was also pointed out that some more magic might be needed to avoid creating duplicate server-notice rooms too, but maybe we can leave that to a follow-up and just add a note about it.

Originally posted by @clokep in #9520 (comment)

Also unit tests are missing.

@anoadragon453 anoadragon453 added S-Minor Blocks non-critical functionality, workarounds exist. T-Defect Bugs, crashes, hangs, security vulnerabilities, or other reported issues. labels Mar 4, 2021
@clokep clokep added the good first issue Good for newcomers label Mar 8, 2021
@Half-Shot
Copy link
Collaborator

Related #9469 ?

@dklimpel
Copy link
Contributor Author

dklimpel commented Jun 22, 2021

Related
#5501
#5791

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
good first issue Good for newcomers S-Minor Blocks non-critical functionality, workarounds exist. T-Defect Bugs, crashes, hangs, security vulnerabilities, or other reported issues.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants
@clokep @anoadragon453 @Half-Shot @dklimpel and others