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

Make stake pools engine rollback faster. #1285

Merged
merged 2 commits into from Jan 20, 2020

Conversation

KtorZ
Copy link
Member

@KtorZ KtorZ commented Jan 20, 2020

Issue Number

#1281

Overview

  • fe138cc
    Log roll back attempts in pools monitoring
    When rolling back, we currently only log monitoring restarts, which
    can be somewhat confusing when done several times in a row:

    [pools-engine] Monitoring stake pools. Currently at f4260343-[1158372.5#220]
    [pools-engine] Monitoring stake pools. Currently at 20bd31a4-[1158372.1#216]
    [pools-engine] Monitoring stake pools. Currently at 437a7400-[1158371.6#212]
    [pools-engine] Monitoring stake pools. Currently at 5c874264-[1158371.2#208]

    Although this is typical of rollbacks, it's better to mention it
    explicitely to better track what the system is doing.

  • 76bf85a
    increase network layer observation window's length

Comments

See details in #1281

  When rolling back, we currently only log monitoring restarts, which
  can be somewhat confusing when done several times in a row:

  [pools-engine] Monitoring stake pools. Currently at f4260343-[1158372.5#220]
  [pools-engine] Monitoring stake pools. Currently at 20bd31a4-[1158372.1#216]
  [pools-engine] Monitoring stake pools. Currently at 437a7400-[1158371.6#212]
  [pools-engine] Monitoring stake pools. Currently at 5c874264-[1158371.2#208]

  Although this is typical of rollbacks, it's better to mention it
  explicitely to better track what the system is doing.
@KtorZ KtorZ self-assigned this Jan 20, 2020
@KtorZ KtorZ changed the title Ktor z/1281/faster stake pools rollback Make stake pools engine rollback faster. Jan 20, 2020
@KtorZ
Copy link
Member Author

KtorZ commented Jan 20, 2020

bors try

iohk-bors bot added a commit that referenced this pull request Jan 20, 2020
@iohk-bors
Copy link
Contributor

iohk-bors bot commented Jan 20, 2020

try

Build succeeded

@@ -175,7 +177,7 @@ monitorStakePools tr nl db@DBLayer{..} = do
readPoolRegistration poolId >>= \case
Nothing -> putPoolRegistration sl0 r
Just{} -> pure ()
readPoolProductionCursor k
readPoolProductionCursor (max 100 k)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why 100 here?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah, ok. explained below

Copy link
Contributor

@paweljakubas paweljakubas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@KtorZ KtorZ merged commit ee9de47 into master Jan 20, 2020
@KtorZ KtorZ deleted the KtorZ/1281/faster-stake-pools-rollback branch January 20, 2020 12:48
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.

None yet

2 participants