Skip to content
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

Removing duplicate call to delete post #2314

Merged
merged 2 commits into from
Aug 19, 2021
Merged

Removing duplicate call to delete post #2314

merged 2 commits into from
Aug 19, 2021

Conversation

pauarge
Copy link
Contributor

@pauarge pauarge commented Aug 18, 2021

Description of the Change

When a post is deleted in ElasticPress, we see that two queries are sent to Elasticsearch to delete that post. Since they are duplicated, at least one of those queries always fails. This happens because we are sending the ep_delete_post signal twice.

This PR gets rid of that duplication.

Verification Process

We have this change deployed and running in production at VIP and it has drastically reduced the errors derived from calling the deletion of a post twice.

Checklist:

  • I have read the CONTRIBUTING document.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my change.
  • All new and existing tests passed.

Changelog Entry

  • [Fixed] Prevents a post from being attempted to delete twice.

@felipeelia felipeelia self-assigned this Aug 18, 2021
@felipeelia felipeelia added this to the 3.6.2 milestone Aug 18, 2021
@felipeelia felipeelia merged commit e3639bb into 10up:develop Aug 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants