portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From wea...@apache.org
Subject svn commit: r219966 - in /portals/jetspeed-2/trunk: components/portal/src/java/org/apache/jetspeed/engine/ portal-webapp/src/webapp/WEB-INF/assembly/ portal-webapp/src/webapp/WEB-INF/assembly/boot/
Date Wed, 20 Jul 2005 19:16:01 GMT
Author: weaver
Date: Wed Jul 20 12:15:58 2005
New Revision: 219966

URL: http://svn.apache.org/viewcvs?rev=219966&view=rev
Log:
JS2-308: http://issues.apache.org/jira/browse/JS2-308#action_12316269

Added:
    portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/
    portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/README   (with
props)
    portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/datasource.xml
      - copied, changed from r219891, portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/datasource.xml
Removed:
    portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/datasource.xml
Modified:
    portals/jetspeed-2/trunk/components/portal/src/java/org/apache/jetspeed/engine/SpringEngine.java
    portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/jetspeed-spring.xml

Modified: portals/jetspeed-2/trunk/components/portal/src/java/org/apache/jetspeed/engine/SpringEngine.java
URL: http://svn.apache.org/viewcvs/portals/jetspeed-2/trunk/components/portal/src/java/org/apache/jetspeed/engine/SpringEngine.java?rev=219966&r1=219965&r2=219966&view=diff
==============================================================================
--- portals/jetspeed-2/trunk/components/portal/src/java/org/apache/jetspeed/engine/SpringEngine.java
(original)
+++ portals/jetspeed-2/trunk/components/portal/src/java/org/apache/jetspeed/engine/SpringEngine.java
Wed Jul 20 12:15:58 2005
@@ -22,12 +22,14 @@
 
 import javax.naming.NamingException;
 import javax.servlet.ServletConfig;
+import javax.servlet.ServletContext;
 
 import org.apache.commons.configuration.Configuration;
 import org.apache.jetspeed.components.ComponentManager;
 import org.apache.jetspeed.components.SpringComponentManager;
 import org.apache.jetspeed.components.factorybeans.ServletConfigFactoryBean;
 import org.springframework.web.context.WebApplicationContext;
+import org.springframework.web.context.support.XmlWebApplicationContext;
 
 /**
  * <p>
@@ -106,7 +108,13 @@
             }          
         }
         
-        SpringComponentManager cm = new SpringComponentManager(configs, null);
+        XmlWebApplicationContext bootCtx = new XmlWebApplicationContext();
+        ServletContext servletContext = servletConfig.getServletContext();
+        bootCtx.setServletContext(servletContext);
+        bootCtx.setConfigLocations(new String[] {"/WEB-INF/assembly/boot/*.xml"});
+        bootCtx.refresh();
+        
+        SpringComponentManager cm = new SpringComponentManager(configs, bootCtx);
         servletConfig.getServletContext().setAttribute(WebApplicationContext.ROOT_WEB_APPLICATION_CONTEXT_ATTRIBUTE,
cm.getApplicationContext());
         
         return cm;

Added: portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/README
URL: http://svn.apache.org/viewcvs/portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/README?rev=219966&view=auto
==============================================================================
--- portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/README (added)
+++ portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/README Wed Jul
20 12:15:58 2005
@@ -0,0 +1,3 @@
+Any configurations in this driedtory will be used to create a "boot" application context
that 
+will be used as a parent Application context for the primary application context
+that is configured via the configurations under WEB-INF/assembly.
\ No newline at end of file

Propchange: portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/README
------------------------------------------------------------------------------
    svn:eol-style = native

Copied: portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/datasource.xml
(from r219891, portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/datasource.xml)
URL: http://svn.apache.org/viewcvs/portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/datasource.xml?p2=portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/datasource.xml&p1=portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/datasource.xml&r1=219891&r2=219966&rev=219966&view=diff
==============================================================================
--- portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/datasource.xml (original)
+++ portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/boot/datasource.xml
Wed Jul 20 12:15:58 2005
@@ -1,7 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd">
-<beans>	
-	
+<beans>		
   <!-- 
 	  Creates a JNDI-based datasource bean name JetspeedDS.
 	  The  jdbc-connection-descriptor jcd-alias property must
@@ -52,9 +51,5 @@
 	 - see: http://www.springframework.org/docs/reference/orm.html#d0e7571
 	-->
 	
-  <bean id="ojbConfigurer" class="org.springframework.orm.ojb.support.LocalOjbConfigurer"/>
-  
-  
-   
-	
+  <bean id="ojbConfigurer" class="org.springframework.orm.ojb.support.LocalOjbConfigurer"/>
   	
 </beans>

Modified: portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/jetspeed-spring.xml
URL: http://svn.apache.org/viewcvs/portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/jetspeed-spring.xml?rev=219966&r1=219965&r2=219966&view=diff
==============================================================================
--- portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/jetspeed-spring.xml
(original)
+++ portals/jetspeed-2/trunk/portal-webapp/src/webapp/WEB-INF/assembly/jetspeed-spring.xml
Wed Jul 20 12:15:58 2005
@@ -87,13 +87,8 @@
   </bean>
     
   <!-- Portlet Registry DAO-->
-  <bean id="portletRegistryImpl" class="org.apache.jetspeed.components.portletregistry.PersistenceBrokerPortletRegistry"
init-method="init"
-  	    depends-on="ojbConfigurer">
-        <!--
-            note: depends-on required due to hidden dep via OJB.properties:
-                  ConnectionFactoryClass=org.springframework.orm.ojb.support.LocalDataSourceConnectionFactory
-            see: datasource.xml and configured http://www.springframework.org/docs/reference/orm.html#d0e7571
-         -->
+  <bean id="portletRegistryImpl" class="org.apache.jetspeed.components.portletregistry.PersistenceBrokerPortletRegistry"
init-method="init" >
+
         <constructor-arg index="0"><value>META-INF/registry_repository.xml</value></constructor-arg>
         <constructor-arg index="1"><ref bean="portletFactory"/></constructor-arg>
   </bean>
@@ -288,12 +283,7 @@
   <bean id="java.util.prefs.PreferencesFactory" 
   	class="org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl"
   	name="prefsFactory" init-method="init"
-  	depends-on="ojbConfigurer">
-    <!--
-        note: depends-on required due to hidden dep via OJB.properties:
-              ConnectionFactoryClass=org.springframework.orm.ojb.support.LocalDataSourceConnectionFactory
-        see: datasource.xml and configured http://www.springframework.org/docs/reference/orm.html#d0e7571
-     -->
+  	>
   		<property name="prefsProvider"> 
 			<ref bean="prefsProvider"/>
 		</property>	



---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org


Mime
View raw message