cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From un...@apache.org
Subject cvs commit: cocoon-2.1/src/blocks/eventcache/java/org/apache/cocoon/caching/impl StoreEventRegistryImpl.java
Date Tue, 29 Jun 2004 10:46:54 GMT
unico       2004/06/29 03:46:54

  Modified:    src/blocks/eventcache/java/org/apache/cocoon/caching/impl
                        StoreEventRegistryImpl.java
  Log:
  PersistentStore is no more
  
  Revision  Changes    Path
  1.9       +13 -14    cocoon-2.1/src/blocks/eventcache/java/org/apache/cocoon/caching/impl/StoreEventRegistryImpl.java
  
  Index: StoreEventRegistryImpl.java
  ===================================================================
  RCS file: /home/cvs/cocoon-2.1/src/blocks/eventcache/java/org/apache/cocoon/caching/impl/StoreEventRegistryImpl.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- StoreEventRegistryImpl.java	19 May 2004 08:44:26 -0000	1.8
  +++ StoreEventRegistryImpl.java	29 Jun 2004 10:46:54 -0000	1.9
  @@ -24,29 +24,29 @@
   
   /**
    * This implementation of <code>EventRegistry</code> stores its <code>EventRegistryDataWrapper</code>
  - * in the <code>PersistentStore</code> defined in cocoon.xconf.
  + * in the default <code>Store</code> defined in cocoon.xconf.
    * 
    * @since 2.1
    * @author <a href="mailto:ghoward@apache.org">Geoff Howard</a>
    * @version CVS $Id$
    */
  -public class StoreEventRegistryImpl
  -    extends AbstractDoubleMapEventRegistry
  -    implements Serviceable {
  +public class StoreEventRegistryImpl extends AbstractDoubleMapEventRegistry 
  +implements Serviceable {
  +
       private static final String EVENTREGISTRYKEY = "EVENTREGWRAPPER";
       private ServiceManager m_manager;
  -    private Store m_persistentStore;
  +    private Store m_store;
   
       protected void persist(EventRegistryDataWrapper wrapper) {
           EventRegistryDataWrapper ecdw = wrapRegistry();
           try {
  -            m_persistentStore.store(EVENTREGISTRYKEY, ecdw);
  +            m_store.store(EVENTREGISTRYKEY, ecdw);
           } catch (IOException e) {
               getLogger().warn("Unable to persist Event Registry");
           }
  -        this.m_manager.release(this.m_persistentStore);
  +        this.m_manager.release(this.m_store);
           m_manager = null;
  -        m_persistentStore = null;
  +        m_store = null;
       }
   
       /**
  @@ -54,19 +54,18 @@
   	 */
       public void service(ServiceManager manager) throws ServiceException {
           this.m_manager = manager;
  -        this.m_persistentStore = (Store) manager.lookup(Store.ROLE);
  +        this.m_store = (Store) manager.lookup(Store.ROLE);
       }
   
       /**
   	 * Recover the datawrapper from the Store.
   	 */
       protected boolean recover() {
  -        Object o = m_persistentStore.get(EVENTREGISTRYKEY);
  -        m_persistentStore.remove(EVENTREGISTRYKEY);
  +        Object o = m_store.get(EVENTREGISTRYKEY);
  +        m_store.remove(EVENTREGISTRYKEY);
           if (o != null && o instanceof EventRegistryDataWrapper) {
               if (getLogger().isInfoEnabled()) {
  -                getLogger().info(
  -                    "Retrieving EventRegistry from PersistentStore.");
  +                getLogger().info("Retrieving EventRegistry from Store.");
               }
               unwrapRegistry((EventRegistryDataWrapper) o);
               return true;
  
  
  

Mime
View raw message