本文整理了Java中org.apache.geode.cache.RegionAttributes.getEntryIdleTimeout
方法的一些代码示例,展示了RegionAttributes.getEntryIdleTimeout
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。RegionAttributes.getEntryIdleTimeout
方法的具体详情如下:
包路径:org.apache.geode.cache.RegionAttributes
类名称:RegionAttributes
方法名:getEntryIdleTimeout
[英]Gets the idleTimeout
expiration attributes for entries in this region. Default is 0 which indicates that no expiration of this type is set. Note that the XML element that corresponds to this method "entry-idle-time", does not include "out" in its name.
[中]获取此区域中项的idleTimeout
过期属性。默认值为0,表示未设置此类型的过期时间。请注意,与此方法“entry idle time”对应的XML元素的名称中不包含“out”。
代码示例来源:origin: apache/geode
@Override
public int getEntryIdleTimeoutTimeLimit() {
return this.ra.getEntryIdleTimeout().getTimeout();
}
代码示例来源:origin: apache/geode
@Override
public ExpirationAction getEntryIdleTimeoutAction() {
return this.ra.getEntryIdleTimeout().getAction();
}
代码示例来源:origin: apache/geode
@Override
protected ExpirationAttributes getIdleAttributes() {
return getLocalRegion().getAttributes().getEntryIdleTimeout();
}
代码示例来源:origin: apache/geode
private void validateExpirationAttributes(final RegionAttributes userRA,
final PartitionRegionConfig prconf) {
if (!userRA.getRegionIdleTimeout().equals(prconf.getRegionIdleTimeout())) {
throw new IllegalStateException(
String.format(
"The %1$s set in RegionAttributes is incompatible with %1$s used by other distributed members.",
new Object[] {" region idle timout "}));
}
if (!userRA.getRegionTimeToLive().equals(prconf.getRegionTimeToLive())) {
throw new IllegalStateException(
String.format(
"The %1$s set in RegionAttributes is incompatible with %1$s used by other distributed members.",
new Object[] {" region time to live "}));
}
if (!userRA.getEntryIdleTimeout().equals(prconf.getEntryIdleTimeout())) {
throw new IllegalStateException(
String.format(
"The %1$s set in RegionAttributes is incompatible with %1$s used by other distributed members.",
new Object[] {" entry idle timout "}));
}
if (!userRA.getEntryTimeToLive().equals(prconf.getEntryTimeToLive())) {
throw new IllegalStateException(
String.format(
"The %1$s set in RegionAttributes is incompatible with %1$s used by other distributed members.",
new Object[] {" entry time to live "}));
}
}
代码示例来源:origin: apache/geode
private PartitionAttributes initializeAttributes(final Cache cache) {
PartitionAttributes partitionAttributes = mock(PartitionAttributes.class);
RegionAttributes attributes = mock(RegionAttributes.class);
when(attributes.getCacheListeners()).thenReturn(new CacheListener[0]);
when(attributes.getRegionTimeToLive()).thenReturn(ExpirationAttributes.DEFAULT);
when(attributes.getRegionIdleTimeout()).thenReturn(ExpirationAttributes.DEFAULT);
when(attributes.getEntryTimeToLive()).thenReturn(ExpirationAttributes.DEFAULT);
when(attributes.getEntryIdleTimeout()).thenReturn(ExpirationAttributes.DEFAULT);
when(attributes.getMembershipAttributes()).thenReturn(new MembershipAttributes());
when(cache.getRegionAttributes(RegionShortcut.PARTITION.toString())).thenReturn(attributes);
when(partitionAttributes.getTotalNumBuckets()).thenReturn(113);
return partitionAttributes;
}
代码示例来源:origin: apache/geode
protected synchronized void sendValueRequest(final InternalDistributedMember sender) {
// send a message to this responder asking for the value
// do this on the waiting pool in case the send blocks
// Always attempt to send the message to fix bug 37149
RegionAttributes attrs = this.region.getAttributes();
NetSearchRequestMessage.sendMessage(this, this.regionName, this.key, sender,
this.remainingTimeout, attrs.getEntryTimeToLive().getTimeout(),
attrs.getEntryIdleTimeout().getTimeout());
// if it turns out that we can't send a message to this member then
// our membership listener should save the day and schedule a send
// to someone else or give up and report a failed search.
}
代码示例来源:origin: apache/geode
allCustomTtl.add(ra.getCustomEntryTimeToLive().toString());
allRegionIdleTimeout.add(ra.getRegionIdleTimeout());
allEntryIdleTimeout.add(ra.getEntryIdleTimeout());
allCustomIdle.add(ra.getCustomEntryIdleTimeout().toString());
allScopes.add(ra.getScope());
代码示例来源:origin: apache/geode
when(regionAttributes.getRegionIdleTimeout()).thenReturn(expirationAttributes);
when(regionAttributes.getEntryTimeToLive()).thenReturn(expirationAttributes);
when(regionAttributes.getEntryIdleTimeout()).thenReturn(expirationAttributes);
when(regionAttributes.getDataPolicy()).thenReturn(dataPolicy);
when(regionAttributes.getDiskStoreName()).thenReturn("store");
代码示例来源:origin: apache/geode
NetLoadRequestMessage.sendMessage(this, this.regionName, this.key, this.aCallbackArgument,
next, this.remainingTimeout, attrs.getEntryTimeToLive().getTimeout(),
attrs.getEntryIdleTimeout().getTimeout());
waitForObject2(this.remainingTimeout);
if (this.remoteException == null) {
代码示例来源:origin: apache/geode
when(attrs.getDataPolicy()).thenReturn(DataPolicy.EMPTY);
when(attrs.getEntryTimeToLive()).thenReturn(expirationAttrs);
when(attrs.getEntryIdleTimeout()).thenReturn(expirationAttrs);
when(advisor.adviseInitializedReplicates()).thenReturn(replicates);
代码示例来源:origin: apache/geode
attrs.getEntryIdleTimeout().getTimeout());
代码示例来源:origin: apache/geode
private synchronized void sendNetSearchRequest() {
InternalDistributedMember nextResponder = nextAppropriateResponder();
if (nextResponder != null) {
// Make a request to the next responder in the queue
RegionAttributes attrs = this.region.getAttributes();
setSelectedNode(nextResponder);
this.requestInProgress = true;
this.remoteGetInProgress = true;
NetSearchRequestMessage.sendMessage(this, this.regionName, this.key, nextResponder,
this.remainingTimeout, attrs.getEntryTimeToLive().getTimeout(),
attrs.getEntryIdleTimeout().getTimeout());
} else {
this.remoteGetInProgress = false;
checkIfDone();
}
}
代码示例来源:origin: apache/geode
entryTimeToLive = ra.getEntryTimeToLive().getTimeout();
isLockGrantor = ra.isLockGrantor();
entryIdleTimeout = ra.getEntryIdleTimeout().getTimeout();
regionIdleTimeout = ra.getRegionIdleTimeout().getTimeout();
regionTimeToLive = ra.getRegionTimeToLive().getTimeout();
ExpirationAction expAction = ra.getEntryIdleTimeout().getAction();
if (expAction != null) {
entryIdleTimeoutAction = expAction.toString();
代码示例来源:origin: apache/geode
idleAttributes = regionAttributes.getEntryIdleTimeout();
return null;
} else if ((ttlDisabled || ttlAttributes.equals(regionAttributes.getEntryTimeToLive()))
&& (idleDisabled || idleAttributes.equals(regionAttributes.getEntryIdleTimeout()))) {
代码示例来源:origin: apache/geode
int regionIdleTimeout = regAttrs.getRegionIdleTimeout().getTimeout();
int entryTimeToLive = regAttrs.getEntryTimeToLive().getTimeout();
int entryIdleTimeout = regAttrs.getEntryIdleTimeout().getTimeout();
代码示例来源:origin: apache/geode
this.cacheLoader = attrs.getCacheLoader();
this.cacheWriter = attrs.getCacheWriter();
this.entryIdleTimeout = attrs.getEntryIdleTimeout();
this.customEntryIdleTimeout = attrs.getCustomEntryIdleTimeout();
this.entryTimeToLive = attrs.getEntryTimeToLive();
代码示例来源:origin: apache/geode
regionAttributes.getEntryTimeToLive().getAction();
this.regionAttributes.customEntryTimeToLive = regionAttributes.getCustomEntryTimeToLive();
this.regionAttributes.entryIdleTimeout = regionAttributes.getEntryIdleTimeout().getTimeout();
this.regionAttributes.entryIdleTimeoutExpirationAction =
regionAttributes.getEntryIdleTimeout().getAction();
this.regionAttributes.customEntryIdleTimeout = regionAttributes.getCustomEntryIdleTimeout();
代码示例来源:origin: apache/geode
setEntryTimeToLiveAttributes();
this.customEntryTimeToLive = attrs.getCustomEntryTimeToLive();
this.entryIdleTimeout = attrs.getEntryIdleTimeout().getTimeout();
this.entryIdleTimeoutExpirationAction = attrs.getEntryIdleTimeout().getAction();
setEntryIdleTimeoutAttributes();
this.customEntryIdleTimeout = attrs.getCustomEntryIdleTimeout();
代码示例来源:origin: apache/geode
this.eTtl = attr.getEntryTimeToLive();
this.customEttlDesc = getDesc(attr.getCustomEntryTimeToLive());
this.eIdleTimeout = attr.getEntryIdleTimeout();
this.customEIdleDesc = getDesc(attr.getCustomEntryIdleTimeout());
this.dataPolicy = attr.getDataPolicy();
代码示例来源:origin: apache/geode
assertEquals(0, attrs.getEntryTimeToLive().getTimeout());
assertEquals(null, attrs.getCustomEntryTimeToLive());
assertEquals(0, attrs.getEntryIdleTimeout().getTimeout());
assertEquals(null, attrs.getCustomEntryIdleTimeout());
assertEquals(Scope.DISTRIBUTED_NO_ACK, attrs.getScope());
内容来源于网络,如有侵权,请联系作者删除!