Skip to content

Commit

Permalink
Also trace the times of stake distribution LSQ queries
Browse files Browse the repository at this point in the history
  • Loading branch information
Anviking committed Aug 26, 2020
1 parent 9f93d0a commit 9220846
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/shelley/src/Cardano/Wallet/Shelley/Network.hs
Original file line number Diff line number Diff line change
Expand Up @@ -441,13 +441,13 @@ withNetworkLayer tr np addrInfo versionData action = do

_stakeDistribution queue bh coin = do
let pt = toPoint getGenesisBlockHash bh
stakeMap <- handleQueryFailure
stakeMap <- handleQueryFailure $ timeQryAndLog "GetStakeDistribution" tr
(queue `send` CmdQueryLocalState pt (QueryIfCurrentShelley Shelley.GetStakeDistribution))
let toStake = Set.singleton $ Left $ toShelleyCoin coin
liftIO $ traceWith tr $ MsgWillQueryRewardsForStake coin
rewardsPerAccount <- handleQueryFailure
rewardsPerAccount <- handleQueryFailure $ timeQryAndLog "GetNonMyopicMemberRewards" tr
(queue `send` CmdQueryLocalState pt (QueryIfCurrentShelley (Shelley.GetNonMyopicMemberRewards toStake)))
pparams <- handleQueryFailure
pparams <- handleQueryFailure $ timeQryAndLog "GetCurrentPParams" tr
(queue `send` CmdQueryLocalState pt (QueryIfCurrentShelley Shelley.GetCurrentPParams))

let fromJustRewards = fromMaybe (error "stakeDistribution: requested rewards not included in response")
Expand Down

0 comments on commit 9220846

Please sign in to comment.