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

notification service: save commit status and deliveries #430

Closed
alessandro-sorint opened this issue Sep 12, 2023 · 0 comments · Fixed by #432
Closed

notification service: save commit status and deliveries #430

alessandro-sorint opened this issue Sep 12, 2023 · 0 comments · Fixed by #432
Labels
enhancement New feature or request

Comments

@alessandro-sorint
Copy link
Contributor

alessandro-sorint commented Sep 12, 2023

What would you like to be added:
Actually the notification service implement the update remote commit status when it handle a RunEvent.
We would like to separate the logic of creation of the commit status from the delivery, as done for run webhooks.

Why is this needed:
It could be useful for example for a future implementation of delivery retry logic.
We avoid duplicated commit status deliverys: we can save the commit status and delivery in the same db transaction, where it is saved the LastRunEventSequence(and RunWebhook, RunWebhookDelivery).
A dedicated handle will do the delivery, as done for RunWebhookDelivery.

It is needed to add 2 table:

CommitStatus
* ProjectID    string
* Status string
* CommitSHA    string
* RunCounter   uint64
* Description  string
* Context      string
CommitStatusDelivery
* Sequence uint64
* CommitStatusID string
* DeliveryStatus DeliveryStatus
* DeliveredAt *time.Time
@alessandro-sorint alessandro-sorint added the enhancement New feature or request label Sep 12, 2023
@sgotti sgotti changed the title notification service: save commit status and deliverys notification service: save commit status and deliveries Oct 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant