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.2/src/java/org/apache/cocoon cocoon.roles
Date Fri, 26 Dec 2003 18:41:39 GMT
unico       2003/12/26 10:41:39

  Modified:    src/java/org/apache/cocoon/bean CocoonBean.java
               tools/targets ide-build.xml
               src/java/org/apache/cocoon cocoon.roles
  Log:
  role management seems to be inevitable for now. 
  For instance, excalibur xmlutils do not have Fortress meta info yet.
  Fortress' role management support uses a different role file format.
  
  Revision  Changes    Path
  1.42      +4 -1      cocoon-2.2/src/java/org/apache/cocoon/bean/CocoonBean.java
  
  Index: CocoonBean.java
  ===================================================================
  RCS file: /home/cvs/cocoon-2.2/src/java/org/apache/cocoon/bean/CocoonBean.java,v
  retrieving revision 1.41
  retrieving revision 1.42
  diff -u -r1.41 -r1.42
  --- CocoonBean.java	22 Oct 2003 17:38:16 -0000	1.41
  +++ CocoonBean.java	26 Dec 2003 18:41:38 -0000	1.42
  @@ -84,6 +84,7 @@
       private String m_logConfigURI = m_contextURI + File.separator + "cocoon.xlog";
       private String m_logCategory = "cocoon";
       private String m_configURI = Constants.DEFAULT_CONF_FILE;
  +    private String m_roleConfigURI = "resource://org/apache/cocoon/cocoon.roles";
       private List m_classForceLoadList = new ArrayList();
       private String m_classPath = System.getProperty( "java.class.path" );
       private int m_threadsPerCPU = 1;
  @@ -299,7 +300,8 @@
           m_confBuilder.setContextClassLoader( m_parentClassLoader );
           m_confBuilder.setCommandFailureHandlerClass( CocoonCommandFailureHandler.class
);
           m_confBuilder.setContainerClass(CocoonContainer.class);
  -
  +        m_confBuilder.setRoleManagerConfiguration(m_roleConfigURI);
  +        
           m_confBuilder.setLifecycleExtensionManager( getLifecycleExtensionManager() );
   
           DefaultContext initContext = new DefaultContext( m_confBuilder.getContext() );
  @@ -359,4 +361,5 @@
           dispose();
           super.finalize();
       }
  +    
   }
  
  
  
  1.6       +1 -0      cocoon-2.2/tools/targets/ide-build.xml
  
  Index: ide-build.xml
  ===================================================================
  RCS file: /home/cvs/cocoon-2.2/tools/targets/ide-build.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- ide-build.xml	26 Dec 2003 13:20:21 -0000	1.5
  +++ ide-build.xml	26 Dec 2003 18:41:38 -0000	1.6
  @@ -124,6 +124,7 @@
             <include name="services.list"/>
             <include name="**/*.meta"/>
             <include name="**/*.deps"/>
  +          <include name="org/apache/cocoon/cocoon.roles"/>
           </fileset>
         </copy>
     </target>
  
  
  
  1.13      +100 -66   cocoon-2.2/src/java/org/apache/cocoon/cocoon.roles
  
  Index: cocoon.roles
  ===================================================================
  RCS file: /home/cvs/cocoon-2.2/src/java/org/apache/cocoon/cocoon.roles,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- cocoon.roles	21 Oct 2003 13:48:31 -0000	1.12
  +++ cocoon.roles	26 Dec 2003 18:41:39 -0000	1.13
  @@ -1,35 +1,34 @@
   <?xml version="1.0"?>
   <!DOCTYPE role-list [
   <!ELEMENT role-list (role+)>
  -<!ELEMENT role (hint*)>
  -<!ELEMENT hint EMPTY>
  -<!ATTLIST role name CDATA #REQUIRED
  -               shorthand CDATA #REQUIRED
  -               default-class CDATA #IMPLIED
  ->
  -<!ATTLIST hint shorthand CDATA #REQUIRED
  -               class CDATA #REQUIRED
  +<!ELEMENT role (component*)>
  +<!ELEMENT component EMPTY>
  +<!ATTLIST role name CDATA #REQUIRED>
  +<!ATTLIST component 
  +  shorthand CDATA #REQUIRED
  +  class CDATA #REQUIRED
  +  handler CDATA #IMPLIED
   >
   ]>
   
   <role-list>
   
  -  <role name="org.apache.excalibur.source.SourceFactorySelector"
  -        shorthand="source-factories"
  -        default-class="org.apache.avalon.excalibur.component.ExcaliburComponentSelector">
  +  <role name="org.apache.excalibur.source.SourceResolver">
  +    <component 
  +      shorthand="source-resolver"
  +      class="org.apache.cocoon.components.source.CocoonSourceResolver"
  +      handler="org.apache.avalon.fortress.impl.handler.ThreadSafeComponentHandler"
  +    />
     </role>
   
  -  <!-- This is the source resolver for Cocoon - do not change this!
  -       If you want to use your own source resolver, define a 
  -       component for the role org.apache.excalibur.source.SourceResolver/Cocoon -->
  -  <role name="org.apache.excalibur.source.SourceResolver"
  -        shorthand="source-resolver"
  -        default-class="org.apache.cocoon.components.source.CocoonSourceResolver"/>
  -
     <!-- The entity resolver used by most parsers -->
  -  <role name="org.apache.excalibur.xml.EntityResolver"
  -        shorthand="entity-resolver"
  -        default-class="org.apache.cocoon.components.resolver.DefaultResolver"/>
  +  <role name="org.apache.excalibur.xml.EntityResolver">
  +    <component
  +      shorthand="entity-resolver"
  +      class="org.apache.cocoon.components.resolver.DefaultResolver"
  +      handler="org.apache.avalon.fortress.impl.handler.ThreadSafeComponentHandler"
  +    />
  +  </role>
   
     <!-- Parser:
   
  @@ -41,44 +40,91 @@
     -->
   
     <!-- This is the usual SAX parser -->
  -  <role name="org.apache.excalibur.xml.sax.SAXParser"
  -        shorthand="xml-parser"
  -        default-class="org.apache.excalibur.xml.impl.JaxpParser"/>
  -
  -  <!-- This is the usual DOM parser -->
  -  <role name="org.apache.excalibur.xml.dom.DOMParser"
  -        shorthand="dom-parser"
  -        default-class="org.apache.excalibur.xml.impl.JaxpParser"/>
  +  <role name="org.apache.excalibur.xml.sax.SAXParser">
  +    <component
  +      shorthand="xml-parser"
  +      class="org.apache.excalibur.xml.impl.JaxpParser"
  +      handler="org.apache.avalon.fortress.impl.handler.ThreadSafeComponentHandler"
  +    />
  +  </role>
   
  -  <!-- A Dom Serializer -->
  -  <role default-class="org.apache.excalibur.xml.dom.DefaultDOMSerializer" name="org.apache.excalibur.xml.dom.DOMSerializer"
shorthand="dom-serializer"/>
  +  <!-- This is the usual DOM parser 
  +  <role name="org.apache.excalibur.xml.dom.DOMParser">
  +    <component
  +      shorthand="dom-parser"
  +      class="org.apache.excalibur.xml.impl.JaxpParser"
  +      handler="org.apache.avalon.fortress.impl.handler.ThreadSafeComponentHandler"
  +    />
  +  </role>
  +  -->
   
  +  <!-- A Dom Serializer -->
  +  <role name="org.apache.excalibur.xml.dom.DOMSerializer">
  +    <component
  +      class="org.apache.excalibur.xml.dom.DefaultDOMSerializer"
  +      shorthand="dom-serializer"
  +      handler="org.apache.avalon.fortress.impl.handler.ThreadSafeComponentHandler"
  +    />
  +  </role>
  +  
     <!-- XSLT: -->
  -  <role name="org.apache.excalibur.xml.xslt.XSLTProcessor"
  -        shorthand="xslt-processor"
  -        default-class="org.apache.excalibur.xml.xslt.XSLTProcessorImpl"/>
  -
  -  <role name="org.apache.excalibur.xml.xpath.XPathProcessor"
  -        shorthand="xpath-processor"
  -        default-class="org.apache.excalibur.xml.xpath.XPathProcessorImpl"/>
  +  <role name="org.apache.excalibur.xml.xslt.XSLTProcessor">
  +    <component 
  +      shorthand="xslt-processor"
  +      class="org.apache.excalibur.xml.xslt.XSLTProcessorImpl"
  +      handler="org.apache.avalon.fortress.impl.handler.ThreadSafeComponentHandler"
  +    />
  +  </role>
  +
  +  <role name="org.apache.excalibur.xmlizer.XMLizer">
  +    <component 
  +      shorthand="xmlizer"
  +      class="org.apache.excalibur.xmlizer.DefaultXMLizer"
  +      handler="org.apache.avalon.fortress.impl.handler.ThreadSafeComponentHandler"
  +    />  
  +  </role>
  +  
  +  <role name="org.apache.excalibur.xml.xpath.XPathProcessor">
  +    <component
  +      shorthand="xpath-processor"
  +      class="org.apache.excalibur.xml.xpath.XPathProcessorImpl"
  +      handler="org.apache.avalon.fortress.impl.handler.ThreadSafeComponentHandler"
  +    />
  +  </role>
   
     <!-- Stores: -->
  -  <role name="org.apache.excalibur.store.Store"
  -       shorthand="persistent-store"
  -       default-class="org.apache.cocoon.components.store.impl.DefaultStore"/>
  -
  -  <role name="org.apache.excalibur.store.Store/TransientStore"
  -        shorthand="transient-store"
  -        default-class="org.apache.excalibur.store.impl.MRUMemoryStore"/>
  -
  -  <role name="org.apache.excalibur.store.StoreJanitor"
  -       shorthand="store-janitor"
  -       default-class="org.apache.excalibur.store.impl.StoreJanitorImpl"/>
  -
  -  <role name="org.apache.cocoon.Processor"
  -        shorthand="sitemap"
  -        default-class="org.apache.cocoon.components.treeprocessor.TreeProcessor"/>
  +  <role name="org.apache.excalibur.store.Store">
  +    <component 
  +      shorthand="persistent-store"
  +      class="org.apache.cocoon.components.store.impl.DefaultStore"
  +      handler="org.apache.avalon.fortress.impl.handler.ThreadSafeComponentHandler"
  +    />
  +  </role>
  +  
  +  <role name="org.apache.excalibur.store.Store/TransientStore">
  +    <component
  +      shorthand="transient-store"
  +      class="org.apache.excalibur.store.impl.MRUMemoryStore"
  +      handler="org.apache.avalon.fortress.impl.handler.ThreadSafeComponentHandler"
  +    />
  +  </role>
  +
  +  <role name="org.apache.excalibur.store.StoreJanitor">
  +    <component
  +      shorthand="store-janitor"
  +      class="org.apache.excalibur.store.impl.StoreJanitorImpl"
  +      handler="org.apache.avalon.fortress.impl.handler.ThreadSafeComponentHandler"
  +    />
  +  </role>
   
  +  <role name="org.apache.cocoon.components.modules.input.SitemapVariableHolder">
  +    <component 
  +      shorthand="global-variables"
  +      class="org.apache.cocoon.components.modules.input.SitemapVariableHolder"
  +    />
  +  </role>
  +
  +  <!--
     <role name="org.apache.cocoon.components.language.generator.ServerPagesSelector"
          shorthand="server-pages"
          default-class="org.apache.cocoon.components.language.generator.GeneratorSelector"/>
  @@ -113,15 +159,10 @@
           shorthand="datasources"
           default-class="org.apache.avalon.excalibur.component.ExcaliburComponentSelector">
   	<hint shorthand="jdbc" class="org.apache.avalon.excalibur.datasource.ResourceLimitingJdbcDataSource"/>
  -    <!-- hint shorthand="jdbc" class="org.apache.avalon.excalibur.datasource.JdbcDataSource"/
