JBoss Portal SVN: r6023 - in trunk: build/ide/intellij/idea60/modules and 16 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-01-17 17:16:04 -0500 (Wed, 17 Jan 2007)
New Revision: 6023
Added:
trunk/build/ide/intellij/idea60/modules/core-management/
trunk/build/ide/intellij/idea60/modules/core-management/core-management.iml
trunk/core-management/
trunk/core-management/build.bat
trunk/core-management/build.sh
trunk/core-management/build.xml
trunk/core-management/src/
trunk/core-management/src/main/
trunk/core-management/src/main/org/
trunk/core-management/src/main/org/jboss/
trunk/core-management/src/main/org/jboss/portal/
trunk/core-management/src/main/org/jboss/portal/core/
trunk/core-management/src/main/org/jboss/portal/core/management/
trunk/core-management/src/main/org/jboss/portal/core/management/Portal.java
trunk/core-management/src/main/org/jboss/portal/core/management/PortalImpl.java
trunk/core-management/src/main/org/jboss/portal/core/management/PortletDiscoveryService.java
trunk/core-management/src/main/org/jboss/portal/core/management/WSRPPortletManagement.java
trunk/core-management/src/main/org/jboss/portal/core/management/WSRPPortletManagementMBean.java
trunk/core-management/src/resources/
trunk/core-management/src/resources/portal-management-sar/
trunk/core-management/src/resources/portal-management-sar/META-INF/
trunk/core-management/src/resources/portal-management-sar/META-INF/jboss-service.xml
Removed:
trunk/core/src/main/org/jboss/portal/core/management/
Modified:
trunk/core/build.xml
trunk/core/src/resources/portal-core-sar/META-INF/jboss-service.xml
trunk/tools/etc/buildfragments/modules.ent
Log:
modulaized core management integration into core-management
Added: trunk/build/ide/intellij/idea60/modules/core-management/core-management.iml
===================================================================
--- trunk/build/ide/intellij/idea60/modules/core-management/core-management.iml (rev 0)
+++ trunk/build/ide/intellij/idea60/modules/core-management/core-management.iml 2007-01-17 22:16:04 UTC (rev 6023)
@@ -0,0 +1,37 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module version="4" relativePaths="true" type="JAVA_MODULE">
+ <component name="ModuleRootManager" />
+ <component name="NewModuleRootManager" inherit-compiler-output="true">
+ <exclude-output />
+ <content url="file://$MODULE_DIR$/../../../../../../core-management">
+ <sourceFolder url="file://$MODULE_DIR$/../../../../../../core-management/src/main" isTestSource="false" />
+ </content>
+ <orderEntry type="inheritedJdk" />
+ <orderEntry type="sourceFolder" forTests="false" />
+ <orderEntry type="module" module-name="core" />
+ <orderEntry type="module" module-name="portlet" />
+ <orderEntry type="module" module-name="common" />
+ <orderEntry type="module" module-name="jems" />
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/../../../../../../thirdparty/jbossas/core-libs/lib/jboss-system.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module-library">
+ <library>
+ <CLASSES>
+ <root url="jar://$MODULE_DIR$/../../../../../../thirdparty/jbossas/core-libs/lib/jboss-jmx.jar!/" />
+ </CLASSES>
+ <JAVADOC />
+ <SOURCES />
+ </library>
+ </orderEntry>
+ <orderEntry type="module" module-name="federation" />
+ <orderEntryProperties />
+ </component>
+</module>
+
Modified: trunk/core/build.xml
===================================================================
--- trunk/core/build.xml 2007-01-17 21:32:24 UTC (rev 6022)
+++ trunk/core/build.xml 2007-01-17 22:16:04 UTC (rev 6023)
@@ -506,13 +506,6 @@
<copy file="${build.lib}/jboss-portal-ha.sar" todir="${jboss.home}/server/${portal-ha.deploy.dir}"/>
</target>
- <target name="deploy-management"
- description="Deploy."
- depends="output">
- <require file="${jboss.home}/server/${portal.deploy.dir}"/>
- <copy file="${build.lib}/portal-management.war" todir="${jboss.home}/server/${portal.deploy.dir}"/>
- </target>
-
<!--
| Undeploy the application
-->
Modified: trunk/core/src/resources/portal-core-sar/META-INF/jboss-service.xml
===================================================================
--- trunk/core/src/resources/portal-core-sar/META-INF/jboss-service.xml 2007-01-17 21:32:24 UTC (rev 6022)
+++ trunk/core/src/resources/portal-core-sar/META-INF/jboss-service.xml 2007-01-17 22:16:04 UTC (rev 6023)
@@ -23,52 +23,7 @@
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
<server>
- <!-- Management -->
-
- <!-- Portlet discovery executed every 30 seconds -->
- <mbean code="org.jboss.varia.scheduler.Scheduler"
- name="portal:service=Management,type=Scheduler">
- <attribute name="SchedulableMBean">portal:service=Management,type=PortletDiscoveryManagement,name=Default</attribute>
- <attribute name="SchedulableMBeanMethod">processPortletDiscovery()</attribute>
- <attribute name="InitialStartDate">NOW</attribute>
- <attribute name="SchedulePeriod">30000</attribute>
- <attribute name="InitialRepetitions">-1</attribute>
- </mbean>
- <mbean
- code="org.jboss.portal.core.management.PortalImpl"
- name="portal.management:service=Management,type=Portal,name=Default"
- xmbean-dd=""
- xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
- <depends
- optional-attribute-name="InstanceContainer"
- proxy-type="attribute">portal:container=Instance</depends>
- <xmbean/>
- </mbean>
-
- <mbean
- code="org.jboss.portal.identity.management.Identity"
- name="portal.management:service=Management,type=Identity,name=Default"
- >
- <depends>portal:service=Module,type=IdentityServiceController</depends>
- <xmbean/>
- </mbean>
-
- <mbean
- code="org.jboss.portal.core.management.PortletDiscoveryService"
- name="portal:service=Management,type=PortletDiscoveryManagement,name=Default"
- xmbean-dd=""
- xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
- <depends
- optional-attribute-name="FederatingPortletInvoker"
- proxy-type="attribute">portal:service=PortletInvoker,type=Federating</depends>
- <depends
- optional-attribute-name="Interceptor"
- proxy-type="attribute">portal:service=Interceptor,type=Portlet,name=PortletContainerManagement</depends>
- <xmbean/>
- </mbean>
-
-
<!-- Server configuration service -->
<mbean
code="org.jboss.portal.server.config.ServerConfigService"
@@ -229,15 +184,7 @@
</mbean>
<!-- Instance stack -->
- <!-- Management MBean, can be removed if management is not used -->
<mbean
- code="org.jboss.portal.portlet.management.PortletContainerManagementInterceptorImpl"
- name="portal:service=Interceptor,type=Portlet,name=PortletContainerManagement"
- xmbean-dd=""
- xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
- <xmbean/>
- </mbean>
- <mbean
code="org.jboss.portal.core.model.instance.InstanceSecurityInterceptor"
name="portal:service=Interceptor,type=Portlet,name=InstanceSecurity"
xmbean-dd=""
@@ -266,7 +213,6 @@
xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
<xmbean/>
<depends-list optional-attribute-name="InterceptorNames">
- <depends-list-element>portal:service=Interceptor,type=Portlet,name=PortletContainerManagement</depends-list-element>
<depends-list-element>portal:service=Interceptor,type=Portlet,name=ConsumerCache</depends-list-element>
<depends-list-element>portal:service=Interceptor,type=Portlet,name=InstanceSecurity</depends-list-element>
<depends-list-element>portal:service=Interceptor,type=Portlet,name=PortalSessionSynchronization</depends-list-element>
Added: trunk/core-management/build.bat
===================================================================
--- trunk/core-management/build.bat (rev 0)
+++ trunk/core-management/build.bat 2007-01-17 22:16:04 UTC (rev 6023)
@@ -0,0 +1,54 @@
+@echo off
+rem
+rem Invokes a script of the same name in the 'tools' module.
+rem
+rem The 'tools' module is expected to be a peer directory of the directory
+rem in which this script lives.
+rem
+rem @author Jason Dillon <jason(a)planet57.com>
+rem
+
+rem $Id: build.bat 1015 2005-11-04 20:15:13Z mholzner $
+
+setlocal
+
+set PROGNAME=%~nx0
+set DIRNAME=%~dp0
+
+rem Legacy shell support
+if x%PROGNAME%==x set PROGNAME=build.bat
+if x%DIRNAME%==x set DIRNAME=.\
+
+set MODULE_ROOT=%DIRNAME%
+if x%TOOLS_ROOT%==x set TOOLS_ROOT=%DIRNAME%..\tools
+set TARGET=%TOOLS_ROOT%\bin\build.bat
+set ARGS=%*
+
+rem Start'er up yo
+goto main
+
+:debug
+if not x%DEBUG%==x echo %PROGNAME%: %*
+goto :EOF
+
+:main
+call :debug PROGNAME=%PROGNAME%
+call :debug DIRNAME=%DIRNAME%
+call :debug TOOLS_ROOT=%TOOLS_ROOT%
+call :debug TARGET=%TARGET%
+
+if exist %TARGET% call :call-script & goto :EOF
+rem else fail, we can not go on
+
+echo %PROGNAME%: *ERROR* The target executable does not exist:
+echo %PROGNAME%:
+echo %PROGNAME%: %TARGET%
+echo %PROGNAME%:
+echo %PROGNAME%: Please make sure you have checked out the 'tools' module
+echo %PROGNAME%: and make sure it is up to date.
+goto :EOF
+
+:call-script
+call :debug Executing %TARGET% %ARGS%
+call %TARGET% %ARGS%
+goto :EOF
Property changes on: trunk/core-management/build.bat
___________________________________________________________________
Name: svn:executable
+ *
Added: trunk/core-management/build.sh
===================================================================
--- trunk/core-management/build.sh (rev 0)
+++ trunk/core-management/build.sh 2007-01-17 22:16:04 UTC (rev 6023)
@@ -0,0 +1,49 @@
+#!/bin/sh
+##
+## Invokes a script of the same name in the 'tools' module.
+##
+## The 'tools' module is expected to be a peer directory of the directory
+## in which this script lives.
+##
+## @author Jason Dillon <jason(a)planet57.com>
+##
+
+# $Id: build.sh 1015 2005-11-04 20:15:13Z mholzner $
+
+PROGNAME=`basename $0`
+DIRNAME=`dirname $0`
+
+# Buss it yo
+main() {
+ if [ "x$TOOLS_ROOT" = "x" ]; then
+ TOOLS_ROOT=`cd $DIRNAME/../tools && pwd`
+ fi
+
+ MODULE_ROOT=`cd $DIRNAME; pwd`
+ export TOOLS_ROOT MODULE_ROOT DEBUG TRACE
+
+ # Where is the target script?
+ target="$TOOLS_ROOT/bin/$PROGNAME"
+ if [ ! -f "$target" ]; then
+ echo "${PROGNAME}: *ERROR* The target executable does not exist:"
+ echo "${PROGNAME}:"
+ echo "${PROGNAME}: $target"
+ echo "${PROGNAME}:"
+ echo "${PROGNAME}: Please make sure you have checked out the 'tools' module"
+ echo "${PROGNAME}: and make sure it is up to date."
+ exit 2
+ fi
+
+ # Get busy yo!
+ if [ "x$DEBUG" != "x" ]; then
+ echo "${PROGNAME}: Executing: /bin/sh $target $@"
+ fi
+ if [ "x$TRACE" = "x" ]; then
+ exec /bin/sh $target "$@"
+ else
+ exec /bin/sh -x $target "$@"
+ fi
+}
+
+# Lets get ready to rumble!
+main "$@"
Property changes on: trunk/core-management/build.sh
___________________________________________________________________
Name: svn:executable
+ *
Added: trunk/core-management/build.xml
===================================================================
--- trunk/core-management/build.xml (rev 0)
+++ trunk/core-management/build.xml 2007-01-17 22:16:04 UTC (rev 6023)
@@ -0,0 +1,325 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ JBoss, a division of Red Hat ~
+ ~ Copyright 2006, Red Hat Middleware, LLC, and individual ~
+ ~ contributors as indicated by the @authors tag. See the ~
+ ~ copyright.txt in the distribution for a full listing of ~
+ ~ individual contributors. ~
+ ~ ~
+ ~ This is free software; you can redistribute it and/or modify it ~
+ ~ under the terms of the GNU Lesser General Public License as ~
+ ~ published by the Free Software Foundation; either version 2.1 of ~
+ ~ the License, or (at your option) any later version. ~
+ ~ ~
+ ~ This software is distributed in the hope that it will be useful, ~
+ ~ but WITHOUT ANY WARRANTY; without even the implied warranty of ~
+ ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ~
+ ~ Lesser General Public License for more details. ~
+ ~ ~
+ ~ You should have received a copy of the GNU Lesser General Public ~
+ ~ License along with this software; if not, write to the Free ~
+ ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA ~
+ ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+
+<!DOCTYPE project [
+ <!ENTITY libraries SYSTEM "../thirdparty/libraries.ent">
+ <!ENTITY buildmagic SYSTEM "../tools/etc/buildfragments/buildmagic.ent">
+ <!ENTITY tools SYSTEM "../tools/etc/buildfragments/tools.ent">
+ <!ENTITY modules SYSTEM "../tools/etc/buildfragments/modules.ent">
+ <!ENTITY defaults SYSTEM "../tools/etc/buildfragments/defaults.ent">
+ <!ENTITY targets SYSTEM "../tools/etc/buildfragments/targets.ent">
+ ]>
+
+<!--+======================================================================+-->
+<!--| JBoss Portal (The OpenSource Portal) Build File |-->
+<!--| |-->
+<!--| Distributable under LGPL license. |-->
+<!--| See terms of license at http://www.gnu.org. |-->
+<!--| |-->
+<!--| This file has been designed to work with the 'tools' module and |-->
+<!--| Buildmagic extentions. |-->
+<!--+======================================================================+-->
+
+<project default="main" name="JBoss Portal">
+
+ <!--+====================================================================+-->
+ <!--| Setup |-->
+ <!--| |-->
+ <!--| Include the common build elements. |-->
+ <!--| |-->
+ <!--| This defines several different targets, properties and paths. |-->
+ <!--| It also sets up the basic extention tasks amoung other things. |-->
+ <!--+====================================================================+-->
+
+ &buildmagic;
+ &modules;
+ &defaults;
+ &tools;
+ &targets;
+
+ <!-- ================================================================== -->
+ <!-- Initialization -->
+ <!-- ================================================================== -->
+
+ <!--
+ | Initialize the build system. Must depend on '_buildmagic:init'.
+ | Other targets should depend on 'init' or things will mysteriously fail.
+ -->
+
+ <target name="init" unless="init.disable" depends="_buildmagic:init">
+ </target>
+
+ <!--+====================================================================+-->
+ <!--| Configuration |-->
+ <!--| |-->
+ <!--| This target is invoked by the Buildmagic initialization logic |-->
+ <!--| and should contain module specific configuration elements. |-->
+ <!--+====================================================================+-->
+
+ <target name="configure" unless="configure.disable">
+
+ <!-- Configure some properties -->
+ <property name="jboss-junit-configuration" value=""/>
+ <property name="junit.formatter.usefile" value="true"/>
+
+ <!-- Configure thirdparty libraries -->
+ &libraries;
+
+ <path id="library.classpath">
+ <path refid="jboss.jbossxb.classpath"/>
+ <path refid="jboss.cache.classpath"/>
+ <path refid="jbossas/core.libs.classpath"/>
+ <path refid="hibernate.hibernate.classpath"/>
+ <path refid="apache.ant.classpath"/>
+ <path refid="apache.myfaces.classpath"/>
+ <path refid="apache.tomahawk.classpath"/>
+ <path refid="apache.log4j.classpath"/>
+ <path refid="junit.junit.classpath"/>
+ <path refid="sun.servlet.classpath"/>
+ <path refid="jakarta.cactus.classpath"/>
+ <path refid="apache.fileupload.classpath"/>
+ <path refid="jakarta.io.classpath"/>
+ <path refid="oswego.concurrent.classpath"/>
+ <path refid="sun.javamail.classpath"/>
+ <path refid="jwebunit.jwebunit.classpath"/>
+ <path refid="dbunit.dbunit.classpath"/>
+ <path refid="sun.jaf.classpath"/>
+ <path refid="portals.bridges.classpath"/>
+ <path refid="beanshell.beanshell.classpath"/>
+ <path refid="facelets.facelets.classpath"/>
+ <path refid="dom4j.dom4j.classpath"/>
+ <path refid="jboss.aop.classpath"/>
+ <path refid="trove.trove.classpath"/>
+ <path refid="qdox.qdox.classpath"/>
+ <pathelement location="${source.etc}/sun-jsf/jsf-example.jar"/>
+ <!-- jbpm integration -->
+ <path refid="jbpm.jbpm.classpath"/>
+ </path>
+
+ <!-- Configure modules -->
+ <call target="configure-modules"/>
+ <path id="dependentmodule.classpath">
+ <path refid="jboss.portal-common.classpath"/>
+ <path refid="jboss.portal-server.classpath"/>
+ <path refid="jboss.portal-portlet.classpath"/>
+ <path refid="jboss.portal-jems.classpath"/>
+ <path refid="jboss.portal-federation.classpath"/>
+ <path refid="jboss.portal-identity.classpath"/>
+ <path refid="jboss.portal-security.classpath"/>
+ <path refid="jboss.portal-test.classpath"/>
+ <path refid="jboss.portal-core.classpath"/>
+ </path>
+
+ <!--+=======================================+-->
+ <!--| Override any default properties here. |-->
+ <!--+=======================================+-->
+
+ <!-- Configure defaults & build tools -->
+ <call target="configure-defaults"/>
+ <call target="configure-tools"/>
+ <call target="configure-explode"/>
+
+ <!--+=======================================+-->
+ <!--| Define module specific elements here. |-->
+ <!--+=======================================+-->
+ <property name="javadoc.private" value="true"/>
+ <property name="javadoc.protected" value="false"/>
+
+ <taskdef name="explode"
+ classname="org.jboss.portal.common.ant.Explode"
+ classpathref="explode.task.classpath"/>
+ <taskdef name="implode"
+ classname="org.jboss.portal.common.ant.Implode"
+ classpathref="explode.task.classpath"/>
+
+ </target>
+
+ <target name="configure-explode">
+ <path id="explode.task.classpath">
+ <pathelement location="${project.tools}/lib/explode.jar"/>
+ <path refid="apache.ant.classpath"/>
+ </path>
+ <taskdef
+ name="explode"
+ classname="org.jboss.portal.common.ant.Explode"
+ classpathref="explode.task.classpath"/>
+ </target>
+
+ <!--+====================================================================+-->
+ <!--| Compile |-->
+ <!--| |-->
+ <!--| This target should depend on other compile-* targets for each |-->
+ <!--| different type of compile that needs to be performed, short of |-->
+ <!--| documentation compiles. |-->
+ <!--+====================================================================+-->
+
+ <target name="compile"
+ description="Compile all source files."
+ depends="_default:compile-classes,
+ _default:compile-etc,
+ _default:compile-resources">
+ <!-- Add module specific elements here. -->
+ </target>
+
+ <!--+====================================================================+-->
+ <!--| Generate Output |-->
+ <!--| |-->
+ <!--| Generates the target output for this module. Target output is |-->
+ <!--| the output which is ment to be released or used by external |-->
+ <!--| modules. |-->
+ <!--+====================================================================+-->
+
+ <target name="artifacts"
+ description="Generate all target output."
+ depends="compile">
+
+ <mkdir dir="${build.lib}"/>
+
+ <!-- portal-core-management-lib.jar -->
+ <jar jarfile="${build.lib}/portal-core-management-lib.jar">
+ <fileset dir="${build.classes}">
+ </fileset>
+ </jar>
+
+ <!-- portal-management.sar -->
+ <copy todir="${build.resources}/portal-management">
+ <fileset dir="${build.resources}/portal-management-sar"/>
+ </copy>
+ <copy todir="${build.resources}/portal-management/lib">
+ <fileset dir="${build.lib}" includes="portal-core-management-lib.jar"/>
+ </copy>
+
+ </target>
+
+ <!-- Build the jboss-portal-ha.sar -->
+ <target name="output-ha" depends="artifacts">
+ <copy todir="${build.resources}/portal-management-ha.sar">
+ <fileset dir="${build.resources}/portal-management" excludes="**/*.xml"/>
+ </copy>
+
+ <copy todir="${build.resources}/portal-management-ha.sar">
+ <filterset>
+ <filtersfile file="../build/etc/clustered.properties"/>
+ </filterset>
+ <fileset dir="${build.resources}/portal-management" includes="**/*.xml"/>
+ </copy>
+
+ <implode
+ dir="${build.resources}/portal-management-ha.sar"
+ tofile="${build.lib}/portal-management-ha.sar"/>
+ </target>
+
+ <!-- Build the jboss-portal.sar -->
+ <target name="output" depends="artifacts">
+ <!-- Build configurations -->
+ <copy todir="${build.resources}/portal-management.sar">
+ <fileset dir="${build.resources}/portal-management" excludes="**/*.xml"/>
+ </copy>
+
+ <copy todir="${build.resources}/portal-management.sar">
+ <filterset>
+ <filtersfile file="../build/etc/single.properties"/>
+ </filterset>
+ <fileset dir="${build.resources}/portal-management" includes="**/*.xml"/>
+ </copy>
+ <!-- Build archives -->
+ <implode
+ dir="${build.resources}/portal-management.sar"
+ tofile="${build.lib}/portal-management.sar"/>
+ </target>
+
+ <!-- create artifacts for running the portlet tests (except TCK) target output should have already been executed -->
+ <target name="package-tests" depends="init">
+ </target>
+
+ <!-- ================================================================== -->
+ <!-- Cleaning -->
+ <!-- ================================================================== -->
+
+ <!-- Clean up all build output -->
+ <target name="clean" depends="_default:clean">
+ <!-- Add module specific elements here. -->
+ </target>
+
+ <!--+====================================================================+-->
+ <!--| Documents |-->
+ <!--| |-->
+ <!--| Generate all documentation for this module. |-->
+ <!--+====================================================================+-->
+
+ <target name="docs" depends="_default:docs">
+ <!-- Add module specific elements here. -->
+ </target>
+
+ <!-- ================================================================== -->
+ <!-- Misc. -->
+ <!-- ================================================================== -->
+
+ <target name="main" depends="most"/>
+ <target name="all" depends="_default:all"/>
+ <target name="most" depends="_default:most"/>
+ <target name="help" depends="_default:help"/>
+
+ <!-- ================================================================== -->
+ <!-- Deployment -->
+ <!-- ================================================================== -->
+
+ <!--
+ | Deploy the application
+ -->
+
+ <target name="deploy"
+ description="Deploy."
+ depends="output">
+ <require file="${jboss.home}/server/${portal.deploy.dir}"/>
+ <copy file="${build.lib}/portal-management.sar" todir="${jboss.home}/server/${portal.deploy.dir}" overwrite="true"/>
+ </target>
+
+ <target name="deploy-ha"
+ description="Deploy high availability."
+ depends="output-ha">
+ <require file="${jboss.home}/server/${portal-ha.deploy.dir}"/>
+ <copy file="${build.lib}/portal-management-ha.sar" todir="${jboss.home}/server/${portal-ha.deploy.dir}"/>
+ </target>
+
+ <!--
+ | Undeploy the application
+ -->
+ <target name="undeploy"
+ description="Undeploy."
+ depends="init">
+ <require file="${jboss.home}/server/${portal.deploy.dir}"/>
+ <delete file="${jboss.home}/server/${portal.deploy.dir}/portal-management.sar"/>
+ </target>
+
+ <target name="undeploy-ha"
+ description="Undeploy."
+ depends="init">
+ <require file="${jboss.home}/server/${portal-ha.deploy.dir}"/>
+ <delete file="${jboss.home}/server/${portal-ha.deploy.dir}/portal-management-ha.sar"/>
+ </target>
+
+ <target name="tests" depends="init, _buildmagic:configure:deployment">
+ </target>
+</project>
Added: trunk/core-management/src/main/org/jboss/portal/core/management/Portal.java
===================================================================
--- trunk/core-management/src/main/org/jboss/portal/core/management/Portal.java (rev 0)
+++ trunk/core-management/src/main/org/jboss/portal/core/management/Portal.java 2007-01-17 22:16:04 UTC (rev 6023)
@@ -0,0 +1,32 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.core.management;
+
+/**
+ * @author <a href="mailto:theute@jboss.org">Thomas Heute</a>
+ * @version $Revision$
+ */
+public interface Portal {
+
+ public int getNbInstances();
+}
Added: trunk/core-management/src/main/org/jboss/portal/core/management/PortalImpl.java
===================================================================
--- trunk/core-management/src/main/org/jboss/portal/core/management/PortalImpl.java (rev 0)
+++ trunk/core-management/src/main/org/jboss/portal/core/management/PortalImpl.java 2007-01-17 22:16:04 UTC (rev 6023)
@@ -0,0 +1,47 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.core.management;
+
+import org.jboss.portal.core.management.Portal;
+import org.jboss.portal.core.model.instance.InstanceContainer;
+import org.jboss.portal.jems.as.system.AbstractJBossService;
+
+/**
+ * @author <a href="mailto:theute@jboss.org">Thomas Heute</a>
+ * @version $Revision$
+ */
+public class PortalImpl extends AbstractJBossService implements Portal {
+
+ private InstanceContainer instanceContainer;
+
+ public int getNbInstances()
+ {
+ return instanceContainer.getDefinitions().size();
+ }
+
+ public void setInstanceContainer(InstanceContainer instanceContainer)
+ {
+ this.instanceContainer = instanceContainer;
+ }
+
+}
Added: trunk/core-management/src/main/org/jboss/portal/core/management/PortletDiscoveryService.java
===================================================================
--- trunk/core-management/src/main/org/jboss/portal/core/management/PortletDiscoveryService.java (rev 0)
+++ trunk/core-management/src/main/org/jboss/portal/core/management/PortletDiscoveryService.java 2007-01-17 22:16:04 UTC (rev 6023)
@@ -0,0 +1,147 @@
+package org.jboss.portal.core.management;
+
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Map;
+
+import javax.management.ObjectName;
+
+import org.jboss.portal.federation.FederatedPortletInvoker;
+import org.jboss.portal.federation.FederatingPortletInvoker;
+import org.jboss.portal.portlet.Portlet;
+import org.jboss.portal.portlet.management.LocalPortletManagement;
+import org.jboss.portal.portlet.management.PortletContainerManagementInterceptor;
+import org.jboss.system.ServiceMBeanSupport;
+
+public class PortletDiscoveryService extends ServiceMBeanSupport
+{
+ public static final String WSRP_JMX_PREFIX = "portal.management:service=Management,type=WSRPPorlet,name=";
+ public static final String LOCAL_JMX_PREFIX = "portal.management:service=Management,type=LocalPortlet,name=";
+
+ private PortletContainerManagementInterceptor interceptor;
+
+ private FederatingPortletInvoker federatingPortletInvoker;
+
+ private Map registeredPortlets = new HashMap();
+
+ public void start()
+ {
+ try
+ {
+ processPortletDiscovery();
+ }
+ catch (Exception e)
+ {
+ e.printStackTrace();
+ }
+ }
+
+ public void stop()
+ {
+ Iterator it = registeredPortlets.values().iterator();
+ while (it.hasNext())
+ {
+ ObjectName objectName = (ObjectName)it.next();
+ try
+ {
+ getServer().unregisterMBean(objectName);
+ }
+ catch (Exception e)
+ {
+ e.printStackTrace();
+ }
+ }
+ if (registeredPortlets.size() != 0)
+ {
+ log.error("Unable to remove all the Portlet management MBeans");
+ }
+ }
+
+ public FederatingPortletInvoker getFederatingPortletInvoker()
+ {
+ return federatingPortletInvoker;
+ }
+
+ public void setFederatingPortletInvoker(FederatingPortletInvoker federatingPortletInvoker)
+ {
+ this.federatingPortletInvoker = federatingPortletInvoker;
+ }
+
+ public void setInterceptor(PortletContainerManagementInterceptor interceptor)
+ {
+ this.interceptor = interceptor;
+ }
+
+ public void processPortletDiscovery() throws Exception
+ {
+ Collection federatedInvokers = federatingPortletInvoker.getFederatedInvokers();
+ Iterator it = federatedInvokers.iterator();
+ while (it.hasNext())
+ {
+ FederatedPortletInvoker federatedPortletInvoker = (FederatedPortletInvoker) it.next();
+ if (federatedPortletInvoker.getId().equals("local"))
+ {
+ registerPortlets(federatedPortletInvoker.getPortlets(), false);
+ }
+ else
+ {
+ registerPortlets(federatedPortletInvoker.getPortlets(), true);
+ }
+ }
+ }
+
+ private void registerPortlets(Collection portlets, boolean wsrp)
+ {
+ Iterator it = portlets.iterator();
+ while (it.hasNext())
+ {
+ Portlet portlet = (Portlet) it.next();
+ String portletId = portlet.getContext().getId();
+ boolean used = interceptor.getPortletInfo(portletId).isUsed();
+ if ((!registeredPortlets.containsKey(portletId))&&(used))
+ {
+ try
+ {
+ ObjectName objectName = createManagementMBean(portlet, wsrp);
+ registeredPortlets.put(portletId, objectName);
+ }
+ catch (Exception e)
+ {
+ e.printStackTrace();
+ }
+ }
+ }
+ }
+
+ private ObjectName createManagementMBean(Portlet portlet, boolean wsrp) throws Exception
+ {
+ Object management = null;
+ if (wsrp)
+ {
+ management = new WSRPPortletManagement(portlet, interceptor);
+ }
+ else
+ {
+ management = new LocalPortletManagement(portlet, interceptor);
+ }
+ ObjectName objectName = new ObjectName(getMBeanName(portlet, wsrp));
+ getServer().registerMBean(management, objectName);
+ log.debug("Registered Management MBean for: " + portlet.getContext().getId());
+ return objectName;
+ }
+
+ private String getMBeanName(Portlet portlet, boolean wsrp)
+ {
+ String id = portlet.getContext().getId();
+ if (wsrp)
+ {
+ return WSRP_JMX_PREFIX + id;
+ }
+ else
+ {
+ return LOCAL_JMX_PREFIX + id;
+ }
+ }
+
+}
Added: trunk/core-management/src/main/org/jboss/portal/core/management/WSRPPortletManagement.java
===================================================================
--- trunk/core-management/src/main/org/jboss/portal/core/management/WSRPPortletManagement.java (rev 0)
+++ trunk/core-management/src/main/org/jboss/portal/core/management/WSRPPortletManagement.java 2007-01-17 22:16:04 UTC (rev 6023)
@@ -0,0 +1,88 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.core.management;
+
+import org.jboss.portal.portlet.Portlet;
+import org.jboss.portal.portlet.management.PortletContainerManagementInterceptor;
+
+/**
+ * @author <a href="mailto:theute@jboss.org">Thomas Heute</a>
+ * @version $Revision$
+ */
+public class WSRPPortletManagement implements WSRPPortletManagementMBean
+{
+ private Portlet portlet;
+
+ private PortletContainerManagementInterceptor interceptor;
+
+ public WSRPPortletManagement(Portlet portlet, PortletContainerManagementInterceptor interceptor)
+ {
+ this.portlet = portlet;
+ this.interceptor = interceptor;
+ }
+
+ public String getId()
+ {
+ return portlet.getContext().getId();
+ }
+
+ public float getAverageRenderTime()
+ {
+ return interceptor.getPortletInfo(getId()).getAverageRenderTime();
+ }
+
+ public float getAverageActionTime()
+ {
+ return interceptor.getPortletInfo(getId()).getAverageActionTime();
+ }
+
+ public long getMaxRenderTime()
+ {
+ return interceptor.getPortletInfo(getId()).getMaxRenderTime();
+ }
+
+ public long getMaxActionTime()
+ {
+ return interceptor.getPortletInfo(getId()).getMaxActionTime();
+ }
+
+ public long getRenderRequestCount()
+ {
+ return interceptor.getPortletInfo(getId()).getRenderRequestCount();
+ }
+
+ public long getActionRequestCount()
+ {
+ return interceptor.getPortletInfo(getId()).getActionRequestCount();
+ }
+
+ public long getActionErrorCount()
+ {
+ return interceptor.getPortletInfo(getId()).getActionErrorCount();
+ }
+
+ public long getRenderErrorCount()
+ {
+ return interceptor.getPortletInfo(getId()).getRenderErrorCount();
+ }
+}
Added: trunk/core-management/src/main/org/jboss/portal/core/management/WSRPPortletManagementMBean.java
===================================================================
--- trunk/core-management/src/main/org/jboss/portal/core/management/WSRPPortletManagementMBean.java (rev 0)
+++ trunk/core-management/src/main/org/jboss/portal/core/management/WSRPPortletManagementMBean.java 2007-01-17 22:16:04 UTC (rev 6023)
@@ -0,0 +1,46 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.core.management;
+
+/**
+ * @author <a href="mailto:theute@jboss.org">Thomas Heute</a>
+ * @version $Revision$
+ */
+public interface WSRPPortletManagementMBean
+{
+ public float getAverageRenderTime();
+
+ public float getAverageActionTime();
+
+ public long getMaxRenderTime();
+
+ public long getMaxActionTime();
+
+ public long getRenderRequestCount();
+
+ public long getActionRequestCount();
+
+ public long getActionErrorCount();
+
+ public long getRenderErrorCount();
+}
Added: trunk/core-management/src/resources/portal-management-sar/META-INF/jboss-service.xml
===================================================================
--- trunk/core-management/src/resources/portal-management-sar/META-INF/jboss-service.xml (rev 0)
+++ trunk/core-management/src/resources/portal-management-sar/META-INF/jboss-service.xml 2007-01-17 22:16:04 UTC (rev 6023)
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ ~ JBoss, a division of Red Hat ~
+ ~ Copyright 2006, Red Hat Middleware, LLC, and individual ~
+ ~ contributors as indicated by the @authors tag. See the ~
+ ~ copyright.txt in the distribution for a full listing of ~
+ ~ individual contributors. ~
+ ~ ~
+ ~ This is free software; you can redistribute it and/or modify it ~
+ ~ under the terms of the GNU Lesser General Public License as ~
+ ~ published by the Free Software Foundation; either version 2.1 of ~
+ ~ the License, or (at your option) any later version. ~
+ ~ ~
+ ~ This software is distributed in the hope that it will be useful, ~
+ ~ but WITHOUT ANY WARRANTY; without even the implied warranty of ~
+ ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ~
+ ~ Lesser General Public License for more details. ~
+ ~ ~
+ ~ You should have received a copy of the GNU Lesser General Public ~
+ ~ License along with this software; if not, write to the Free ~
+ ~ Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA ~
+ ~ 02110-1301 USA, or see the FSF site: http://www.fsf.org. ~
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
+
+<server>
+
+ <!-- Portlet discovery executed every 30 seconds -->
+ <mbean
+ code="org.jboss.varia.scheduler.Scheduler"
+ name="portal:service=Management,type=Scheduler">
+ <attribute name="SchedulableMBean">portal:service=Management,type=PortletDiscoveryManagement,name=Default</attribute>
+ <attribute name="SchedulableMBeanMethod">processPortletDiscovery()</attribute>
+ <attribute name="InitialStartDate">NOW</attribute>
+ <attribute name="SchedulePeriod">30000</attribute>
+ <attribute name="InitialRepetitions">-1</attribute>
+ </mbean>
+
+ <mbean
+ code="org.jboss.portal.core.management.PortalImpl"
+ name="portal.management:service=Management,type=Portal,name=Default"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
+ <depends
+ optional-attribute-name="InstanceContainer"
+ proxy-type="attribute">portal:container=Instance</depends>
+ <xmbean/>
+ </mbean>
+
+ <mbean
+ code="org.jboss.portal.identity.management.Identity"
+ name="portal.management:service=Management,type=Identity,name=Default">
+ <depends>portal:service=Module,type=IdentityServiceController</depends>
+ <xmbean/>
+ </mbean>
+
+ <mbean
+ code="org.jboss.portal.core.management.PortletDiscoveryService"
+ name="portal:service=Management,type=PortletDiscoveryManagement,name=Default"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
+ <depends
+ optional-attribute-name="FederatingPortletInvoker"
+ proxy-type="attribute">portal:service=PortletInvoker,type=Federating</depends>
+ <depends
+ optional-attribute-name="Interceptor"
+ proxy-type="attribute">portal:service=Interceptor,type=Portlet,name=PortletContainerManagement</depends>
+ <xmbean/>
+ </mbean>
+
+ <mbean
+ code="org.jboss.portal.portlet.management.PortletContainerManagementInterceptorImpl"
+ name="portal:service=Interceptor,type=Portlet,name=PortletContainerManagement"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
+ <xmbean/>
+ </mbean>
+ <mbean
+ code="org.jboss.portal.server.impl.invocation.JBossInterceptorRegistration"
+ name="portal:service=InterceptorRegistration,type=Portlet,name=PortletContainerManagement"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
+ <xmbean/>
+ <depends
+ optional-attribute-name="StackFactory">portal:service=InterceptorStackFactory,type=Instance</depends>
+ <depends
+ optional-attribute-name="InterceptorName">portal:service=Interceptor,type=Portlet,name=PortletContainerManagement</depends>
+ </mbean>
+</server>
Modified: trunk/tools/etc/buildfragments/modules.ent
===================================================================
--- trunk/tools/etc/buildfragments/modules.ent 2007-01-17 21:32:24 UTC (rev 6022)
+++ trunk/tools/etc/buildfragments/modules.ent 2007-01-17 22:16:04 UTC (rev 6023)
@@ -99,6 +99,13 @@
<pathelement path="${jboss.portal-core-cms.lib}/portal-core-cms-lib.jar"/>
</path>
+ <!-- core-management -->
+ <property name="jboss.portal-core-management.root" value="${project.root}/core-management/output"/>
+ <property name="jboss.portal-core-management.lib" value="${jboss.portal-core-management.root}/lib"/>
+ <path id="jboss.portal-core-management.classpath">
+ <pathelement path="${jboss.portal-core-management.lib}/portal-core-management-lib.jar"/>
+ </path>
+
<!-- theme -->
<property name="jboss.portal-theme.root" value="${project.root}/theme/output"/>
<property name="jboss.portal-theme.lib" value="${jboss.portal-theme.root}/lib"/>
17 years, 5 months
JBoss Portal SVN: r6022 - in trunk: core/src/main/org/jboss/portal/core/controller/classic and 6 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-01-17 16:32:24 -0500 (Wed, 17 Jan 2007)
New Revision: 6022
Added:
trunk/server/src/main/org/jboss/portal/test/server/request/
trunk/server/src/main/org/jboss/portal/test/server/request/URLContextTestCase.java
Modified:
trunk/core/src/main/org/jboss/portal/core/aspects/controller/PageCustomizerInterceptor.java
trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicController.java
trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicResponseHandler.java
trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletInvocationFactory.java
trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletResponseHandler.java
trunk/core/src/main/org/jboss/portal/core/model/portal/command/RenderPortletWindowCommand.java
trunk/server/build.xml
trunk/server/src/main/org/jboss/portal/server/request/URLContext.java
Log:
- added URLContext test cases
- on the tab logout URL, do not use the authenticated servlet
Modified: trunk/core/src/main/org/jboss/portal/core/aspects/controller/PageCustomizerInterceptor.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/aspects/controller/PageCustomizerInterceptor.java 2007-01-17 20:54:46 UTC (rev 6021)
+++ trunk/core/src/main/org/jboss/portal/core/aspects/controller/PageCustomizerInterceptor.java 2007-01-17 21:32:24 UTC (rev 6022)
@@ -157,7 +157,7 @@
if (controllerCtx.getServerInvocation().getServerContext().getClientRequest().getRemoteUser() == null)
{
URLContext ctx = controllerCtx.getServerInvocation().getServerContext().getURLContext();
- ctx = URLContext.newInstance(ctx.getSecure(), true);
+ ctx = URLContext.newInstance(ctx.isSecure(), true);
String loginURL = controllerCtx.renderURL(cc, ctx, null);
sb.append("<a href=\"").append(loginURL).append("\">Login</a>");
}
@@ -253,7 +253,8 @@
}
SignOutCommand cmd = new SignOutCommand();
- String logoutURL = controllerCtx.renderURL(cmd, null, null);
+ URLContext urlContext = controllerCtx.getServerInvocation().getServerContext().getURLContext();
+ String logoutURL = controllerCtx.renderURL(cmd, urlContext.asNonAuthenticated(), null);
//
if (user != null)
Modified: trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicController.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicController.java 2007-01-17 20:54:46 UTC (rev 6021)
+++ trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicController.java 2007-01-17 21:32:24 UTC (rev 6022)
@@ -134,7 +134,7 @@
}
else
{
- urlContext = URLContext.newInstance(urlContext.getSecure(), true);
+ urlContext = URLContext.newInstance(urlContext.isSecure(), true);
ServerURL serverURL = getURLFactory().doMapping(invocation, cmd);
String url = invocation.getResponse().renderURL(serverURL, urlContext, null);
AbstractResponseHandler.sendRedirect(invocation, url);
@@ -200,8 +200,8 @@
}
else
{
- boolean currentSecure = currentURLCtx.getSecure();
- if (nextURLCtx != null && nextURLCtx.getSecure() && !currentSecure)
+ boolean currentSecure = currentURLCtx.isSecure();
+ if (nextURLCtx != null && nextURLCtx.isSecure() && !currentSecure)
{
return true;
}
Modified: trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicResponseHandler.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicResponseHandler.java 2007-01-17 20:54:46 UTC (rev 6021)
+++ trunk/core/src/main/org/jboss/portal/core/controller/classic/ClassicResponseHandler.java 2007-01-17 21:32:24 UTC (rev 6022)
@@ -74,9 +74,8 @@
PortalObjectContainer portalObjectContainer = ctx.getController().getPortalObjectContainer();
Portal portal = (Portal)portalObjectContainer.getObject(defaultPortalPath);
RenderPageCommand renderCmd = new RenderPageCommand(portal.getId());
- boolean secure = invocation.getServerContext().getURLContext().getSecure();
- URLContext urlContext = URLContext.newInstance(secure, false);
- location = ctx.renderURL(renderCmd, urlContext, null);
+ URLContext urlContext = invocation.getServerContext().getURLContext();
+ location = ctx.renderURL(renderCmd, urlContext.asNonAuthenticated(), null);
}
//
Modified: trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletInvocationFactory.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletInvocationFactory.java 2007-01-17 20:54:46 UTC (rev 6021)
+++ trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletInvocationFactory.java 2007-01-17 21:32:24 UTC (rev 6022)
@@ -245,7 +245,7 @@
}
//
- boolean secure = controllerContext.getServerInvocation().getServerContext().getURLContext().getSecure();
+ boolean secure = controllerContext.getServerInvocation().getServerContext().getURLContext().isSecure();
if (wantSecure != null)
{
secure = wantSecure.booleanValue();
Modified: trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletResponseHandler.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletResponseHandler.java 2007-01-17 20:54:46 UTC (rev 6021)
+++ trunk/core/src/main/org/jboss/portal/core/controller/portlet/PortletResponseHandler.java 2007-01-17 21:32:24 UTC (rev 6022)
@@ -118,7 +118,7 @@
InvokePortletWindowActionCommand iwac = (InvokePortletWindowActionCommand)cmd;
Page page = iwac.getPage();
RenderPageCommand renderCmd = new RenderPageCommand(page.getId());
- boolean secure = invocation.getServerContext().getURLContext().getSecure();
+ boolean secure = invocation.getServerContext().getURLContext().isSecure();
URLContext urlContext = URLContext.newInstance(secure, false);
location = ctx.renderURL(renderCmd, urlContext, null);
}
Modified: trunk/core/src/main/org/jboss/portal/core/model/portal/command/RenderPortletWindowCommand.java
===================================================================
--- trunk/core/src/main/org/jboss/portal/core/model/portal/command/RenderPortletWindowCommand.java 2007-01-17 20:54:46 UTC (rev 6021)
+++ trunk/core/src/main/org/jboss/portal/core/model/portal/command/RenderPortletWindowCommand.java 2007-01-17 21:32:24 UTC (rev 6022)
@@ -353,7 +353,7 @@
InvokePortletWindowRenderCommand cmd = new InvokePortletWindowRenderCommand(window.getId(), mode, windowState);
ControllerContext controllerContext = getControllerContext();
ServerInvocationContext serverContext = controllerContext.getServerInvocation().getServerContext();
- boolean secure = serverContext.getURLContext().getSecure();
+ boolean secure = serverContext.getURLContext().isSecure();
boolean authenticated = serverContext.getURLContext().isAuthenticated();
URLContext urlContext = URLContext.newInstance(secure, authenticated);
return controllerContext.renderURL(cmd, urlContext, URLFormat.newInstance(true, true));
Modified: trunk/server/build.xml
===================================================================
--- trunk/server/build.xml 2007-01-17 20:54:46 UTC (rev 6021)
+++ trunk/server/build.xml 2007-01-17 21:32:24 UTC (rev 6022)
@@ -310,10 +310,11 @@
</x-sysproperty>
<x-test>
<!-- Server side tests -->
- <!--<test todir="${test.reports}" name="org.jboss.portal.test.server.CharsetTestCase"/>-->
- <!--<test todir="${test.reports}" name="org.jboss.portal.test.server.ParametersTestCase"/>-->
- <!--<test todir="${test.reports}" name="org.jboss.portal.test.server.ServletTestCase"/>-->
+ <test todir="${test.reports}" name="org.jboss.portal.test.server.CharsetTestCase"/>
+ <test todir="${test.reports}" name="org.jboss.portal.test.server.ParametersTestCase"/>
+ <test todir="${test.reports}" name="org.jboss.portal.test.server.ServletTestCase"/>
<test todir="${test.reports}" name="org.jboss.portal.test.server.ResponseTestCase"/>
+ <test todir="${test.reports}" name="org.jboss.portal.test.server.request.URLContextTestCase"/>
</x-test>
<x-classpath>
<path refid="jboss.serialization.classpath"/>
Modified: trunk/server/src/main/org/jboss/portal/server/request/URLContext.java
===================================================================
--- trunk/server/src/main/org/jboss/portal/server/request/URLContext.java 2007-01-17 20:54:46 UTC (rev 6021)
+++ trunk/server/src/main/org/jboss/portal/server/request/URLContext.java 2007-01-17 21:32:24 UTC (rev 6022)
@@ -31,10 +31,10 @@
public final class URLContext
{
- /** . */
+ /** Mask for secure bit. */
public static final int SEC_MASK = 0x01;
- /** . */
+ /** Mask for authenticated bit. */
public static final int AUTH_MASK = 0x02;
/** . */
@@ -62,7 +62,7 @@
this.authenticated = authenticated;
}
- public boolean getSecure()
+ public boolean isSecure()
{
return secure;
}
@@ -72,6 +72,30 @@
return authenticated;
}
+ public URLContext asSecured()
+ {
+ int newMask = mask | SEC_MASK;
+ return contexts[newMask];
+ }
+
+ public URLContext asNonSecured()
+ {
+ int newMask = mask & ~SEC_MASK;
+ return contexts[newMask];
+ }
+
+ public URLContext asAuthenticated()
+ {
+ int newMask = mask | AUTH_MASK;
+ return contexts[newMask];
+ }
+
+ public URLContext asNonAuthenticated()
+ {
+ int newMask = mask & ~AUTH_MASK;
+ return contexts[newMask];
+ }
+
public int getMask()
{
return mask;
Added: trunk/server/src/main/org/jboss/portal/test/server/request/URLContextTestCase.java
===================================================================
--- trunk/server/src/main/org/jboss/portal/test/server/request/URLContextTestCase.java (rev 0)
+++ trunk/server/src/main/org/jboss/portal/test/server/request/URLContextTestCase.java 2007-01-17 21:32:24 UTC (rev 6022)
@@ -0,0 +1,88 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.test.server.request;
+
+import junit.framework.TestCase;
+import org.jboss.portal.server.request.URLContext;
+
+/**
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 1.1 $
+ */
+public class URLContextTestCase extends TestCase
+{
+
+ URLContext a = URLContext.newInstance(false, false);
+ URLContext b = URLContext.newInstance(true, false);
+ URLContext c = URLContext.newInstance(false, true);
+ URLContext d = URLContext.newInstance(true, true);
+
+ public void testFactory()
+ {
+ assertFalse(a.isSecure());
+ assertFalse(a.isAuthenticated());
+ assertEquals(0, a.getMask());
+
+ //
+ assertTrue(b.isSecure());
+ assertFalse(b.isAuthenticated());
+ assertEquals(URLContext.SEC_MASK, b.getMask());
+
+ //
+ assertFalse(c.isSecure());
+ assertTrue(c.isAuthenticated());
+ assertEquals(URLContext.AUTH_MASK, c.getMask());
+
+ //
+ assertTrue(d.isSecure());
+ assertTrue(d.isAuthenticated());
+ assertEquals(URLContext.AUTH_MASK | URLContext.SEC_MASK, d.getMask());
+ }
+
+ public void testTransformation()
+ {
+ assertEquals(a, a.asNonSecured());
+ assertEquals(a, a.asNonAuthenticated());
+ assertEquals(b, a.asSecured());
+ assertEquals(c, a.asAuthenticated());
+
+ //
+ assertEquals(a, b.asNonSecured());
+ assertEquals(b, b.asNonAuthenticated());
+ assertEquals(b, b.asSecured());
+ assertEquals(d, b.asAuthenticated());
+
+ //
+ assertEquals(c, c.asNonSecured());
+ assertEquals(a, c.asNonAuthenticated());
+ assertEquals(d, c.asSecured());
+ assertEquals(c, c.asAuthenticated());
+
+ //
+ assertEquals(c, d.asNonSecured());
+ assertEquals(b, d.asNonAuthenticated());
+ assertEquals(d, d.asSecured());
+ assertEquals(d, d.asAuthenticated());
+ }
+
+}
17 years, 5 months
JBoss Portal SVN: r6021 - in trunk: core-cms/src/resources/portal-cms-sar/META-INF and 1 other directories.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-01-17 15:54:46 -0500 (Wed, 17 Jan 2007)
New Revision: 6021
Added:
trunk/server/src/main/org/jboss/portal/server/impl/invocation/JBossInterceptorRegistration.java
Modified:
trunk/cms/src/main/org/jboss/portal/cms/impl/jcr/command/FolderGetListCommand.java
trunk/core-cms/src/resources/portal-cms-sar/META-INF/jboss-service.xml
Log:
- added JBossInterceptorRegistration which allows the registration of interceptor dynamically on an interceptor stack
- add/remove the cms user interceptor binding at runtime using the new interceptor registration service
Modified: trunk/cms/src/main/org/jboss/portal/cms/impl/jcr/command/FolderGetListCommand.java
===================================================================
--- trunk/cms/src/main/org/jboss/portal/cms/impl/jcr/command/FolderGetListCommand.java 2007-01-17 18:37:31 UTC (rev 6020)
+++ trunk/cms/src/main/org/jboss/portal/cms/impl/jcr/command/FolderGetListCommand.java 2007-01-17 20:54:46 UTC (rev 6021)
@@ -78,13 +78,14 @@
{
Node node = ni.nextNode();
NodeType nt = node.getPrimaryNodeType();
- if (nt.getName().equals("portalcms:folder"))
+ String ntName = nt.getName();
+ if (ntName.equals("portalcms:folder"))
{
JCRCommand folderList = (JCRCommand)context.getCommandFactory().createFolderGetCommand(node.getPath());
Folder childFolder = (Folder)context.execute(folderList);
folders.add(childFolder);
}
- else if (nt.getName().equals("portalcms:file"))
+ else if (ntName.equals("portalcms:file"))
{
//JCRCommand fileList = (JCRCommand) context.getCommandFactory().createFileGetMetaDataCommand(node.getPath(), null);
//File childFile = (File) context.execute(fileList);
Modified: trunk/core-cms/src/resources/portal-cms-sar/META-INF/jboss-service.xml
===================================================================
--- trunk/core-cms/src/resources/portal-cms-sar/META-INF/jboss-service.xml 2007-01-17 18:37:31 UTC (rev 6020)
+++ trunk/core-cms/src/resources/portal-cms-sar/META-INF/jboss-service.xml 2007-01-17 20:54:46 UTC (rev 6021)
@@ -604,4 +604,25 @@
<attribute name="UseRegionBasedMarshalling">false</attribute>
</mbean-->
+
+ <mbean
+ code="org.jboss.portal.core.cms.aspect.IdentityBindingInterceptor"
+ name="portal:service=Interceptor,type=Server,name=CMSIdentityBinding"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
+ <xmbean/>
+ </mbean>
+
+ <mbean
+ code="org.jboss.portal.server.impl.invocation.JBossInterceptorRegistration"
+ name="portal:service=InterceptorRegistration,type=Server,name=CMSIdentityBinding"
+ xmbean-dd=""
+ xmbean-code="org.jboss.portal.jems.as.system.JBossServiceModelMBean">
+ <xmbean/>
+ <depends
+ optional-attribute-name="InterceptorName">portal:service=PortalAuthorizationManagerFactory</depends>
+ <depends
+ optional-attribute-name="StackFactory">portal:service=InterceptorStackFactory,type=Server</depends>
+ </mbean>
+
</server>
Added: trunk/server/src/main/org/jboss/portal/server/impl/invocation/JBossInterceptorRegistration.java
===================================================================
--- trunk/server/src/main/org/jboss/portal/server/impl/invocation/JBossInterceptorRegistration.java (rev 0)
+++ trunk/server/src/main/org/jboss/portal/server/impl/invocation/JBossInterceptorRegistration.java 2007-01-17 20:54:46 UTC (rev 6021)
@@ -0,0 +1,113 @@
+/******************************************************************************
+ * JBoss, a division of Red Hat *
+ * Copyright 2006, Red Hat Middleware, LLC, and individual *
+ * contributors as indicated by the @authors tag. See the *
+ * copyright.txt in the distribution for a full listing of *
+ * individual contributors. *
+ * *
+ * This is free software; you can redistribute it and/or modify it *
+ * under the terms of the GNU Lesser General Public License as *
+ * published by the Free Software Foundation; either version 2.1 of *
+ * the License, or (at your option) any later version. *
+ * *
+ * This software is distributed in the hope that it will be useful, *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
+ * Lesser General Public License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser General Public *
+ * License along with this software; if not, write to the Free *
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org. *
+ ******************************************************************************/
+package org.jboss.portal.server.impl.invocation;
+
+import org.jboss.portal.jems.as.system.AbstractJBossService;
+
+import javax.management.ObjectName;
+
+/**
+ * Register an interceptor on a stack factory. The main usage is for dynamic registration of an interceptor
+ * when the interceptor cannot be specified in the stack factory dependencies.
+ *
+ * @author <a href="mailto:julien@jboss.org">Julien Viet</a>
+ * @version $Revision: 1.1 $
+ */
+public class JBossInterceptorRegistration extends AbstractJBossService
+{
+
+ /** . */
+ private ObjectName interceptorName;
+
+ /** . */
+ private ObjectName stackFactory;
+
+ public ObjectName getInterceptorName()
+ {
+ return interceptorName;
+ }
+
+ public void setInterceptorName(ObjectName interceptorName)
+ {
+ this.interceptorName = interceptorName;
+ }
+
+ public ObjectName getStackFactory()
+ {
+ return stackFactory;
+ }
+
+ public void setStackFactory(ObjectName stackFactory)
+ {
+ this.stackFactory = stackFactory;
+ }
+
+ protected void startService() throws Exception
+ {
+ try
+ {
+ server.invoke(
+ stackFactory,
+ "addInterceptor",
+ new Object[]{interceptorName},
+ new String[]{ObjectName.class.getName()});
+ }
+ finally
+ {
+ rebuildStackFactory();
+ }
+ }
+
+ protected void stopService() throws Exception
+ {
+ try
+ {
+ server.invoke(
+ stackFactory,
+ "removeInterceptor",
+ new Object[]{interceptorName},
+ new String[]{ObjectName.class.getName()});
+ }
+ finally
+ {
+ rebuildStackFactory();
+ }
+ }
+
+ private void rebuildStackFactory()
+ {
+ try
+ {
+ server.invoke(
+ stackFactory,
+ "rebuild",
+ new Object[0],
+ new String[0]);
+ }
+ catch (Exception e)
+ {
+ log.warn("Exception during rebuild of stack factory", e);
+ }
+ }
+}
+
17 years, 5 months
JBoss Portal SVN: r6020 - in trunk: wsrp and 3 other directories.
by portal-commits@lists.jboss.org
Author: chris.laprun(a)jboss.com
Date: 2007-01-17 13:37:31 -0500 (Wed, 17 Jan 2007)
New Revision: 6020
Modified:
trunk/build/ide/intellij/idea60/modules/workflow/workflow.iml
trunk/wsrp/build.xml
trunk/wsrp/src/main/org/jboss/portal/wsrp/consumer/ProducerInfo.java
trunk/wsrp/src/main/org/jboss/portal/wsrp/consumer/WSRPConsumerImpl.java
trunk/wsrp/src/main/org/jboss/portal/wsrp/deployment/WSRPConsumerService.java
trunk/wsrp/src/main/org/jboss/portal/wsrp/deployment/WSRPDeployer.java
trunk/wsrp/src/main/org/jboss/portal/wsrp/producer/WSRPProducerImpl.java
Log:
- JBPORTAL-1194: Reverted build of ProducerInfo on Consumer start to work around deployment issues.
- JBPORTAL-1201: ProducerInfo.refresh now correctly refreshes POP list as well.
- Minor code clean-ups.
Modified: trunk/build/ide/intellij/idea60/modules/workflow/workflow.iml
===================================================================
--- trunk/build/ide/intellij/idea60/modules/workflow/workflow.iml 2007-01-17 15:37:41 UTC (rev 6019)
+++ trunk/build/ide/intellij/idea60/modules/workflow/workflow.iml 2007-01-17 18:37:31 UTC (rev 6020)
@@ -52,5 +52,178 @@
<option name="ACTIVE_VCS_NAME" value="svn" />
<option name="USE_PROJECT_VCS" value="false" />
</component>
+ <component name="copyright">
+ <Base>
+ <setting name="state" value="1" />
+ </Base>
+ <LanguageOptions name="$TEMPLATE$">
+ <option name="templateOptions">
+ <value>
+ <option name="block" value="true" />
+ <option name="separateBefore" value="true" />
+ <option name="separateAfter" value="true" />
+ <option name="prefixLines" value="true" />
+ <option name="lenBefore" value="80" />
+ <option name="lenAfter" value="80" />
+ <option name="box" value="true" />
+ <option name="filler" value=" " />
+ </value>
+ </option>
+ <option name="notice" value="JBoss, a division of Red Hat Copyright &#36;today.year, Red Hat Middleware, LLC, and individual contributors as indicated by the @authors tag. See the copyright.txt in the distribution for a full listing of individual contributors. This is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option) any later version. This software is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this software; if not, write to the Free Software Foundation, Inc., 51 Fr!
anklin St, Fifth Floor, Boston, MA 02110-1301 USA, or see the FSF site: http://www.fsf.org." />
+ <option name="keyword" value="Copyright" />
+ <option name="fileTypeOverride" value="4" />
+ <option name="relativeBefore" value="true" />
+ <option name="addBlankAfter" value="true" />
+ <option name="fileLocation" value="1" />
+ <option name="useAlternate" value="false" />
+ </LanguageOptions>
+ <LanguageOptions name="CSS">
+ <option name="templateOptions">
+ <value>
+ <option name="block" value="true" />
+ <option name="separateBefore" value="false" />
+ <option name="separateAfter" value="false" />
+ <option name="prefixLines" value="true" />
+ <option name="lenBefore" value="80" />
+ <option name="lenAfter" value="80" />
+ <option name="box" value="false" />
+ <option name="filler" value=" " />
+ </value>
+ </option>
+ <option name="notice" value="Copyright (c) &#36;today.year, Your Corporation. All Rights Reserved." />
+ <option name="keyword" value="Copyright" />
+ <option name="fileTypeOverride" value="1" />
+ <option name="relativeBefore" value="true" />
+ <option name="addBlankAfter" value="true" />
+ <option name="fileLocation" value="1" />
+ <option name="useAlternate" value="false" />
+ </LanguageOptions>
+ <LanguageOptions name="HTML">
+ <option name="templateOptions">
+ <value>
+ <option name="block" value="true" />
+ <option name="separateBefore" value="false" />
+ <option name="separateAfter" value="false" />
+ <option name="prefixLines" value="true" />
+ <option name="lenBefore" value="80" />
+ <option name="lenAfter" value="80" />
+ <option name="box" value="false" />
+ <option name="filler" value=" " />
+ </value>
+ </option>
+ <option name="notice" value="Copyright (c) &#36;today.year, Your Corporation. All Rights Reserved." />
+ <option name="keyword" value="Copyright" />
+ <option name="fileTypeOverride" value="1" />
+ <option name="relativeBefore" value="true" />
+ <option name="addBlankAfter" value="true" />
+ <option name="fileLocation" value="1" />
+ <option name="useAlternate" value="false" />
+ </LanguageOptions>
+ <LanguageOptions name="JAVA">
+ <option name="templateOptions">
+ <value>
+ <option name="block" value="true" />
+ <option name="separateBefore" value="false" />
+ <option name="separateAfter" value="false" />
+ <option name="prefixLines" value="true" />
+ <option name="lenBefore" value="80" />
+ <option name="lenAfter" value="80" />
+ <option name="box" value="false" />
+ <option name="filler" value=" " />
+ </value>
+ </option>
+ <option name="notice" value="Copyright (c) &#36;today.year, Your Corporation. All Rights Reserved." />
+ <option name="keyword" value="Copyright" />
+ <option name="fileTypeOverride" value="2" />
+ <option name="relativeBefore" value="true" />
+ <option name="addBlankAfter" value="true" />
+ <option name="fileLocation" value="1" />
+ <option name="useAlternate" value="false" />
+ </LanguageOptions>
+ <LanguageOptions name="JSP">
+ <option name="templateOptions">
+ <value>
+ <option name="block" value="true" />
+ <option name="separateBefore" value="false" />
+ <option name="separateAfter" value="false" />
+ <option name="prefixLines" value="true" />
+ <option name="lenBefore" value="80" />
+ <option name="lenAfter" value="80" />
+ <option name="box" value="false" />
+ <option name="filler" value=" " />
+ </value>
+ </option>
+ <option name="notice" value="Copyright (c) &#36;today.year, Your Corporation. All Rights Reserved." />
+ <option name="keyword" value="Copyright" />
+ <option name="fileTypeOverride" value="1" />
+ <option name="relativeBefore" value="true" />
+ <option name="addBlankAfter" value="true" />
+ <option name="fileLocation" value="1" />
+ <option name="useAlternate" value="false" />
+ </LanguageOptions>
+ <LanguageOptions name="JavaScript">
+ <option name="templateOptions">
+ <value>
+ <option name="block" value="true" />
+ <option name="separateBefore" value="false" />
+ <option name="separateAfter" value="false" />
+ <option name="prefixLines" value="true" />
+ <option name="lenBefore" value="80" />
+ <option name="lenAfter" value="80" />
+ <option name="box" value="false" />
+ <option name="filler" value=" " />
+ </value>
+ </option>
+ <option name="notice" value="Copyright (c) &#36;today.year, Your Corporation. All Rights Reserved." />
+ <option name="keyword" value="Copyright" />
+ <option name="fileTypeOverride" value="1" />
+ <option name="relativeBefore" value="true" />
+ <option name="addBlankAfter" value="true" />
+ <option name="fileLocation" value="1" />
+ <option name="useAlternate" value="false" />
+ </LanguageOptions>
+ <LanguageOptions name="Properties">
+ <option name="templateOptions">
+ <value>
+ <option name="block" value="true" />
+ <option name="separateBefore" value="false" />
+ <option name="separateAfter" value="false" />
+ <option name="prefixLines" value="true" />
+ <option name="lenBefore" value="80" />
+ <option name="lenAfter" value="80" />
+ <option name="box" value="false" />
+ <option name="filler" value=" " />
+ </value>
+ </option>
+ <option name="notice" value="Copyright (c) &#36;today.year, Your Corporation. All Rights Reserved." />
+ <option name="keyword" value="Copyright" />
+ <option name="fileTypeOverride" value="1" />
+ <option name="relativeBefore" value="true" />
+ <option name="addBlankAfter" value="true" />
+ <option name="fileLocation" value="1" />
+ <option name="useAlternate" value="false" />
+ </LanguageOptions>
+ <LanguageOptions name="XML">
+ <option name="templateOptions">
+ <value>
+ <option name="block" value="true" />
+ <option name="separateBefore" value="false" />
+ <option name="separateAfter" value="false" />
+ <option name="prefixLines" value="true" />
+ <option name="lenBefore" value="80" />
+ <option name="lenAfter" value="80" />
+ <option name="box" value="false" />
+ <option name="filler" value=" " />
+ </value>
+ </option>
+ <option name="notice" value="Copyright (c) &#36;today.year, Your Corporation. All Rights Reserved." />
+ <option name="keyword" value="Copyright" />
+ <option name="fileTypeOverride" value="2" />
+ <option name="relativeBefore" value="true" />
+ <option name="addBlankAfter" value="true" />
+ <option name="fileLocation" value="1" />
+ <option name="useAlternate" value="false" />
+ </LanguageOptions>
+ </component>
</module>
Modified: trunk/wsrp/build.xml
===================================================================
--- trunk/wsrp/build.xml 2007-01-17 15:37:41 UTC (rev 6019)
+++ trunk/wsrp/build.xml 2007-01-17 18:37:31 UTC (rev 6020)
@@ -238,7 +238,7 @@
<jar jarfile="${build.lib}/portal-wsrp.jse">
<fileset dir="${build.resources}/portal-wsrp-war"/>
</jar>
- <copy todir="${build.resources}/portal-wsrp-sar">
+ <copy todir="${build.resources}/portal-wsrp-sar" overwrite="true">
<fileset dir="${build.lib}" includes="portal-wsrp-client.jar"/>
<fileset dir="${build.lib}" includes="portal-wsrp-lib.jar"/>
<fileset dir="${build.lib}" includes="portal-wsrp.jse"/>
Modified: trunk/wsrp/src/main/org/jboss/portal/wsrp/consumer/ProducerInfo.java
===================================================================
--- trunk/wsrp/src/main/org/jboss/portal/wsrp/consumer/ProducerInfo.java 2007-01-17 15:37:41 UTC (rev 6019)
+++ trunk/wsrp/src/main/org/jboss/portal/wsrp/consumer/ProducerInfo.java 2007-01-17 18:37:31 UTC (rev 6020)
@@ -120,27 +120,16 @@
this.registrationInfo = registrationInfo;
}
- public boolean requiresRegistration()
+ CookieProtocol getRequiresInitCookie()
{
- return registrationInfo != null && registrationInfo.requiresRegistration();
- }
-
- public CookieProtocol getRequiresInitCookie()
- {
return requiresInitCookie;
}
- public boolean isInitialized()
+ private boolean isInitialized()
{
return isInitialized;
}
- public void start() throws Exception
- {
- refresh(true);
- endpointConfigurationInfo.getServiceFactory().start();
- }
-
public boolean refresh(boolean forceRefresh) throws PortletInvokerException
{
ServiceDescription serviceDescription;
@@ -200,6 +189,10 @@
isInitialized = false;
}
}
+
+ // refresh the offered portlets
+ extractOfferedPortlets(serviceDescription);
+ isInitialized = true;
}
else
{
@@ -225,11 +218,6 @@
return isInitialized;
}
- public boolean needsRegistration()
- {
- return requiresRegistration() && !registrationInfo.isRegistrationValid();
- }
-
public String getId()
{
return producerId;
@@ -326,6 +314,8 @@
public Portlet getPortlet(String portletId) throws PortletInvokerException
{
+ refresh(false);
+
// if cache is still valid, use information from cached service description
if (useCache() && !isCacheExpired())
{
Modified: trunk/wsrp/src/main/org/jboss/portal/wsrp/consumer/WSRPConsumerImpl.java
===================================================================
--- trunk/wsrp/src/main/org/jboss/portal/wsrp/consumer/WSRPConsumerImpl.java 2007-01-17 15:37:41 UTC (rev 6019)
+++ trunk/wsrp/src/main/org/jboss/portal/wsrp/consumer/WSRPConsumerImpl.java 2007-01-17 18:37:31 UTC (rev 6020)
@@ -504,9 +504,16 @@
protected void startService() throws Exception
{
- producerInfo.start();
+ super.startService();
+ getServiceFactory().start();
}
+ protected void stopService() throws Exception
+ {
+ getServiceFactory().stop();
+ super.stopService();
+ }
+
// Web services access **********************************************************************************************
public ServiceFactory getServiceFactory()
@@ -519,23 +526,27 @@
producerInfo.getEndpointConfigurationInfo().setServiceFactory(serviceFactory);
}
- public WSRP_v1_ServiceDescription_PortType getServiceDescriptionService() throws InvokerUnavailableException
+ public WSRP_v1_ServiceDescription_PortType getServiceDescriptionService() throws PortletInvokerException
{
+ producerInfo.refresh(false);
return producerInfo.getEndpointConfigurationInfo().getServiceDescriptionService();
}
- public WSRP_v1_Markup_PortType getMarkupService() throws InvokerUnavailableException
+ public WSRP_v1_Markup_PortType getMarkupService() throws PortletInvokerException
{
+ producerInfo.refresh(false);
return producerInfo.getEndpointConfigurationInfo().getMarkupService();
}
- public WSRP_v1_PortletManagement_PortType getPortletManagementService() throws InvokerUnavailableException
+ public WSRP_v1_PortletManagement_PortType getPortletManagementService() throws PortletInvokerException
{
+ producerInfo.refresh(false);
return producerInfo.getEndpointConfigurationInfo().getPortletManagementService();
}
- public WSRP_v1_Registration_PortType getRegistrationService() throws InvokerUnavailableException
+ public WSRP_v1_Registration_PortType getRegistrationService() throws PortletInvokerException
{
+ producerInfo.refresh(false);
return producerInfo.getEndpointConfigurationInfo().getRegistrationService();
}
Modified: trunk/wsrp/src/main/org/jboss/portal/wsrp/deployment/WSRPConsumerService.java
===================================================================
--- trunk/wsrp/src/main/org/jboss/portal/wsrp/deployment/WSRPConsumerService.java 2007-01-17 15:37:41 UTC (rev 6019)
+++ trunk/wsrp/src/main/org/jboss/portal/wsrp/deployment/WSRPConsumerService.java 2007-01-17 18:37:31 UTC (rev 6020)
@@ -73,11 +73,15 @@
protected void startService() throws Exception
{
+ super.startService();
federatingPortletInvoker.registerInvoker(this);
+ consumer.start();
}
protected void stopService() throws Exception
{
+ consumer.stop();
federatingPortletInvoker.unregisterInvoker(this);
+ super.stop();
}
}
Modified: trunk/wsrp/src/main/org/jboss/portal/wsrp/deployment/WSRPDeployer.java
===================================================================
--- trunk/wsrp/src/main/org/jboss/portal/wsrp/deployment/WSRPDeployer.java 2007-01-17 15:37:41 UTC (rev 6019)
+++ trunk/wsrp/src/main/org/jboss/portal/wsrp/deployment/WSRPDeployer.java 2007-01-17 18:37:31 UTC (rev 6020)
@@ -40,8 +40,6 @@
*/
public class WSRPDeployer extends SubDeployerSupport implements WSRPDeployerMBean
{
-
-
/** . */
private static final String[] DEFAULT_ENHANCED_SUFFIXES = new String[]{"800:-wsrp.xml"};
@@ -111,8 +109,6 @@
{
WSRPConsumerService service = (WSRPConsumerService)i.next();
service.setFederatingPortletInvoker(federatingPortletInvoker);
- service.getConsumer().getServiceFactory().start();
- service.getConsumer().start();
service.start();
}
catch (Exception e)
@@ -131,8 +127,6 @@
{
WSRPConsumerService service = (WSRPConsumerService)i.next();
service.stop();
- service.getConsumer().stop();
- service.getConsumer().getServiceFactory().stop();
}
catch (Exception e)
{
Modified: trunk/wsrp/src/main/org/jboss/portal/wsrp/producer/WSRPProducerImpl.java
===================================================================
--- trunk/wsrp/src/main/org/jboss/portal/wsrp/producer/WSRPProducerImpl.java 2007-01-17 15:37:41 UTC (rev 6019)
+++ trunk/wsrp/src/main/org/jboss/portal/wsrp/producer/WSRPProducerImpl.java 2007-01-17 18:37:31 UTC (rev 6020)
@@ -462,7 +462,6 @@
log.debug("Portlet " + portlet.getContext() + " remotable: " + remotable);
if (remotable != null)
{
-
return remotable.booleanValue();
}
else
17 years, 5 months
JBoss Portal SVN: r6019 - trunk/core/src/bin/portal-core-war/themes/renaissance.
by portal-commits@lists.jboss.org
Author: roy.russo(a)jboss.com
Date: 2007-01-17 10:37:41 -0500 (Wed, 17 Jan 2007)
New Revision: 6019
Modified:
trunk/core/src/bin/portal-core-war/themes/renaissance/portal_style.css
Log:
JBPORTAL-1136 - fixed horizontal scroll bar
Modified: trunk/core/src/bin/portal-core-war/themes/renaissance/portal_style.css
===================================================================
--- trunk/core/src/bin/portal-core-war/themes/renaissance/portal_style.css 2007-01-16 09:50:44 UTC (rev 6018)
+++ trunk/core/src/bin/portal-core-war/themes/renaissance/portal_style.css 2007-01-17 15:37:41 UTC (rev 6019)
@@ -101,14 +101,14 @@
#content-container {
height: 100%;
text-align: left;
- width: 100%;
+ /*width: 100%;*/
min-width: 770px;
position: absolute;
top: 70px;
left: 0px; /* z-index: 1; */
/*part of below IE hack
padding: 0 350px 0 350px; */
- padding: 0px 100px 0px 0px;
+ padding: 0px 0px 0px 0px;
}
/* Login JSP Selectors */
17 years, 5 months
JBoss Portal SVN: r6018 - in trunk/core/src/resources/portal-core-sar/conf/hibernate: portal and 1 other directory.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-01-16 04:50:44 -0500 (Tue, 16 Jan 2007)
New Revision: 6018
Modified:
trunk/core/src/resources/portal-core-sar/conf/hibernate/instance/domain.hbm.xml
trunk/core/src/resources/portal-core-sar/conf/hibernate/portal/domain.hbm.xml
Log:
JBPORTAL-1196 : Invalid table creation script with Oracle 9i
Modified: trunk/core/src/resources/portal-core-sar/conf/hibernate/instance/domain.hbm.xml
===================================================================
--- trunk/core/src/resources/portal-core-sar/conf/hibernate/instance/domain.hbm.xml 2007-01-16 02:25:10 UTC (rev 6017)
+++ trunk/core/src/resources/portal-core-sar/conf/hibernate/instance/domain.hbm.xml 2007-01-16 09:50:44 UTC (rev 6018)
@@ -43,7 +43,7 @@
name="instanceId"
column="ID"
not-null="true"
- unique="true"/>
+ unique="false"/>
</natural-id>
<property
name="portletRef"
Modified: trunk/core/src/resources/portal-core-sar/conf/hibernate/portal/domain.hbm.xml
===================================================================
--- trunk/core/src/resources/portal-core-sar/conf/hibernate/portal/domain.hbm.xml 2007-01-16 02:25:10 UTC (rev 6017)
+++ trunk/core/src/resources/portal-core-sar/conf/hibernate/portal/domain.hbm.xml 2007-01-16 09:50:44 UTC (rev 6018)
@@ -44,7 +44,7 @@
column="PATH"
type="org.jboss.portal.jems.hibernate.MagicString"
not-null="false"
- unique="true"/>
+ unique="false"/>
</natural-id>
<property
name="name"
17 years, 5 months
JBoss Portal SVN: r6016 - in trunk: core-cms/src/main/org/jboss/portal/core/cms/aspect and 1 other directory.
by portal-commits@lists.jboss.org
Author: julien(a)jboss.com
Date: 2007-01-15 21:17:07 -0500 (Mon, 15 Jan 2007)
New Revision: 6016
Modified:
trunk/build/ide/intellij/idea60/modules/core-cms/core-cms.iml
trunk/core-cms/src/main/org/jboss/portal/core/cms/aspect/IdentityBindingInterceptor.java
Log:
forgot to move PublishAssignmentHandler to core-cms integration
Modified: trunk/build/ide/intellij/idea60/modules/core-cms/core-cms.iml
===================================================================
--- trunk/build/ide/intellij/idea60/modules/core-cms/core-cms.iml 2007-01-16 02:08:41 UTC (rev 6015)
+++ trunk/build/ide/intellij/idea60/modules/core-cms/core-cms.iml 2007-01-16 02:17:07 UTC (rev 6016)
@@ -51,6 +51,7 @@
</orderEntry>
<orderEntry type="module" module-name="portlet" />
<orderEntry type="module" module-name="identity" />
+ <orderEntry type="module" module-name="common" />
<orderEntryProperties />
</component>
<component name="VcsManagerConfiguration">
Modified: trunk/core-cms/src/main/org/jboss/portal/core/cms/aspect/IdentityBindingInterceptor.java
===================================================================
--- trunk/core-cms/src/main/org/jboss/portal/core/cms/aspect/IdentityBindingInterceptor.java 2007-01-16 02:08:41 UTC (rev 6015)
+++ trunk/core-cms/src/main/org/jboss/portal/core/cms/aspect/IdentityBindingInterceptor.java 2007-01-16 02:17:07 UTC (rev 6016)
@@ -24,11 +24,9 @@
import org.jboss.portal.identity.User;
import org.jboss.portal.cms.impl.jcr.JCRCMS;
-import org.jboss.portal.cms.impl.jcr.JCRCommand;
-import org.jboss.portal.cms.CMSInterceptor;
import org.jboss.portal.server.ServerInterceptor;
import org.jboss.portal.server.ServerInvocation;
-import com.sun.jdi.InvocationException;
+import org.jboss.portal.common.invocation.InvocationException;
/**
* @author <a href="mailto:julien@jboss.org">Julien Viet</a>
17 years, 5 months
JBoss Portal SVN: r6015 - in trunk/core-cms/src: resources/portal-cms-war/WEB-INF/jsp/cms/admin and 1 other directory.
by portal-commits@lists.jboss.org
Author: roy.russo(a)jboss.com
Date: 2007-01-15 21:08:41 -0500 (Mon, 15 Jan 2007)
New Revision: 6015
Modified:
trunk/core-cms/src/main/org/jboss/portal/core/cms/ui/admin/CMSAdminConstants.java
trunk/core-cms/src/resources/portal-cms-war/WEB-INF/jsp/cms/admin/viewfile.jsp
Log:
JBPORTAL-1153 - ui changes
Modified: trunk/core-cms/src/main/org/jboss/portal/core/cms/ui/admin/CMSAdminConstants.java
===================================================================
--- trunk/core-cms/src/main/org/jboss/portal/core/cms/ui/admin/CMSAdminConstants.java 2007-01-16 02:01:12 UTC (rev 6014)
+++ trunk/core-cms/src/main/org/jboss/portal/core/cms/ui/admin/CMSAdminConstants.java 2007-01-16 02:08:41 UTC (rev 6015)
@@ -99,4 +99,6 @@
public static final String OP_APPROVE = "approve";
public static final String OP_DENY = "deny";
+
+ public static final String OP_VIEWPENDING = "view_pending_items";
}
Modified: trunk/core-cms/src/resources/portal-cms-war/WEB-INF/jsp/cms/admin/viewfile.jsp
===================================================================
--- trunk/core-cms/src/resources/portal-cms-war/WEB-INF/jsp/cms/admin/viewfile.jsp 2007-01-16 02:01:12 UTC (rev 6014)
+++ trunk/core-cms/src/resources/portal-cms-war/WEB-INF/jsp/cms/admin/viewfile.jsp 2007-01-16 02:08:41 UTC (rev 6015)
@@ -125,9 +125,8 @@
<portlet:param name="returnOp" value="<%= CMSAdminConstants.OP_VIEWFILE %>"/>
</portlet:renderURL>">${n:i18n("CMS_SECURE")}</a></li>
<li><a href="<portlet:renderURL>
- <portlet:param name="op" value="<%= CMSAdminConstants.OP_CONFIRMSECURE %>"/>
+ <portlet:param name="op" value="<%= CMSAdminConstants.OP_VIEWPENDING %>"/>
<portlet:param name="path" value="<%= sCurrPath %>"/>
- <portlet:param name="returnOp" value="<%= CMSAdminConstants.OP_VIEWFILE %>"/>
</portlet:renderURL>">${n:i18n("CMS_APPROVAL")}</a></li>
</ul>
</li>
17 years, 5 months