Skip to content
  • YACOVM's avatar
    [FAB-3444] Gossip: pulled blocks aren't evicted · 05f811f2
    YACOVM authored
    
    
    In Gossip, the component that handles pulling messages
    of blocks is the pullMediator .
    
    There is a bug that was discovered, that blocks may enter the pull
    mediator's internal map, but are never evicted.
    This is because the eviction logic only worked for blocks that were manually
    added, but blocks that were consumed by update messages were never removed by
    the dedicated callback (that worked for blocks that were manually added)
    
    I fixed the bug by filtering the incoming data request with the help
    of the message store, and thus - blocks that are old don't enter
    the pull mediator.
    
    This effectively makes all blocks of the pull mediator a subset of the blocks
    in the message store (which has a fixed upper bound)
    
    Blocks that are new, cause eviction of old blocks from the pull mediator
    in the callback in channel.go line 185
    
    Change-Id: Idfcaeff68f941cc5ac7e437968ec8fa4d4a8fe31
    Signed-off-by: default avatarYacov Manevich <yacovm@il.ibm.com>
    05f811f2