/** {@inheritDoc} */
  @Override
  public void onRemoved(GridDhtCacheEntry e) {
    /*
     * Make sure not to acquire any locks here as this method
     * may be called from sensitive synchronization blocks.
     * ===================================================
     */

    GridDhtLocalPartition loc =
        localPartition(cctx.affinity().partition(e.key()), topologyVersion(), false);

    if (loc != null) loc.onRemoved(e);
  }
  /** {@inheritDoc} */
  @Override
  public GridDhtLocalPartition onAdded(AffinityTopologyVersion topVer, GridDhtCacheEntry e) {
    /*
     * Make sure not to acquire any locks here as this method
     * may be called from sensitive synchronization blocks.
     * ===================================================
     */

    int p = cctx.affinity().partition(e.key());

    GridDhtLocalPartition loc = localPartition(p, topVer, true);

    assert loc != null;

    loc.onAdded(e);

    return loc;
  }