Examples of ICompositeCache


Examples of org.apache.stratum.jcs.engine.behavior.ICompositeCache

                            log.debug( "puts = " + puts );
                        }
                    }

                    getCacheManager();
                    ICompositeCache cache = ( ICompositeCache ) cacheMgr.getCache( irca.getCacheName() );
                    cache.update( cb, ICache.REMOTE_INVOKATION );

                }

            }
            else
View Full Code Here

Examples of org.apache.stratum.jcs.engine.behavior.ICompositeCache

            // ordered cache item update and notification.
            synchronized ( cacheDesc )
            {
                try
                {
                    ICompositeCache c = ( ICompositeCache ) cacheDesc.cache;

                    //TODO; make this a bit less of a hack
                    // If the source of this request was from a cluster, then
                    // update the remote caches.  COnsider it a local update.
                    // This requires that two local caches not be connected to
                    // two clustered remote caches. The failover runner will
                    // have to make sure of this.  ALos, the local cache needs
                    // avoid updating this source.  Will need to pass the source
                    // id somehow.  The remote cache should udate all local caches
                    // but not update the cluster source.  Cluster remote caches
                    // should only be updated by the server and not the RemoteCache.
                    // PUT LOGIC IN REMOTE CACHE
                    // WILL TRY UPDATING REMOTES
                    if ( fromCluster )
                    {
                        if ( log.isDebugEnabled() )
                        {
                            log.debug( "not updating clusters **************************************" );
                        }
                        c.update( item, ICache.REMOTE_INVOKATION );
                    }
                    else
                    {
                        if ( log.isDebugEnabled() )
                        {
                            log.debug( "updating clusters **************************************" );
                        }
                        c.update( item, ICache.LOCAL_INVOKATION );
                    }
                }
                catch ( Exception oee )
                {
                }

                // UPDATE LOCALS IF A REQUEST COMES FROM A CLUSTER
                // IF LOCAL CLUSTER CONSISTENCY IS CONFIGURED
                ICompositeCache cache = ( ICompositeCache ) cacheDesc.cache;
                if ( !fromCluster || ( fromCluster && rcsa.getLocalClusterConsistency() ) )
                {

                    ICacheEventQueue[] qlist = getEventQList( cacheDesc, requesterId );

View Full Code Here

Examples of org.apache.stratum.jcs.engine.behavior.ICompositeCache

        {
            return null;
        }
        else
        {
            ICompositeCache c = ( ICompositeCache ) cacheDesc.cache;
//            if ( fromCluster )
//            {
            return c.get( key, container, ICache.REMOTE_INVOKATION );
//            }
//            else
//            {
//                if ( this.rcsa.getAllowClusterGet() )
//                {
View Full Code Here

Examples of org.apache.stratum.jcs.engine.behavior.ICompositeCache

            {

                boolean removeSuccess = false;

                // No need to notify if it was not cached.
                ICompositeCache c = ( ICompositeCache ) cacheDesc.cache;

                if ( fromCluster )
                {
                    if ( log.isDebugEnabled() )
                    {
                        log.debug( "not updating clusters **************************************" );
                    }
                    removeSuccess = c.remove( key, ICache.REMOTE_INVOKATION );
                }
                else
                {
                    if ( log.isDebugEnabled() )
                    {
                        log.debug( "updating clusters **************************************" );
                    }
                    removeSuccess = c.remove( key, ICache.LOCAL_INVOKATION );
                }

                if ( removeSuccess )
                {

                    // UPDATE LOCALS IF A REQUEST COMES FROM A CLUSTER
                    // IF LOCAL CLUSTER CONSISTENCY IS CONFIGURED
                    ICompositeCache cache = ( ICompositeCache ) cacheDesc.cache;
                    if ( !fromCluster || ( fromCluster && rcsa.getLocalClusterConsistency() ) )
                    {

                        ICacheEventQueue[] qlist = getEventQList( cacheDesc, requesterId );

View Full Code Here

Examples of org.apache.stratum.jcs.engine.behavior.ICompositeCache

        if ( log.isDebugEnabled() )
        {
            log.debug( "PUTTING ELEMENT FROM LATERAL" );
        }
        getCacheManager();
        ICompositeCache cache = ( ICompositeCache ) cacheMgr.getCache( cb.getCacheName() );
        cache.update( cb, ICache.REMOTE_INVOKATION );
        //handleRemove(cb.getCacheName(), cb.getKey());
    }
View Full Code Here

Examples of org.apache.stratum.jcs.engine.behavior.ICompositeCache

        }

        getCacheManager();
        // interface limitation here

        ICompositeCache cache = ( ICompositeCache ) cacheMgr.getCache( cacheName );
        cache.remove( key, ICache.REMOTE_INVOKATION );
    }
View Full Code Here

Examples of org.apache.stratum.jcs.engine.behavior.ICompositeCache

        if ( log.isDebugEnabled() )
        {
            log.debug( "handleGet> cacheName=" + cacheName + ", key = " + key );
        }
        getCacheManager();
        ICompositeCache cache = ( ICompositeCache ) cacheMgr.getCache( cacheName );
        // get container
        return cache.get( key, true, ICache.REMOTE_INVOKATION );
    }
View Full Code Here

Examples of org.apache.stratum.jcs.engine.behavior.ICompositeCache

    protected Cache createSystemCache( String cacheName,
                                       ICache[] auxCaches,
                                       ICompositeCacheAttributes cattr,
                                       IElementAttributes attr )
    {
        ICompositeCache systemGroupIdCache =
            ( ICompositeCache ) systemCaches.get( "groupIdCache" );

        return new GroupCache( cacheName, auxCaches, cattr, attr,
            systemGroupIdCache );
    }
View Full Code Here

Examples of org.apache.stratum.jcs.engine.behavior.ICompositeCache

    protected Cache createCache( String cacheName,
                                 ICache[] auxCaches,
                                 ICompositeCacheAttributes cattr,
                                 IElementAttributes attr )
    {
        ICompositeCache systemGroupIdCache =
            ( ICompositeCache ) systemCaches.get( "groupIdCache" );

        return new GroupCache( cacheName, auxCaches, cattr, attr,
            systemGroupIdCache );
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.