-->
       <hint shorthand="j2ee" class="org.apache.avalon.excalibur.datasource.J2eeDataSource"/>
       <hint shorthand="informix" class="org.apache.avalon.excalibur.datasource.InformixDataSource"/>
     </role>
   
  -  <role name="org.apache.excalibur.xmlizer.XMLizer"
  -        shorthand="xmlizer"
  -        default-class="org.apache.excalibur.xmlizer.DefaultXMLizer"/>
  -
     <role name="org.apache.avalon.excalibur.monitor.Monitor"
           shorthand="monitor"
           default-class="org.apache.avalon.excalibur.monitor.ActiveMonitor">
  @@ -147,7 +188,6 @@
           shorthand="cache"
           default-class="org.apache.cocoon.caching.impl.CacheImpl"/>
   
  -  <!-- i18n components for resource bundle handling -->
     <role name="org.apache.cocoon.i18n.BundleFactory"
           shorthand="i18n-bundles"
           default-class="org.apache.cocoon.i18n.XMLResourceBundleFactory"/>
  @@ -156,7 +196,6 @@
           shorthand="continuations-manager"
           default-class="org.apache.cocoon.components.flow.ContinuationsManagerImpl" />
   
  -  <!-- input/output modules -->
     <role name="org.apache.cocoon.components.modules.input.InputModuleSelector"
           shorthand="input-modules"
           default-class="org.apache.avalon.excalibur.component.ExcaliburComponentSelector"/>
  @@ -165,13 +204,8 @@
           shorthand="output-modules"
           default-class="org.apache.avalon.excalibur.component.ExcaliburComponentSelector"/>
   
  -  <role name="org.apache.cocoon.components.modules.input.SitemapVariableHolder"
  -        shorthand="global-variables"
  -        default-class="org.apache.cocoon.components.modules.input.SitemapVariableHolder"/>
  -
  -  <!-- Storing data in the current request -->
     <role name="org.apache.cocoon.components.persistence.RequestDataStore"
           shorthand="request-data-store"
           default-class="org.apache.cocoon.components.persistence.RequestDataStoreImpl"/>
  -
  +  -->
   </role-list>
  
  
  

Mime
View raw message