Revision: 28381
Author:   jbloemendal
Date:     2011-05-27 12:07:44 +0200 (Fri, 27 May 2011)
Log Message:
-----------
CMS7-5270 Template Composer Integration into the Channel Manager 
- removed PageComposerBootstrapValve

Modified Paths:
--------------
    
hippo-cms7/site-toolkit/trunk/client-modules/page-composer/src/main/resources/org/hippoecm/hst/pagecomposer/SpringComponentManager-pagecomposer.xml
    
hippo-cms7/site-toolkit/trunk/demosuite/content/src/main/resources/hst-virtualhosts.xml

Removed Paths:
-------------
    
hippo-cms7/site-toolkit/trunk/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/container/PageComposerBootstrapValve.java
    
hippo-cms7/site-toolkit/trunk/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/dependencies/
    hippo-cms7/site-toolkit/trunk/client-modules/page-composer/src/test/

Deleted: 
hippo-cms7/site-toolkit/trunk/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/container/PageComposerBootstrapValve.java
===================================================================
--- 
hippo-cms7/site-toolkit/trunk/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/container/PageComposerBootstrapValve.java
    2011-05-27 08:29:40 UTC (rev 28380)
+++ 
hippo-cms7/site-toolkit/trunk/client-modules/page-composer/src/main/java/org/hippoecm/hst/pagecomposer/container/PageComposerBootstrapValve.java
    2011-05-27 10:07:44 UTC (rev 28381)
