-
Notifications
You must be signed in to change notification settings - Fork 193
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
Fix triggering user query calls whenever a new user was added in UserListController
#3184
Fix triggering user query calls whenever a new user was added in UserListController
#3184
Conversation
…every new user when using a `UserListController`
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM ✅
CHANGELOG.md
Outdated
@@ -4,6 +4,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). | |||
# Upcoming | |||
|
|||
## StreamChat | |||
### 🐞 Fixed | |||
- Fix triggering user query calls whenever a new user was added in `UserListController` #[3184](https://github.com/GetStream/stream-chat-swift/pull/3184) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thinking if we should mention that the UserListController
is no longer reactive, wdyt?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I was thinking about that too, but I was afraid it might warn customers for no important reason, since most of them won't care about this, but maybe better to be transparent, so I'll add this 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done ✅
StreamChat XCMetrics
|
Quality Gate passedIssues Measures |
🔗 Issue Links
Relates to https://github.com/GetStream/ios-issues-tracking/issues/800
🎯 Goal
Fixes adding new users causing additional HTTP calls just to check if the new user is part of the query.
📝 Summary
The responsible for this was
NewUserQueryUpdater
. This is a really old worker that we had, and it seems like we had one of these for channel lists as well, and then we had to remove it because of problems. This approach is for sure a no go, creating an HTTP call for every new user just to check if it stills matches the query is not recommended by the backend team, and it can be a pretty fragile solution. Observing this in theUserListController
also seems to be an overkill. Only for theMemberListController
this is useful. So for the time being, we will just remove this. If customers wantUserListController
to be reactive, we will need to implement the automatic query filter and/or the filter block approach that we have for channel lists.References:
🧪 Manual Testing Notes
N/A
☑️ Contributor Checklist