Skip to content

Retrying error state webhooks and cleanup for orphaned ones#923

Merged
epipav merged 7 commits intomainfrom
improvement/retry-for-incoming-webhooks
Jun 5, 2023
Merged

Retrying error state webhooks and cleanup for orphaned ones#923
epipav merged 7 commits intomainfrom
improvement/retry-for-incoming-webhooks

Conversation

@epipav
Copy link
Copy Markdown
Collaborator

@epipav epipav commented May 31, 2023

Changes proposed ✍️

  • When checking stuck webhooks, now we also set the error state webhooks to pending state that wasn't tried 5 times. This will help retrying the error state webhooks again.

  • When marking a webhook as error, we now also update the retry count.

  • New cleanup function: cleanUpOrphanedWebhooks removes the orphaned webhooks from the database that doesn't belong to any integrations anymore

What

🤖 Generated by Copilot at 3b87e50

This pull request implements a new feature to retry incoming webhooks based on their state and error. It modifies the incomingWebhookRepository class, the incomingWebhooks table, and the WebhookProcessor service to support this functionality. It also includes migration scripts to update the database schema.

🤖 Generated by Copilot at 3b87e50

Oh we are the WebhookProcessor crew
We handle webhooks old and new
We add and drop the retries column
And sing this shanty as we run

Why

How

🤖 Generated by Copilot at 3b87e50

  • Add a new feature to track and retry incoming webhooks that fail to be processed by the webhook processor service (link, link, link, link, link)
  • Add a new feature to delete incoming webhooks that have no corresponding integration or have a deleted integration (link)

Checklist ✅

  • Label appropriately with Feature, Improvement, or Bug.
  • Add screehshots to the PR description for relevant FE changes
  • New backend functionality has been unit-tested.
  • API documentation has been updated (if necessary) (see docs on API documentation).
  • Quality standards are met.

@epipav epipav changed the title Improvement/retry for incoming webhooks Retrying error state webhooks and cleanup for orphaned ones May 31, 2023
@epipav epipav self-assigned this May 31, 2023
@epipav epipav added the Improvement Created by Linear-GitHub Sync label May 31, 2023
@epipav epipav marked this pull request as ready for review May 31, 2023 11:26
@epipav epipav requested a review from themarolt May 31, 2023 11:26
@epipav epipav merged commit f33f709 into main Jun 5, 2023
@epipav epipav deleted the improvement/retry-for-incoming-webhooks branch June 5, 2023 07:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Improvement Created by Linear-GitHub Sync

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants