Skip to content

(fix): ACK deleted comments on 404 from OpenSearch #2560

Zack Wynne requested to merge fix/comments-404-2560 into master

Ticket(s) / Related Merge Requests

#2560 (closed)

Summary of Changes

This MR adds an additional condition to the try/catch wrapping the Elasticsearch DELETE requests for the comment indexer. This should allow for 404 responses from Elastic to be acknowledged by the indexer.

Testing Considerations

  1. Create a comment in sandbox
  2. Delete the comment manually from Elasticsearch
  3. Delete the comment through the UI
  4. Observe that the comment indexer now ACK's the message when this happens

Deployment Considerations

None

Regression Scope

Comment indexer

Platform Affected (web, mobile, etc)

Web

Developer Testing Completed

Tested deleting comments in sandbox

Screenshots / Screen Recording

[07-Jun-2023 13:32:58 UTC] Minds.INFO: Preparing DELETE query                                                                                                                                              
[07-Jun-2023 13:32:58 UTC] Minds.INFO: Finished preparing DELETE query     ["DELETE FROM `minds_comments` WHERE `guid` = :guid;"]                                                                          
[07-Jun-2023 13:32:58 UTC] Minds.INFO: Executing DELETE query.                                                                                                                                             
[07-Jun-2023 13:32:58 UTC] Minds.INFO: Preparing Elasticsearch delete query                                                                                                                                
[07-Jun-2023 13:32:58 UTC] Minds.INFO: Elasticsearch returned a 404, comment already deleted.                                                                                                              

Does this impact

  • Localization
  • Dark/light mode
  • Guest mode

Definition of Done Checklist

  • The Acceptance Criteria has been met
  • Code is tested: Testing includes unit/spec, E2E/automated and manual testing
  • Merge requests description has been filled out
Edited by Zack Wynne

Merge request reports