}
}
for ( int i = 0; i < auxCaches.length; i++ )
{
ICache aux = auxCaches[i];
if ( log.isDebugEnabled() )
{
log.debug( "Auxilliary cache type: " + aux.getCacheType() );
}
if ( aux == null )
{
continue;
}
// SEND TO REMOTE STORE
if ( aux.getCacheType() == ICache.REMOTE_CACHE )
{
if ( log.isDebugEnabled() )
{
log.debug( "ce.getElementAttributes().getIsRemote() = "
+ cacheElement.getElementAttributes().getIsRemote() );
}
if ( cacheElement.getElementAttributes().getIsRemote() && !localOnly )
{
try
{
// need to make sure the group cache understands that
// the key is a group attribute on update
aux.update( cacheElement );
if ( log.isDebugEnabled() )
{
log.debug( "Updated remote store for " + cacheElement.getKey() + cacheElement );
}
}
catch ( IOException ex )
{
log.error( "Failure in updateExclude", ex );
}
}
// SEND LATERALLY
}
else if ( aux.getCacheType() == ICache.LATERAL_CACHE )
{
// lateral can't do the checking since it is dependent on the
// cache region restrictions
if ( log.isDebugEnabled() )
{
log.debug( "lateralcache in aux list: cattr " + cacheAttr.getUseLateral() );
}
if ( cacheAttr.getUseLateral() && cacheElement.getElementAttributes().getIsLateral() && !localOnly )
{
// later if we want a multicast, possibly delete abnormal
// broadcaster
// DISTRIBUTE LATERALLY
// Currently always multicast even if the value is
// unchanged,
// just to cause the cache item to move to the front.
aux.update( cacheElement );
if ( log.isDebugEnabled() )
{
log.debug( "updated lateral cache for " + cacheElement.getKey() );
}
}
}
// update disk if the usage pattern permits
else if ( aux.getCacheType() == ICache.DISK_CACHE )
{
if ( log.isDebugEnabled() )
{
log.debug( "diskcache in aux list: cattr " + cacheAttr.getUseDisk() );
}
if ( cacheAttr.getUseDisk()
&& ( cacheAttr.getDiskUsagePattern() == ICompositeCacheAttributes.DISK_USAGE_PATTERN_UPDATE )
&& cacheElement.getElementAttributes().getIsSpool() )
{
aux.update( cacheElement );
if ( log.isDebugEnabled() )
{
log.debug( "updated disk cache for " + cacheElement.getKey() );
}
}