public boolean putLocally(final BucketRegion bucketRegion, final EntryEventImpl event,
      boolean ifNew, boolean ifOld, Object expectedOldValue, boolean requireOldValue,
      final long lastModified) throws PrimaryBucketException, ForceReattemptException {
    boolean didPut = false; // false if entry put fails

    // final BucketRegion bucketRegion = getInitializedBucketForId(event.getKey(), bucketId);

    try {
      event.setRegion(bucketRegion);

      if (event.isOriginRemote()) {
        didPut = bucketRegion.basicUpdate(event, ifNew, ifOld, lastModified, false);
      } else {
        // Skip yet another validation
        didPut = bucketRegion.virtualPut(event, ifNew, ifOld, expectedOldValue, requireOldValue,
            lastModified, false);
      }
      // bug 34361: don't send a reply if bucket was destroyed during the op
      bucketRegion.checkReadiness();
    } catch (RegionDestroyedException rde) {
      checkRegionDestroyedOnBucket(bucketRegion, event.isOriginRemote(), rde);
    }

    return didPut;
  }
Puts the object with the given key locally. <br>
Step: <br>
1) It finds out the bucket region for the bucket id. <br>
2) If from step 1 it gets null, that means the bucket is re-mapped. <br>
3) If it finds the bucket region from step 1, it tries to put the key-value on the region. <br>
4) updateBucket2Size if bucket is on more than 1 node or else bucket listeners would take care
of size update. <br>

@param bucketId the bucket id of the key
@param event the operation event
@param ifNew whether a create must be performed
@param ifOld whether an existing entry must be updated
@param lastModified time stamp for update operations
@throws ForceReattemptException if bucket region is null
@throws PrimaryBucketException if the bucket in this data store is not the primary bucket
@return true if put happened
geode-core/src/main/java/org/apache/geode/internal/cache/PartitionedRegionDataStore.java