@@ -1,89 +0,0 @@
-/*
- *  Copyright 2010 Hippo.
- * 
- *  Licensed under the Apache License, Version 2.0 (the "License");
- *  you may not use this file except in compliance with the License.
- *  You may obtain a copy of the License at
- * 
- *       http://www.apache.org/licenses/LICENSE-2.0
- * 
- *  Unless required by applicable law or agreed to in writing, software
- *  distributed under the License is distributed on an "AS IS" BASIS,
- *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- *  See the License for the specific language governing permissions and
- *  limitations under the License.
- */
-package org.hippoecm.hst.pagecomposer.container;
-
-import java.io.IOException;
-import java.io.PrintWriter;
-import java.util.List;
-
-import javax.servlet.http.HttpServletResponse;
-import javax.servlet.http.HttpSession;
-
-import org.hippoecm.hst.configuration.hosting.Mount;
-import org.hippoecm.hst.core.ResourceLifecycleManagement;
-import org.hippoecm.hst.core.container.AbstractValve;
-import org.hippoecm.hst.core.container.ContainerConstants;
-import org.hippoecm.hst.core.container.ContainerException;
-import org.hippoecm.hst.core.container.ValveContext;
-import org.hippoecm.hst.core.linking.HstLinkCreator;
-import org.hippoecm.hst.core.request.HstRequestContext;
-
-/**
- * InitializationValve
- * 
- * @version $Id: InitializationValve.java 23030 2010-06-07 06:50:46Z adouma $
- */
-public class PageComposerBootstrapValve extends AbstractValve
-{
-    protected List<ResourceLifecycleManagement> resourceLifecycleManagements;
-
-    public void 
setResourceLifecycleManagements(List<ResourceLifecycleManagement> 
resourceLifecycleManagements) {
-        this.resourceLifecycleManagements = resourceLifecycleManagements;
-    }
-
-    @Override
-    public void invoke(ValveContext context) throws ContainerException
-    {
-        
-        HttpSession session = context.getServletRequest().getSession();
-        session.setAttribute(ContainerConstants.COMPOSERMODE_ATTR_NAME, 
"true");
-        
session.setAttribute(ContainerConstants.COMPOSERMODE_TEMPLATE_VIEW_ATTR_NAME, 
"true");
-        
-        HstRequestContext requestContext = 
(HstRequestContext)context.getRequestContext();
-        Mount mount = requestContext.getResolvedMount().getMount();
-
-        /*
-        *  get the preview URL. Note, that the 'composer' mount always needs a 
parent mount of type 'composermode'.
-        *  If either the parent is null, OR the parent is not of type 
'composermode', we cannot instantiate the composer tool
-        */
-        Mount parentMount = mount.getParent();
-        if (parentMount == null || !parentMount.isOfType("composermode")) {
-            try {
-                
context.getServletResponse().sendError(HttpServletResponse.SC_INTERNAL_SERVER_ERROR,
 "Page Composer Tool can only be started if the composer Mount is a descendant 
of the Mount of type 'composermode'.");
-            } catch (IOException e) {
-                e.printStackTrace();
-            }
-            return;
-        }
-
-        HstLinkCreator creator = requestContext.getHstLinkCreator();
-        try {
-            context.getServletResponse().setContentType("text/html");
-            PrintWriter writer = context.getServletResponse().getWriter();
-            writer.append("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01//EN\" 
\"http://www.w3.org/TR/html4/strict.dtd\";>");
-            writer.append("\n<html><head><meta http-equiv=\"Content-Type\" 
content=\"text/html;charset=utf-8\">");
-            writer.append("</head>");
-            writer.append("</html>");
-            writer.flush();
-            
-        } catch (IOException e) {
-            e.printStackTrace();
-        }
-        
-        // continue
-        context.invokeNext();
-    }
-}

Modified: 
hippo-cms7/site-toolkit/trunk/client-modules/page-composer/src/main/resources/org/hippoecm/hst/pagecomposer/SpringComponentManager-pagecomposer.xml
===================================================================
--- 
hippo-cms7/site-toolkit/trunk/client-modules/page-composer/src/main/resources/org/hippoecm/hst/pagecomposer/SpringComponentManager-pagecomposer.xml
 2011-05-27 08:29:40 UTC (rev 28380)
+++ 
hippo-cms7/site-toolkit/trunk/client-modules/page-composer/src/main/resources/org/hippoecm/hst/pagecomposer/SpringComponentManager-pagecomposer.xml
 2011-05-27 10:07:44 UTC (rev 28381)
@@ -79,8 +79,6 @@
   <bean id="jaxrsHstConfigServiceValve" 
class="org.hippoecm.hst.core.container.JaxrsRestServiceValve">
     <constructor-arg ref="jaxrsHstConfigService"/>
   </bean>
-  <bean id="composerBootstrap" parent="abstractValve"
-        
class="org.hippoecm.hst.pagecomposer.container.PageComposerBootstrapValve"/>
 
   <bean 
class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
     <property name="targetObject">
@@ -128,42 +126,6 @@
     <property name="targetMethod" value="put"/>
     <property name="arguments">
       <list>
-        <value>ComposerBootstrapPipeline</value>
-        <bean class="org.hippoecm.hst.core.container.HstSitePipeline">
-          <property name="preInvokingValves">
-            <list>
-              <ref bean="initializationValve"/>
-            </list>
-          </property>
-          <property name="invokingValves">
-            <list>
-              <ref bean="cmsSecurityValve"/>
-              <ref bean="subjectBasedSessionValve"/>
-              <ref bean="jcrSessionStatefulConcurrencyValve"/>
-              <ref bean="noCacheResponseHeadersValve"/>
-              <ref bean="composerBootstrap"/>
-            </list>
-          </property>
-          <property name="postInvokingValves">
-            <list>
-              <ref bean="cleanupValve"/>
-            </list>
-          </property>
-        </bean>
-      </list>
-    </property>
-  </bean>
-
-  <bean 
class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
-    <property name="targetObject">
-      <bean 
class="org.springframework.beans.factory.config.PropertyPathFactoryBean">
-        <property name="targetObject" 
ref="org.hippoecm.hst.core.container.Pipelines"/>
-        <property name="propertyPath" value="pipelines"/>
-      </bean>
-    </property>
-    <property name="targetMethod" value="put"/>
-    <property name="arguments">
-      <list>
         <value>ComposerPreviewPipeline</value>
         <bean class="org.hippoecm.hst.core.container.HstSitePipeline">
           <property name="preInvokingValves">

Modified: 
hippo-cms7/site-toolkit/trunk/demosuite/content/src/main/resources/hst-virtualhosts.xml
===================================================================
--- 
hippo-cms7/site-toolkit/trunk/demosuite/content/src/main/resources/hst-virtualhosts.xml
     2011-05-27 08:29:40 UTC (rev 28380)
+++ 
hippo-cms7/site-toolkit/trunk/demosuite/content/src/main/resources/hst-virtualhosts.xml
     2011-05-27 10:07:44 UTC (rev 28381)
@@ -382,26 +382,6 @@
               <sv:property sv:name="hst:sessionstateful" sv:type="Boolean">
                 <sv:value>true</sv:value>
               </sv:property>
-              <sv:node sv:name="composer">
-                <sv:property sv:name="jcr:primaryType" sv:type="Name">
-                  <sv:value>hst:mount</sv:value>
-                </sv:property>
-                <sv:property sv:name="hst:ismapped" sv:type="Boolean">
-                  <sv:value>false</sv:value>
-                </sv:property>
-                <sv:property sv:name="hst:namedpipeline" sv:type="String">
-                  <sv:value>ComposerBootstrapPipeline</sv:value>
-                </sv:property>
-                <sv:property sv:name="hst:showport" sv:type="Boolean">
-                  <sv:value>true</sv:value>
-                </sv:property>
-                <sv:property sv:name="hst:type" sv:type="String">
-                  <sv:value>composer</sv:value>
-                </sv:property>
-                <sv:property sv:name="hst:types" sv:type="String">
-                  <sv:value>preview</sv:value>
-                </sv:property>
-              </sv:node>
               <sv:node sv:name="_rp">
                 <sv:property sv:name="jcr:primaryType" sv:type="Name">
                   <sv:value>hst:mount</sv:value>

_______________________________________________
Hippocms-svn mailing list
[email protected]
http://lists.hippo.nl/mailman/listinfo/hippocms-svn

Reply via email to