Use awardEmojiToggle mutation instead of workItemUpdate
What does this MR do and why?
We were using the workItemUpdate mutation for awarding emojis but it has few limitations.
- On rapid clicking of award emoji button, the
workItemUpdatemutation is throwing errors. - The
workItemUpdateallows for adding emojis only if user isReporter+, whereasawardEmojiTogglecan work withGuestas well as non-member users.
Apart from that, awardEmojiToggle is also quite performant. The comparison is below:
| workItemUpdate | awardEmojiToggle |
|---|---|
![]() |
![]() |
Utilising the awardEmojiToggle mutation would be more pertinent in comparison to the workItemUpdate.
Screenshots or screen recordings
No errors on rapid press of the button
How to set up and validate locally
Prerequisites: Enable the following feature flag to create objects supporting this feature using gdk rails console:
Feature.enable(:okrs_mvc, Project.find_by_full_path('gitlab-org/gitlab-test'))
Steps:
- Login with a particular user
- Go to any Project > Issues > List
- Create an new Objective under New issue split button
- Go to Objective detail page
-
Click on the
👍 rapidly more than 2 times - There should be no error
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #411203 (closed)
Edited by Rajan Mistry


