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

Refactor and optimise filter_events_for_server #3541

Merged
merged 6 commits into from
Jul 17, 2018

Conversation

richvdh
Copy link
Member

@richvdh richvdh commented Jul 16, 2018

Firstly this factors filter_events_for_server out of FederationHandler and adds a unit test for it. Then we refactor it to make it do a bit less string comparison, and add another test which does some profiling.

@richvdh richvdh requested a review from a team July 16, 2018 13:15
return False
return state_key[idx + 1:] == server_name
Copy link
Member

Choose a reason for hiding this comment

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

Might be worth a quick comment as to why we don't use get_domain_from_id, I was a bit confused.

@richvdh richvdh merged commit 9c04b4a into develop Jul 17, 2018
@richvdh richvdh changed the title Refactor and optimze filter_events_for_server Refactor and optimise filter_events_for_server Jul 17, 2018
@richvdh richvdh deleted the rav/optimize_filter_events_for_server branch July 18, 2018 13:28
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.

2 participants