-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Add optional comments reference_id #19890
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
Conversation
6bade5f to
0bf13a3
Compare
| protected function hasMissingColumns(): array { | ||
| $indexInfo = new MissingColumnInformation(); | ||
| // Dispatch event so apps can also hint for pending index updates if needed | ||
| $event = new GenericEvent($indexInfo); |
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.
For now i copied the indexes code, but we could also go for a new event class here making things proper. i dont care too much
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.
Depends. If we consider this public then I would go for the new things straight away
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.
Okay, fine by me
rullzer
left a comment
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.
Fine by me
Signed-off-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Joas Schilling <coding@schilljs.com>
15dae1b to
60d9384
Compare
|
Squash time |
|
Signed-off-by: Joas Schilling <coding@schilljs.com>
|
Updated the one new test as well |
|
There's more: i didn't check all steps. |
Signed-off-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Joas Schilling <coding@schilljs.com>
Ref nextcloud/server#19845 Ref nextcloud/server#19890 Ref nextcloud/server#19075 Ref nextcloud/server#19670 Ref nextcloud/server#19412 Ref nextcloud/server#14722 Ref nextcloud/server#19746 Ref nextcloud/server#19321 Ref nextcloud/server#19569 Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
So for talks use of the comments api, we would be interested in an additional field for comments to be added. We would store there a random hash, so when the server messages are returned while you e.g. post a message we can see if the message is the one you are currently sending and already hide the temporary message.
You can currently see this sometimes when a lot of notifications are sent, that the message is shown twice for some milliseconds, because currently the temporary message is killed by the response of the post (which happens after the notifications are sent to the proxy) but in parallel the message appears already from the "waiting for new messages" request immediately after its written to the database.
So this PR adds the optional column, and only writes/updates it when the column was added already. This laziness is okay, as the impact is sloppier behaviour instead of broken behaviour in case the column was not added.