public void checkForPrimary() { final boolean isp = getBucketAdvisor().isPrimary(); if (!isp) { this.partitionedRegion.checkReadiness(); checkReadiness(); InternalDistributedMember primaryHolder = getBucketAdvisor().basicGetPrimaryMember(); throw new PrimaryBucketException( "Bucket " + getName() + " is not primary. Current primary holder is " + primaryHolder); } }
VersionTag v = regionEntry.generateVersionTag(null, false, this, event); if (logger.isDebugEnabled() && v != null) { logger.debug("generated version tag {} in region {}", v, this.getName());
logger.debug("getLocally: key {}) bucketId={}{}{} region {} returnTombstones {} ", key, this.partitionedRegion.getPRId(), PartitionedRegion.BUCKET_ID_SEPARATOR, bucketId, bucketRegion.getName(), returnTombstones);
@Override public void basicDestroyBeforeRemoval(RegionEntry entry, EntryEventImpl event) { long token = -1; DestroyOperation op = null; try { // Assumed this is called with entry synchrony if (!event.isOriginRemote() && !event.isBulkOpInProgress() && !event.getOperation().isLocal() && !Operation.EVICT_DESTROY.equals(event.getOperation()) && !(event.isExpiration() && isEntryEvictDestroyEnabled())) { if (event.getVersionTag() == null || event.getVersionTag().isGatewayTag()) { VersionTag v = entry.generateVersionTag(null, false, this, event); if (logger.isDebugEnabled() && v != null) { logger.debug("generated version tag {} in region {}", v, this.getName()); } } // This code assumes it is safe ignore token mode (GII in progress) // because it assume when the origin of the event is local, // then GII has completed (the region has been completely initialized) // This code assumes that this bucket is primary // before distribute: BR.destroy for retain op = new DestroyOperation(event); token = op.startOperation(); } super.basicDestroyBeforeRemoval(entry, event); } finally { if (op != null) { op.endOperation(token); } } }
protected void distributeUpdateOperation(EntryEventImpl event, long lastModified) { long token = -1; UpdateOperation op = null; try { if (!event.isOriginRemote() && !event.isNetSearch() && getBucketAdvisor().isPrimary()) { if (event.isBulkOpInProgress()) { // consolidate the UpdateOperation for each entry into a PutAllMessage // since we did not call basicPutPart3(), so we have to explicitly addEntry here event.getPutAllOperation().addEntry(event, this.getId()); } else { // before distribute: BR's put op = new UpdateOperation(event, lastModified); token = op.startOperation(); if (logger.isDebugEnabled()) { logger.debug("sent update operation : for region : {}: with event: {}", this.getName(), event); } } } if (!event.getOperation().isPutAll()) { // putAll will invoke listeners later event.invokeCallbacks(this, true, true); } } finally { if (op != null) { op.endOperation(token); } } }
logger.debug("containsKeyLocally: key {}) bucketId={}{}{} region {} returns {}", key, this.partitionedRegion.getPRId(), PartitionedRegion.BUCKET_ID_SEPARATOR, bucketId, bucketRegion.getName(), ret);
logger.debug("getSerializedLocally: key {}) bucketId={}{}{} region {}", keyInfo.getKey(), this.partitionedRegion.getPRId(), PartitionedRegion.BUCKET_ID_SEPARATOR, keyInfo.getBucketId(), bucketRegion.getName());
logger.debug("getEntryLocally: key {}) bucketId={}{}{} region {}", key, this.partitionedRegion.getPRId(), PartitionedRegion.BUCKET_ID_SEPARATOR, bucketId, bucketRegion.getName());
if (v != null) { if (logger.isDebugEnabled()) { logger.debug("generated version tag {} in region {}", v, this.getName());