Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
  • Loading branch information
4eUeP authored Sep 18, 2023
1 parent b597fcd commit 0e97c26
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions hstream-admin/store/HStream/Admin/Store/Command/Logs.hs
Original file line number Diff line number Diff line change
Expand Up @@ -54,15 +54,13 @@ runLogsUpdate conf UpdateLogsOpts{..} = do
case res of
Right loggroup -> S.logGroupGetAttrs loggroup
Left (_ :: S.NOTFOUND) -> S.logDirectoryGetAttrs =<< S.getLogDirectory client updatePath
putStrLn $ "updateReplicateAcross: " <> show updateReplicateAcross
let attrs' =
attrs { logReplicationFactor = maybe logReplicationFactor S.defAttr1 updateReplicationFactor
, logSyncedCopies = maybe logSyncedCopies S.defAttr1 updateSyncedCopies
, logBacklogDuration = maybe logBacklogDuration (S.defAttr1 . Just) updateBacklogDuration
, logReplicateAcross = updateRepAcross updateReplicateAcross logReplicateAcross
, logAttrsExtras = updateExtras `Map.union` logAttrsExtras
}
putStrLn $ "new attrs: " <> show attrs'
attrsPtr <- S.pokeLogAttributes attrs'
withForeignPtr attrsPtr $ S.ldWriteAttributes client updatePath
case res of
Expand Down

0 comments on commit 0e97c26

Please sign in to comment.