Skip to content

Conversation

@bkioshn
Copy link
Contributor

@bkioshn bkioshn commented Dec 10, 2025

Description

Implement timers for doc-sync.

Related Issue(s)

input-output-hk/hermes#703

Description of Changes

Specification can be found here

  • Implement timers config as specify in Timers and Retries section in the spec
  • Implement SyncTimersState where it holds the state of all the timers
  • Main implementation is the quiet timer activate by the .new topic
    • start_quiet_timer: Start the quiet timer. It should runs the quiet timer in the background and there should be only one quiet timer per channel.
    • run_quiet_timer: Contains a loop that use to control the timer
    • reset_quiet_timer: Use to send a notification when the timer need to be reset
    • stop_quiet_timer: Stop the timer (the timer should be long running)
  • Unit test is added

📝 NOTES: The related pull request mention below shows how the timer is used.

Related Pull Requests

input-output-hk/hermes#707

Please confirm the following checks

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream module

Signed-off-by: bkioshn <[email protected]>
Signed-off-by: bkioshn <[email protected]>
Signed-off-by: bkioshn <[email protected]>
@bkioshn bkioshn self-assigned this Dec 10, 2025
@bkioshn bkioshn added this to Catalyst Dec 10, 2025
@bkioshn bkioshn added the squad: hermetics Hermes Backend, System Development & Integration Team label Dec 10, 2025
@bkioshn bkioshn moved this from New to 👀 In review in Catalyst Dec 10, 2025
@github-actions
Copy link
Contributor

📚 Docs Preview

The docs for this PR can be previewed at the following URL:

https://docs.dev.projectcatalyst.io/libs/feat/doc-sync-timers

@github-actions
Copy link
Contributor

github-actions bot commented Dec 10, 2025

Test Report | ${\color{lightgreen}Pass: 633/633}$ | ${\color{red}Fail: 0/633}$ |

@bkioshn bkioshn moved this from 👀 In review to 🏗 In progress in Catalyst Dec 10, 2025
@bkioshn bkioshn added the comment me Request for comments label Dec 10, 2025
@bkioshn bkioshn marked this pull request as draft December 10, 2025 10:12
@bkioshn bkioshn marked this pull request as ready for review December 10, 2025 11:31
@bkioshn bkioshn moved this from 🏗 In progress to 👀 In review in Catalyst Dec 10, 2025
@bkioshn bkioshn added the review me PR is ready for review label Dec 10, 2025
@bkioshn
Copy link
Contributor Author

bkioshn commented Dec 10, 2025

Decide to use this callback as a function over generic function object due to the complication arise in DOC_SYNC_STATE

Signed-off-by: bkioshn <[email protected]>
Signed-off-by: bkioshn <[email protected]>
Signed-off-by: bkioshn <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comment me Request for comments review me PR is ready for review squad: hermetics Hermes Backend, System Development & Integration Team

Projects

Status: 👀 In review

Development

Successfully merging this pull request may close these issues.

2 participants