Author: ate
Date: Fri Jul 18 12:57:49 2008
New Revision: 678019
URL:
http://svn.apache.org/viewvc?rev=678019&view=revLog:
JS2-895: Provide a solution to seperate the Jetspeed build integration tasks (configuration,database,deploy) from the standard Maven-2 build lifecycle
See:
http://issues.apache.org/jira/browse/JS2-895Added:
portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/jetspeed-mvn-demo-pom.xml (with props)
portals/jetspeed-2/portal/trunk/jetspeed-mvn-db-init-pom.xml (with props)
portals/jetspeed-2/portal/trunk/jetspeed-mvn-settings-sample.xml
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/ (with props)
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/pom.xml (with props)
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/CompositeMap.java (with props)
portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/MvnMojo.java (with props)
portals/jetspeed-2/portal/trunk/maven/src/
portals/jetspeed-2/portal/trunk/maven/src/site/
portals/jetspeed-2/portal/trunk/maven/src/site/resources/
portals/jetspeed-2/portal/trunk/maven/src/site/resources/css/
portals/jetspeed-2/portal/trunk/maven/src/site/resources/css/site.css
portals/jetspeed-2/portal/trunk/maven/src/site/site.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/building-jetspeed.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/examples/
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/examples/jetspeed-demo.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/examples/multiple-targets.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/index.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/jetspeed-archetype.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/jetspeed-db-ddl-plugin.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/jetspeed-db-init-plugin.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/jetspeed-deploy-plugin.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/jetspeed-maven-plugins.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/jetspeed-mvn-plugin.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/jetspeed-portal-resources.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/jetspeed-unpack-plugin.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/project-structure.xml (with props)
portals/jetspeed-2/portal/trunk/maven/src/site/xdoc/the-need-for-a-custom-lifecycle.xml (with props)
Removed:
portals/jetspeed-2/portal/trunk/settings.xml.derby.minimal
portals/jetspeed-2/portal/trunk/settings.xml.sample
Modified:
portals/jetspeed-2/portal/trunk/ (props changed)
portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/pom.xml
portals/jetspeed-2/portal/trunk/maven/pom.xml
portals/jetspeed-2/portal/trunk/pom.xml
portals/jetspeed-2/portal/trunk/quickStart.sh
Propchange: portals/jetspeed-2/portal/trunk/
------------------------------------------------------------------------------
--- svn:ignore (original)
+++ svn:ignore Fri Jul 18 12:57:49 2008
@@ -12,3 +12,5 @@
.springBeansProject
target-eclipse
+
+jetspeed-mvn-settings.xml
Added: portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/jetspeed-mvn-demo-pom.xml
URL:
http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/jetspeed-mvn-demo-pom.xml?rev=678019&view=auto==============================================================================
--- portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/jetspeed-mvn-demo-pom.xml (added)
+++ portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/jetspeed-mvn-demo-pom.xml Fri Jul 18 12:57:49 2008
@@ -0,0 +1,345 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You 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.
+
+ $Id$
+-->
+<project xmlns="
http://maven.apache.org/POM/4.0.0" xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="
http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+ <modelVersion>4.0.0</modelVersion>
+ <prerequisites>
+ <maven>2.0.9</maven>
+ </prerequisites>
+
+ <artifactId>jetspeed-mvn-demo-pom</artifactId>
+ <name>Jetspeed-2 Maven Invoker Configuration for Jetspeed Demo Portal</name>
+ <description>Jetspeed-2 Maven Invoker Configuration for Jetspeed Demo Portal</description>
+ <parent>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>applications</artifactId>
+ <version>2.2-SNAPSHOT</version>
+ </parent>
+
+ <packaging>pom</packaging>
+
+ <properties>
+ <org.apache.portals.jetspeed.version>${pom.version}</org.apache.portals.jetspeed.version>
+ <org.apache.jetspeed.portal.context.name>jetspeed</org.apache.jetspeed.portal.context.name>
+ <org.apache.jetspeed.server.home>${project.build.directory}/demo-deploy</org.apache.jetspeed.server.home>
+ </properties>
+
+ <build>
+ <defaultGoal>process-resources</defaultGoal>
+ </build>
+
+ <profiles>
+ <profile>
+ <id>seed</id>
+ <build>
+ <plugins>
+
+ <plugin>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-db-maven-plugin</artifactId>
+ <version>${org.apache.portals.jetspeed.version}</version>
+ <executions>
+ <execution>
+ <id>seed</id>
+ <goals>
+ <goal>init</goal>
+ </goals>
+ <phase>process-resources</phase>
+ <configuration>
+ <connection>
+ <username>${org.apache.jetspeed.production.database.user}</username>
+ <password>${org.apache.jetspeed.production.database.password}</password>
+ <url>${org.apache.jetspeed.production.database.url}</url>
+ <driver>${org.apache.jetspeed.production.database.driver}</driver>
+ </connection>
+ <unpack>
+ <artifact>org.apache.portals.jetspeed-2:jetspeed-portal-resources:jar</artifact>
+ <resources>
+ <resource>
+ <path>seed</path>
+ <destination>db/seed</destination>
+ </resource>
+ </resources>
+ </unpack>
+ <seed>
+ <categories>serializer</categories>
+ <filterPropertiesFileName>
+ ${project.build.directory}/jetspeed-demo-${pom.version}/WEB-INF/conf/spring-filter.properties
+ </filterPropertiesFileName>
+ <applicationRootPath>
+ ${project.build.directory}/jetspeed-demo-${pom.version}
+ </applicationRootPath>
+ <files>
+ <file>${project.build.directory}/db/seed/j2-seed.xml</file>
+ </files>
+ <initProperties>
+ <org.apache.jetspeed.database.user>${org.apache.jetspeed.production.database.user}</org.apache.jetspeed.database.user>
+ <org.apache.jetspeed.database.password>${org.apache.jetspeed.production.database.password}</org.apache.jetspeed.database.password>
+ <org.apache.jetspeed.database.url>${org.apache.jetspeed.production.database.url}</org.apache.jetspeed.database.url>
+ <org.apache.jetspeed.database.driver>${org.apache.jetspeed.production.database.driver}</org.apache.jetspeed.database.driver>
+ </initProperties>
+ </seed>
+ </configuration>
+ </execution>
+ </executions>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-portal-resources</artifactId>
+ <version>${org.apache.portals.jetspeed.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-db-tools</artifactId>
+ <version>${org.apache.portals.jetspeed.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>${org.apache.jetspeed.production.jdbc.driver.groupId}</groupId>
+ <artifactId>${org.apache.jetspeed.production.jdbc.driver.artifactId}</artifactId>
+ <version>${org.apache.jetspeed.production.jdbc.driver.version}</version>
+ </dependency>
+ </dependencies>
+ </plugin>
+
+ </plugins>
+ </build>
+ </profile>
+
+ <profile>
+ <id>seed-dbpsml</id>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-db-maven-plugin</artifactId>
+ <version>${org.apache.portals.jetspeed.version}</version>
+ <executions>
+ <execution>
+ <id>seed-dbpsml</id>
+ <goals>
+ <goal>init</goal>
+ </goals>
+ <phase>process-resources</phase>
+ <configuration>
+ <psml>
+ <categories>pageSerializer</categories>
+ <filterPropertiesFileName>
+ ${project.build.directory}/jetspeed-demo-${pom.version}/WEB-INF/conf/spring-filter.properties
+ </filterPropertiesFileName>
+ <applicationRootPath>
+ ${project.build.directory}/jetspeed-demo-${pom.version}
+ </applicationRootPath>
+ <initProperties>
+ <org.apache.jetspeed.database.user>${org.apache.jetspeed.production.database.user}</org.apache.jetspeed.database.user>
+ <org.apache.jetspeed.database.password>${org.apache.jetspeed.production.database.password}</org.apache.jetspeed.database.password>
+ <org.apache.jetspeed.database.url>${org.apache.jetspeed.production.database.url}</org.apache.jetspeed.database.url>
+ <org.apache.jetspeed.database.driver>${org.apache.jetspeed.production.database.driver}</org.apache.jetspeed.database.driver>
+ </initProperties>
+ </psml>
+ </configuration>
+ </execution>
+ </executions>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-portal-resources</artifactId>
+ <version>${org.apache.portals.jetspeed.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-db-tools</artifactId>
+ <version>${org.apache.portals.jetspeed.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>${org.apache.jetspeed.production.jdbc.driver.groupId}</groupId>
+ <artifactId>${org.apache.jetspeed.production.jdbc.driver.artifactId}</artifactId>
+ <version>${org.apache.jetspeed.production.jdbc.driver.version}</version>
+ </dependency>
+ </dependencies>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+
+ <profile>
+ <id>deploy</id>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-deploy-maven-plugin</artifactId>
+ <version>${org.apache.portals.jetspeed.version}</version>
+ <executions>
+ <execution>
+ <id>deploy</id>
+ <goals>
+ <goal>deploy</goal>
+ </goals>
+ <phase>process-resources</phase>
+ <configuration>
+ <targetBaseDir>${org.apache.jetspeed.server.home}</targetBaseDir>
+ <portalName>${org.apache.jetspeed.portal.context.name}</portalName>
+ <deployments>
+ <!-- shared/lib -->
+ <deployment>
+ <artifact>portlet-api:portlet-api:jar</artifact>
+ </deployment>
+ <deployment>
+ <artifact>org.apache.portals.jetspeed-2:jetspeed-api:jar</artifact>
+ </deployment>
+ <deployment>
+ <artifact>org.apache.portals.jetspeed-2:jetspeed-commons:jar</artifact>
+ </deployment>
+ <deployment>
+ <artifact>org.apache.pluto:pluto:jar</artifact>
+ </deployment>
+ <deployment>
+ <artifact>org.apache.portals.bridges:portals-bridges-common:jar</artifact>
+ </deployment>
+ <deployment>
+ <artifact>${org.apache.jetspeed.production.jdbc.driver.groupId}:${org.apache.jetspeed.production.jdbc.driver.artifactId}:jar</artifact>
+ <destination>system</destination>
+ </deployment>
+ <!-- jetspeed portal expanded -->
+ <deployment>
+ <artifact>org.apache.portals.jetspeed-2:jetspeed-demo:war</artifact>
+ <expand>true</expand>
+ <targetName>${org.apache.jetspeed.portal.context.name}</targetName>
+ <delete>./${org.apache.jetspeed.portal.context.name}</delete>
+ </deployment>
+ <!-- admin pa -->
+ <deployment>
+ <artifact>org.apache.portals.jetspeed-2:j2-admin:war</artifact>
+ <delete>./j2-admin</delete>
+ </deployment>
+ <!-- demo pa's -->
+ <deployment>
+ <artifact>org.apache.portals.jetspeed-2:demo:war</artifact>
+ <delete>./demo</delete>
+ </deployment>
+ <deployment>
+ <artifact>org.apache.portals.jetspeed-2:rss:war</artifact>
+ <delete>./rss</delete>
+ </deployment>
+ <deployment>
+ <artifact>org.apache.portals.bridges:jpetstore:war</artifact>
+ <infuse>true</infuse>
+ <delete>./jpetstore</delete>
+ </deployment>
+ <deployment>
+ <artifact>org.apache.portals.bridges:jsf-demo:war</artifact>
+ <infuse>true</infuse>
+ <expand>true</expand>
+ <delete>./jsf-demo</delete>
+ </deployment>
+ </deployments>
+ </configuration>
+ </execution>
+ </executions>
+
+ <dependencies>
+ <!-- shared/lib deps -->
+ <dependency>
+ <groupId>portlet-api</groupId>
+ <artifactId>portlet-api</artifactId>
+ <version>${portlet-api.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-api</artifactId>
+ <version>${org.apache.portals.jetspeed.version}</version>
+ <scope>runtime</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-commons</artifactId>
+ <version>${org.apache.portals.jetspeed.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.pluto</groupId>
+ <artifactId>pluto</artifactId>
+ <version>${org.apache.pluto.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.portals.bridges</groupId>
+ <artifactId>portals-bridges-common</artifactId>
+ <version>${org.apache.portals.bridges.common.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>${org.apache.jetspeed.production.jdbc.driver.groupId}</groupId>
+ <artifactId>${org.apache.jetspeed.production.jdbc.driver.artifactId}</artifactId>
+ <version>${org.apache.jetspeed.production.jdbc.driver.version}</version>
+ </dependency>
+ <!-- jetspeed-demo -->
+ <dependency>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-demo</artifactId>
+ <version>${pom.version}</version>
+ <type>war</type>
+ </dependency>
+ <!-- j2-admin -->
+ <dependency>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>j2-admin</artifactId>
+ <version>${org.apache.portals.jetspeed.version}</version>
+ <type>war</type>
+ </dependency>
+ <!-- demo pa's -->
+ <dependency>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>rss</artifactId>
+ <version>2.1.3</version>
+ <type>war</type>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>demo</artifactId>
+ <version>2.1.3</version>
+ <type>war</type>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.portals.bridges</groupId>
+ <artifactId>jsf-demo</artifactId>
+ <version>1.0.4</version>
+ <type>war</type>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.portals.bridges</groupId>
+ <artifactId>jpetstore</artifactId>
+ <version>1.0.4</version>
+ <type>war</type>
+ </dependency>
+
+ <!-- plugin own dependencies -->
+ <dependency>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-deploy-tools</artifactId>
+ <version>${org.apache.portals.jetspeed.version}</version>
+ </dependency>
+ </dependencies>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+
+ </profiles>
+
+</project>
Propchange: portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/jetspeed-mvn-demo-pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/jetspeed-mvn-demo-pom.xml
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/jetspeed-mvn-demo-pom.xml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Modified: portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/pom.xml
URL:
http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/pom.xml?rev=678019&r1=678018&r2=678019&view=diff==============================================================================
--- portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/pom.xml (original)
+++ portals/jetspeed-2/portal/trunk/applications/jetspeed-demo/pom.xml Fri Jul 18 12:57:49 2008
@@ -25,14 +25,21 @@
<maven>2.0.9</maven>
</prerequisites>
- <groupId>org.apache.portals.jetspeed-2</groupId>
<artifactId>jetspeed-demo</artifactId>
- <version>2.2-SNAPSHOT</version>
<name>Jetspeed-2 Demo Portal Application</name>
<description>Jetspeed-2 Demo Portal Application</description>
+ <parent>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>applications</artifactId>
+ <version>2.2-SNAPSHOT</version>
+ </parent>
<packaging>war</packaging>
+ <properties>
+ <org.apache.portals.jetspeed.version>${pom.version}</org.apache.portals.jetspeed.version>
+ </properties>
+
<dependencies>
<dependency>
<groupId>org.apache.portals.jetspeed-2</groupId>
@@ -49,17 +56,8 @@
</dependency>
</dependencies>
- <properties>
- <portlet-api.version>1.0</portlet-api.version>
- <org.apache.portals.jetspeed.version>2.2-SNAPSHOT</org.apache.portals.jetspeed.version>
- <org.apache.pluto.version>1.0.1</org.apache.pluto.version>
- <org.apache.portals.bridges.common.version>1.0.4</org.apache.portals.bridges.common.version>
- <portal.context.name>jetspeed</portal.context.name>
- <org.apache.jetspeed.server.home>${project.build.directory}/demo-deploy</org.apache.jetspeed.server.home>
- </properties>
-
<build>
- <finalName>${portal.context.name}</finalName>
+ <defaultGoal>install</defaultGoal>
<plugins>
<plugin>
<groupId>org.apache.portals.jetspeed-2</groupId>
@@ -133,6 +131,7 @@
<artifactId>maven-war-plugin</artifactId>
<version>2.0.2</version>
<configuration>
+ <warName>${pom.artifactId}</warName>
<webResources>
<resource>
<directory>${project.build.directory}/resources</directory>
@@ -146,285 +145,6 @@
<profiles>
<profile>
- <id>demo</id>
- <build>
- <plugins>
-
- <plugin>
- <groupId>org.apache.portals.jetspeed-2</groupId>
- <artifactId>jetspeed-db-maven-plugin</artifactId>
- <version>${org.apache.portals.jetspeed.version}</version>
- <goals>
- <goal>init</goal>
- </goals>
- <configuration>
- <connection>
- <username>${org.apache.jetspeed.production.database.user}</username>
- <password>${org.apache.jetspeed.production.database.password}</password>
- <url>${org.apache.jetspeed.production.database.url}</url>
- <driver>${org.apache.jetspeed.production.database.driver}</driver>
- </connection>
- <unpack>
- <artifact>org.apache.portals.jetspeed-2:jetspeed-portal-resources:jar</artifact>
- <resources>
- <resource>
- <path>ddl</path>
- <include>${org.apache.jetspeed.production.database.default.name}/</include>
- <destination>db/ddl</destination>
- </resource>
- <resource>
- <path>seed</path>
- <destination>db/seed</destination>
- </resource>
- </resources>
- </unpack>
- <sql>
- <scripts>
- <script>
- <path>
- ${project.build.directory}/db/ddl/${org.apache.jetspeed.production.database.default.name}/drop-schema.sql
- </path>
- <ignoreErrors>true</ignoreErrors>
- </script>
- <script>
- <path>
- ${project.build.directory}/db/ddl/${org.apache.jetspeed.production.database.default.name}/create-schema.sql
- </path>
- </script>
- </scripts>
- </sql>
- <seed>
- <categories>serializer</categories>
- <filterPropertiesFileName>
- ${project.build.directory}/${project.build.finalName}/WEB-INF/conf/spring-filter.properties
- </filterPropertiesFileName>
- <applicationRootPath>${project.build.directory}/${project.build.finalName}</applicationRootPath>
- <files>
- <file>${project.build.directory}/db/seed/j2-seed.xml</file>
- </files>
- <initProperties>
- <org.apache.jetspeed.database.user>
- ${org.apache.jetspeed.production.database.user}
- </org.apache.jetspeed.database.user>
- <org.apache.jetspeed.database.password>
- ${org.apache.jetspeed.production.database.password}
- </org.apache.jetspeed.database.password>
- <org.apache.jetspeed.database.url>
- ${org.apache.jetspeed.production.database.url}
- </org.apache.jetspeed.database.url>
- <org.apache.jetspeed.database.driver>
- ${org.apache.jetspeed.production.database.driver}
- </org.apache.jetspeed.database.driver>
- </initProperties>
- </seed>
- </configuration>
- <dependencies>
- <dependency>
- <groupId>org.apache.portals.jetspeed-2</groupId>
- <artifactId>jetspeed-portal-resources</artifactId>
- <version>${org.apache.portals.jetspeed.version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.portals.jetspeed-2</groupId>
- <artifactId>jetspeed-db-tools</artifactId>
- <version>${org.apache.portals.jetspeed.version}</version>
- </dependency>
- <dependency>
- <groupId>${org.apache.jetspeed.production.jdbc.driver.groupId}</groupId>
- <artifactId>${org.apache.jetspeed.production.jdbc.driver.artifactId}</artifactId>
- <version>${org.apache.jetspeed.production.jdbc.driver.version}</version>
- </dependency>
- </dependencies>
- </plugin>
-
- <plugin>
- <groupId>org.apache.portals.jetspeed-2</groupId>
- <artifactId>jetspeed-deploy-maven-plugin</artifactId>
- <version>${org.apache.portals.jetspeed.version}</version>
- <configuration>
- <targetBaseDir>${org.apache.jetspeed.server.home}</targetBaseDir>
- <portalName>${portal.context.name}</portalName>
- <deployments>
- <!-- shared/lib -->
- <deployment>
- <artifact>portlet-api:portlet-api:jar</artifact>
- </deployment>
- <deployment>
- <artifact>org.apache.portals.jetspeed-2:jetspeed-api:jar</artifact>
- </deployment>
- <deployment>
- <artifact>org.apache.portals.jetspeed-2:jetspeed-commons:jar</artifact>
- </deployment>
- <deployment>
- <artifact>org.apache.pluto:pluto:jar</artifact>
- </deployment>
- <deployment>
- <artifact>org.apache.portals.bridges:portals-bridges-common:jar</artifact>
- </deployment>
- <deployment>
- <artifact>
- ${org.apache.jetspeed.production.jdbc.driver.groupId}:${org.apache.jetspeed.production.jdbc.driver.artifactId}:jar
- </artifact>
- <destination>system</destination>
- </deployment>
- <!-- jetspeed portal expanded -->
- <deployment>
- <artifact>${pom.groupId}:${pom.artifactId}:war</artifact>
- <expand>true</expand>
- <targetName>${portal.context.name}</targetName>
- <delete>./${portal.context.name}</delete>
- </deployment>
- <!-- admin pa -->
- <deployment>
- <artifact>org.apache.portals.jetspeed-2:j2-admin:war</artifact>
- <delete>./j2-admin</delete>
- </deployment>
- <!-- demo pa's -->
- <deployment>
- <artifact>org.apache.portals.jetspeed-2:demo:war</artifact>
- <delete>./demo</delete>
- </deployment>
- <deployment>
- <artifact>org.apache.portals.jetspeed-2:rss:war</artifact>
- <delete>./rss</delete>
- </deployment>
- <deployment>
- <artifact>org.apache.portals.bridges:jpetstore:war</artifact>
- <infuse>true</infuse>
- <delete>./jpetstore</delete>
- </deployment>
- <deployment>
- <artifact>org.apache.portals.bridges:jsf-demo:war</artifact>
- <infuse>true</infuse>
- <expand>true</expand>
- <delete>./jsf-demo</delete>
- </deployment>
- </deployments>
- </configuration>
- <dependencies>
- <!-- shared/lib deps -->
- <dependency>
- <groupId>${pom.groupId}</groupId>
- <artifactId>${pom.artifactId}</artifactId>
- <version>${pom.version}</version>
- <type>war</type>
- </dependency>
- <dependency>
- <groupId>portlet-api</groupId>
- <artifactId>portlet-api</artifactId>
- <version>${portlet-api.version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.portals.jetspeed-2</groupId>
- <artifactId>jetspeed-api</artifactId>
- <version>${org.apache.portals.jetspeed.version}</version>
- <scope>runtime</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.portals.jetspeed-2</groupId>
- <artifactId>jetspeed-commons</artifactId>
- <version>${org.apache.portals.jetspeed.version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.pluto</groupId>
- <artifactId>pluto</artifactId>
- <version>${org.apache.pluto.version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.portals.bridges</groupId>
- <artifactId>portals-bridges-common</artifactId>
- <version>${org.apache.portals.bridges.common.version}</version>
- </dependency>
- <dependency>
- <groupId>${org.apache.jetspeed.production.jdbc.driver.groupId}</groupId>
- <artifactId>${org.apache.jetspeed.production.jdbc.driver.artifactId}</artifactId>
- <version>${org.apache.jetspeed.production.jdbc.driver.version}</version>
- </dependency>
- <!-- j2-admin -->
- <dependency>
- <groupId>org.apache.portals.jetspeed-2</groupId>
- <artifactId>j2-admin</artifactId>
- <version>${org.apache.portals.jetspeed.version}</version>
- <type>war</type>
- </dependency>
- <!-- demo pa's -->
- <dependency>
- <groupId>org.apache.portals.jetspeed-2</groupId>
- <artifactId>rss</artifactId>
- <version>2.1.3</version>
- <type>war</type>
- </dependency>
- <dependency>
- <groupId>org.apache.portals.jetspeed-2</groupId>
- <artifactId>demo</artifactId>
- <version>2.1.3</version>
- <type>war</type>
- </dependency>
- <dependency>
- <groupId>org.apache.portals.bridges</groupId>
- <artifactId>jsf-demo</artifactId>
- <version>1.0.4</version>
- <type>war</type>
- </dependency>
- <dependency>
- <groupId>org.apache.portals.bridges</groupId>
- <artifactId>jpetstore</artifactId>
- <version>1.0.4</version>
- <type>war</type>
- </dependency>
-
- <!-- plugin own dependencies -->
- <dependency>
- <groupId>org.apache.portals.jetspeed-2</groupId>
- <artifactId>jetspeed-deploy-tools</artifactId>
- <version>${org.apache.portals.jetspeed.version}</version>
- </dependency>
- </dependencies>
- </plugin>
- </plugins>
- </build>
- </profile>
-
- <profile>
- <id>demo-dbpsml</id>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.portals.jetspeed-2</groupId>
- <artifactId>jetspeed-db-maven-plugin</artifactId>
- <version>${org.apache.portals.jetspeed.version}</version>
- <goals>
- <goal>init</goal>
- </goals>
- <configuration>
- <psml>
- <categories>pageSerializer</categories>
- <filterPropertiesFileName>
- ${project.build.directory}/${project.build.finalName}/WEB-INF/conf/spring-filter.properties
- </filterPropertiesFileName>
- <applicationRootPath>${project.build.directory}/${project.build.finalName}</applicationRootPath>
- <initProperties>
- <org.apache.jetspeed.database.user>
- ${org.apache.jetspeed.production.database.user}
- </org.apache.jetspeed.database.user>
- <org.apache.jetspeed.database.password>
- ${org.apache.jetspeed.production.database.password}
- </org.apache.jetspeed.database.password>
- <org.apache.jetspeed.database.url>
- ${org.apache.jetspeed.production.database.url}
- </org.apache.jetspeed.database.url>
- <org.apache.jetspeed.database.driver>
- ${org.apache.jetspeed.production.database.driver}
- </org.apache.jetspeed.database.driver>
- </initProperties>
- </psml>
- </configuration>
- </plugin>
- </plugins>
- </build>
- </profile>
-
- <profile>
<id>dbpsml</id>
<build>
<resources>
Added: portals/jetspeed-2/portal/trunk/jetspeed-mvn-db-init-pom.xml
URL:
http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-mvn-db-init-pom.xml?rev=678019&view=auto==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-mvn-db-init-pom.xml (added)
+++ portals/jetspeed-2/portal/trunk/jetspeed-mvn-db-init-pom.xml Fri Jul 18 12:57:49 2008
@@ -0,0 +1,112 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You 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.
+
+ $Id$
+-->
+<project xmlns="
http://maven.apache.org/POM/4.0.0" xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="
http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+ <modelVersion>4.0.0</modelVersion>
+ <prerequisites>
+ <maven>2.0.9</maven>
+ </prerequisites>
+
+ <artifactId>jetspeed-mvn-dbinit-pom</artifactId>
+ <name>Jetspeed-2 Maven Invoker Database Initialization</name>
+ <description>Jetspeed-2 Maven Invoker Database Initialization</description>
+ <parent>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>jetspeed-2</artifactId>
+ <version>2.2-SNAPSHOT</version>
+ </parent>
+ <packaging>pom</packaging>
+
+ <build>
+ <defaultGoal>process-resources</defaultGoal>
+
+ <plugins>
+ <plugin>
+ <groupId>${pom.groupId}</groupId>
+ <artifactId>jetspeed-db-maven-plugin</artifactId>
+ <version>${pom.version}</version>
+ <configuration>
+ <connection>
+ <username>${
org.apache.jetspeed.@...@.database.user}</username>
+ <password>${
org.apache.jetspeed.@...@.database.password}</password>
+ <url>${
org.apache.jetspeed.@...@.database.url}</url>
+ <driver>${
org.apache.jetspeed.@...@.database.driver}</driver>
+ </connection>
+ </configuration>
+ <executions>
+ <execution>
+ <id>unpack-ddl</id>
+ <goals>
+ <goal>init</goal>
+ </goals>
+ <phase>process-resources</phase>
+ <configuration>
+ <unpack>
+ <artifact>${groupId}:jetspeed-portal-resources:jar</artifact>
+ <resources>
+ <resource>
+ <path>ddl</path>
+ <destination>
ddl/@...@</destination>
+ <include>${
org.apache.jetspeed.@...@.database.default.name}/</include>
+ </resource>
+ </resources>
+ </unpack>
+ </configuration>
+ </execution>
+ <execution>
+ <id>execute-sql</id>
+ <goals>
+ <goal>init</goal>
+ </goals>
+ <phase>process-resources</phase>
+ <configuration>
+ <sql>
+ <scripts>
+ <script>
+ <path>${
project.build.directory}/ddl/@...@/${
org.apache.jetspeed.@...@.database.default.name}/drop-schema.sql</path>
+ <ignoreErrors>true</ignoreErrors>
+ </script>
+ <script>
+ <path>${
project.build.directory}/ddl/@...@/${
org.apache.jetspeed.@...@.database.default.name}/create-schema.sql</path>
+ </script>
+ </scripts>
+ </sql>
+ </configuration>
+ </execution>
+ </executions>
+ <dependencies>
+ <dependency>
+ <groupId>${groupId}</groupId>
+ <artifactId>jetspeed-portal-resources</artifactId>
+ <version>${pom.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>${
org.apache.jetspeed.@...@.jdbc.driver.groupId}</groupId>
+ <artifactId>${
org.apache.jetspeed.@...@.jdbc.driver.artifactId}</artifactId>
+ <version>${
org.apache.jetspeed.@...@.jdbc.driver.version}</version>
+ </dependency>
+ </dependencies>
+ </plugin>
+ </plugins>
+
+ </build>
+
+</project>
Propchange: portals/jetspeed-2/portal/trunk/jetspeed-mvn-db-init-pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: portals/jetspeed-2/portal/trunk/jetspeed-mvn-db-init-pom.xml
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: portals/jetspeed-2/portal/trunk/jetspeed-mvn-db-init-pom.xml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: portals/jetspeed-2/portal/trunk/jetspeed-mvn-settings-sample.xml
URL:
http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/jetspeed-mvn-settings-sample.xml?rev=678019&view=auto==============================================================================
--- portals/jetspeed-2/portal/trunk/jetspeed-mvn-settings-sample.xml (added)
+++ portals/jetspeed-2/portal/trunk/jetspeed-mvn-settings-sample.xml Fri Jul 18 12:57:49 2008
@@ -0,0 +1,95 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You 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.
+
+ jetspeed-mvn-settings.xml
+
+ This file is usually placed in your root project folder.
+ It can be used to provide a specific Maven settings.xml for usage with the jetspeed:mvn plugin
+ when executing specific targets, like database initialization or deployments.
+ This allows easier maintenance and configuration for different conditions and environments
+ like development|test|staging|production, *and* keeping these configurations with your
+ project source (version management).
+
+ By providing multiple profiles, it is easy to switch different settings by configuring the
+ specific profile(s) to be used for a specific jetspeed:mvn target with a <profiles> subelement.
+
+ Lookup and usage of the nearest jetspeed-mvn-settings.xml file, searching current project folder
+ and then upwards to the root project, is enabled by default.
+
+ The default lookup behavior can be disabled or overridden in 3 ways (in higest precedence order):
+
+ a) specify a custom settings.xml file in one of the target specific or general jetspeed-mvn properties
+ using key jetspeed.mvn.settings.xml
+ b) specify a specific settings.xml file for a target with a <settingsFile> element
+ c) configure <useSettings>false</useSettings> in the configuration of the jetspeed:mvn plugin
+ to disable using a custom settings.xml
+ d) lookup of the nearest jetspeed-mvn-settings.xml
+
+ $Id$
+-->
+<settings xmlns="
http://maven.apache.org/POM/4.0.0">
+
+ <profiles>
+
+ <!-- Sample Jetspeed Invoker (jetspeed:mvn plugin) Maven settings.xml configuration using embedded Derby-->
+ <profile>
+ <id>jetspeed-mvn-settings</id>
+ <activation>
+ <activeByDefault>true</activeByDefault>
+ </activation>
+ <properties>
+ <org.apache.jetspeed.services.autodeployment.user>j2deployer</org.apache.jetspeed.services.autodeployment.user>
+ <org.apache.jetspeed.services.autodeployment.password>j2deployer</org.apache.jetspeed.services.autodeployment.password>
+
+ <org.apache.jetspeed.server.home>@rootdir@/applications/jetspeed-demo/target/demo-deploy</org.apache.jetspeed.server.home>
+
+ <!-- demo embedded Derby database configurations -->
+
+ <!-- Production Derby jdbc driver artifact properties -->
+
+ <org.apache.jetspeed.production.jdbc.driver.groupId>org.apache.derby</org.apache.jetspeed.production.jdbc.driver.groupId>
+ <org.apache.jetspeed.production.jdbc.driver.artifactId>derby</org.apache.jetspeed.production.jdbc.driver.artifactId>
+ <org.apache.jetspeed.production.jdbc.driver.version>10.3.2.1</org.apache.jetspeed.production.jdbc.driver.version>
+
+ <!-- required production database configuration properties:
+ make sure to check/correct the database.url path location (e.g. /tmp on Linux usually is restricted)
+ -->
+ <org.apache.jetspeed.production.database.default.name>derby</org.apache.jetspeed.production.database.default.name>
+ <org.apache.jetspeed.production.database.url>jdbc:derby:/tmp/derby/productiondb;create=true</org.apache.jetspeed.production.database.url>
+ <org.apache.jetspeed.production.database.driver>org.apache.derby.jdbc.EmbeddedDriver</org.apache.jetspeed.production.database.driver>
+ <org.apache.jetspeed.production.database.user></org.apache.jetspeed.production.database.user>
+ <org.apache.jetspeed.production.database.password></org.apache.jetspeed.production.database.password>
+
+ <!-- Jetspeed Portal development test Derby database properties -->
+
+ <org.apache.jetspeed.test.jdbc.driver.groupId>org.apache.derby</org.apache.jetspeed.test.jdbc.driver.groupId>
+ <org.apache.jetspeed.test.jdbc.driver.artifactId>derby</org.apache.jetspeed.test.jdbc.driver.artifactId>
+ <org.apache.jetspeed.test.jdbc.driver.version>10.3.2.1</org.apache.jetspeed.test.jdbc.driver.version>
+
+ <!-- make sure to check/correct the database.url path location (e.g. /tmp on Linux usually is restricted) -->
+ <org.apache.jetspeed.test.database.default.name>derby</org.apache.jetspeed.test.database.default.name>
+ <org.apache.jetspeed.test.database.url>jdbc:derby:/tmp/derby/testdb;create=true</org.apache.jetspeed.test.database.url>
+ <org.apache.jetspeed.test.database.driver>org.apache.derby.jdbc.EmbeddedDriver</org.apache.jetspeed.test.database.driver>
+ <org.apache.jetspeed.test.database.user></org.apache.jetspeed.test.database.user>
+ <org.apache.jetspeed.test.database.password></org.apache.jetspeed.test.database.password>
+
+ </properties>
+ </profile>
+
+ </profiles>
+
+</settings>
Propchange: portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Fri Jul 18 12:57:49 2008
@@ -0,0 +1 @@
+target
Added: portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/pom.xml
URL:
http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/pom.xml?rev=678019&view=auto==============================================================================
--- portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/pom.xml (added)
+++ portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/pom.xml Fri Jul 18 12:57:49 2008
@@ -0,0 +1,93 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You 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.
+
+ $Id$
+-->
+<project xmlns="
http://maven.apache.org/POM/4.0.0" xmlns:xsi="
http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="
http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+ <modelVersion>4.0.0</modelVersion>
+ <prerequisites>
+ <maven>2.0.9</maven>
+ </prerequisites>
+
+ <artifactId>jetspeed-mvn-maven-plugin</artifactId>
+ <name>Jetspeed 2 Maven Invoker Plugin</name>
+ <description>Jetspeed 2 Maven Maven Invoker Plugin</description>
+ <parent>
+ <groupId>org.apache.portals.jetspeed-2</groupId>
+ <artifactId>maven</artifactId>
+ <version>2.2-SNAPSHOT</version>
+ </parent>
+ <packaging>maven-plugin</packaging>
+
+ <dependencies>
+ <dependency>
+ <groupId>${pom.groupId}</groupId>
+ <artifactId>jetspeed-maven-utils</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.maven.shared</groupId>
+ <artifactId>maven-invoker</artifactId>
+ <version>2.0.8</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.maven</groupId>
+ <artifactId>maven-project</artifactId>
+ <version>2.0.9</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.maven</groupId>
+ <artifactId>maven-plugin-api</artifactId>
+ <version>2.0.9</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.maven</groupId>
+ <artifactId>maven-artifact</artifactId>
+ <version>2.0.9</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.maven</groupId>
+ <artifactId>maven-settings</artifactId>
+ <version>2.0.9</version>
+ </dependency>
+ <dependency>
+ <groupId>org.beanshell</groupId>
+ <artifactId>bsh</artifactId>
+ <version>2.0b4</version>
+ </dependency>
+ <dependency>
+ <groupId>org.codehaus.plexus</groupId>
+ <artifactId>plexus-utils</artifactId>
+ <!-- TODO: 1.5.1 seems to cause problems with quoted commandline parameters containing spaces on Windows
+ see:
http://jira.codehaus.org/browse/MSHARED-21+ should be fixed with org.apache.maven.share:maven-invoker:2.0.9
+ -->
+ <version>1.5</version>
+ </dependency>
+ </dependencies>
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-plugin-plugin</artifactId>
+ <configuration>
+ <goalPrefix>jetspeed</goalPrefix>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+</project>
Propchange: portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/pom.xml
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/pom.xml
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/pom.xml
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/CompositeMap.java
URL:
http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/CompositeMap.java?rev=678019&view=auto==============================================================================
--- portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/CompositeMap.java (added)
+++ portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/CompositeMap.java Fri Jul 18 12:57:49 2008
@@ -0,0 +1,181 @@
+package org.apache.jetspeed.maven.plugins;
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you 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.
+ */
+
+import java.util.Collection;
+import java.util.Map;
+import java.util.Properties;
+import java.util.Set;
+
+import org.apache.maven.project.MavenProject;
+import org.codehaus.plexus.util.introspection.ReflectionValueExtractor;
+
+/**
+ * Copied from org.apache.maven.plugin.invoker.CompositeMap.java
+ *
+ * @author <a href="mailto:
olamy@...">olamy</a>
+ * @version $Id$
+ */
+public class CompositeMap implements Map
+{
+ private MavenProject mavenProject;
+
+ private Properties properties;
+
+ public CompositeMap( MavenProject mavenProject, Properties properties )
+ {
+ this.mavenProject = mavenProject;
+ this.properties = properties == null ? new Properties() : properties;
+ }
+
+ public Properties getProperties()
+ {
+ return properties;
+ }
+
+ /**
+ * @see java.util.Map#clear()
+ */
+ public void clear()
+ {
+ // nothing here
+ }
+
+ /**
+ * @see java.util.Map#containsKey(java.lang.Object)
+ */
+ public boolean containsKey( Object key )
+ {
+ if ( key == null )
+ {
+ return false;
+ }
+ try
+ {
+ Object evaluated = ReflectionValueExtractor.evaluate( (String) key, this.mavenProject );
+ return evaluated == null;
+ }
+ catch ( Exception e )
+ {
+ // uhm do we have to throw a RuntimeException here ?
+ }
+
+ return ( mavenProject.getProperties().containsKey( key ) || properties.containsKey( key ) );
+ }
+
+ /**
+ * @see java.util.Map#containsValue(java.lang.Object)
+ */
+ public boolean containsValue( Object value )
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /**
+ * @see java.util.Map#entrySet()
+ */
+ public Set entrySet()
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /**
+ * @see java.util.Map#get(java.lang.Object)
+ */
+ public Object get( Object key )
+ {
+ if ( key == null )
+ {
+ return null;
+ }
+ try
+ {
+ Object evaluated = ReflectionValueExtractor.evaluate( (String) key, this.mavenProject );
+ if ( evaluated != null )
+ {
+ return evaluated;
+ }
+ }
+ catch ( Exception e )
+ {
+ // uhm do we have to throw a RuntimeException here ?
+ }
+
+ Object value = properties.get( key );
+
+ return ( value != null ? value : this.mavenProject.getProperties().get( key ) );
+
+ }
+
+ /**
+ * @see java.util.Map#isEmpty()
+ */
+ public boolean isEmpty()
+ {
+ return this.mavenProject == null && this.mavenProject.getProperties().isEmpty() && this.properties.isEmpty();
+ }
+
+ /**
+ * @see java.util.Map#keySet()
+ */
+ public Set keySet()
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /**
+ * @see java.util.Map#put(java.lang.Object, java.lang.Object)
+ */
+ public Object put( Object key, Object value )
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /**
+ * @see java.util.Map#putAll(java.util.Map)
+ */
+ public void putAll( Map t )
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /**
+ * @see java.util.Map#remove(java.lang.Object)
+ */
+ public Object remove( Object key )
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /**
+ * @see java.util.Map#size()
+ */
+ public int size()
+ {
+ throw new UnsupportedOperationException();
+ }
+
+ /**
+ * @see java.util.Map#values()
+ */
+ public Collection values()
+ {
+ throw new UnsupportedOperationException();
+ }
+}
Propchange: portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/CompositeMap.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/CompositeMap.java
------------------------------------------------------------------------------
svn:keywords = Id
Propchange: portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/CompositeMap.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/MvnMojo.java
URL:
http://svn.apache.org/viewvc/portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/MvnMojo.java?rev=678019&view=auto==============================================================================
--- portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/MvnMojo.java (added)
+++ portals/jetspeed-2/portal/trunk/maven/jetspeed-mvn-maven-plugin/src/main/java/org/apache/jetspeed/maven/plugins/MvnMojo.java Fri Jul 18 12:57:49 2008
@@ -0,0 +1,600 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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.apache.jetspeed.maven.plugins;
+
+import java.io.BufferedReader;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.io.Writer;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.Properties;
+
+import org.apache.maven.plugin.AbstractMojo;
+import org.apache.maven.plugin.MojoExecutionException;
+import org.apache.maven.plugin.MojoFailureException;
+import org.apache.maven.project.MavenProject;
+import org.apache.maven.settings.Settings;
+import org.apache.maven.shared.invoker.CommandLineConfigurationException;
+import org.apache.maven.shared.invoker.DefaultInvocationRequest;
+import org.apache.maven.shared.invoker.InvocationRequest;
+import org.apache.maven.shared.invoker.InvocationResult;
+import org.apache.maven.shared.invoker.Invoker;
+import org.apache.maven.shared.invoker.MavenCommandLineBuilder;
+import org.apache.maven.shared.invoker.MavenInvocationException;
+import org.apache.maven.shared.invoker.SystemOutLogger;
+import org.codehaus.plexus.util.IOUtil;
+import org.codehaus.plexus.util.InterpolationFilterReader;
+import org.codehaus.plexus.util.ReaderFactory;
+import org.codehaus.plexus.util.StringUtils;
+import org.codehaus.plexus.util.WriterFactory;
+import org.codehaus.plexus.util.cli.CommandLineException;
+import org.codehaus.plexus.util.interpolation.MapBasedValueSource;
+import org.codehaus.plexus.util.interpolation.RegexBasedInterpolator;
+
+/**
+ * Based upon org.apache.maven.plugin.invoker.InvokerMojo.java, r655038
+ *
+ * @goal mvn
+ * @aggregator
+ * @requiresDirectInvocation true
+ * @author <a href="mailto:
ate@...">Ate Douma</a>
+ * @version $Id$
+ */
+public class MvnMojo extends AbstractMojo
+{
+ public static class Target
+ {
+ public Target()
+ {
+ }
+
+ public Target(String name)
+ {
+ this.name = name;
+ init();
+ }
+
+ public void init()
+ {
+ if (properties == null)
+ {
+ properties = new HashMap<String,String>();
+ }
+ }
+
+ protected String id;
+ protected String name;
+ protected String dir;
+ protected String settingsFile;
+ protected String goals;
+ protected String profiles;
+ protected String depends;
+ protected Map<String,String> properties;
+ protected String mavenOpts;
+
+ public String toString()
+