mirror of
https://github.com/Alfresco/alfresco-sdk.git
synced 2025-07-31 17:39:14 +00:00
- closes issue #251
- refactored h2 support to play nicely with IDEs and across the aio and amp archetype use cases - now moved the h2 support for the default alfresco version in the alfresco-rad project, as part of the rapid application development features - tested all cmd line and eclipse based scenarios - consolidated alfresco.community.default version and alfresco.enterprise.default version and made them parametric in the whole project
This commit is contained in:
@@ -10,7 +10,7 @@
|
|||||||
<defaultValue>org.alfresco</defaultValue>
|
<defaultValue>org.alfresco</defaultValue>
|
||||||
</requiredProperty>
|
</requiredProperty>
|
||||||
<requiredProperty key="alfresco_target_version">
|
<requiredProperty key="alfresco_target_version">
|
||||||
<defaultValue>5.0.c</defaultValue>
|
<defaultValue>@@alfresco.community.default.version@@</defaultValue>
|
||||||
</requiredProperty>
|
</requiredProperty>
|
||||||
<requiredProperty key="package">
|
<requiredProperty key="package">
|
||||||
<defaultValue>(not used)</defaultValue>
|
<defaultValue>(not used)</defaultValue>
|
||||||
|
@@ -23,6 +23,7 @@
|
|||||||
<includes>
|
<includes>
|
||||||
<include>archetype-resources/pom.xml</include>
|
<include>archetype-resources/pom.xml</include>
|
||||||
<include>archetype-resources/run.sh</include>
|
<include>archetype-resources/run.sh</include>
|
||||||
|
<include>META-INF/maven/archetype-metadata.xml</include>
|
||||||
</includes>
|
</includes>
|
||||||
<filtering>true</filtering>
|
<filtering>true</filtering>
|
||||||
</resource>
|
</resource>
|
||||||
@@ -31,6 +32,7 @@
|
|||||||
<excludes>
|
<excludes>
|
||||||
<exclude>archetype-resources/pom.xml</exclude>
|
<exclude>archetype-resources/pom.xml</exclude>
|
||||||
<exclude>archetype-resources/run.sh</exclude>
|
<exclude>archetype-resources/run.sh</exclude>
|
||||||
|
<exclude>META-INF/maven/archetype-metadata.xml</exclude>
|
||||||
</excludes>
|
</excludes>
|
||||||
<filtering>false</filtering>
|
<filtering>false</filtering>
|
||||||
</resource>
|
</resource>
|
||||||
|
@@ -10,7 +10,7 @@
|
|||||||
<defaultValue>org.alfresco</defaultValue>
|
<defaultValue>org.alfresco</defaultValue>
|
||||||
</requiredProperty>
|
</requiredProperty>
|
||||||
<requiredProperty key="alfresco_target_version">
|
<requiredProperty key="alfresco_target_version">
|
||||||
<defaultValue>5.0.c</defaultValue>
|
<defaultValue>@@alfresco.community.default.version@@</defaultValue>
|
||||||
</requiredProperty>
|
</requiredProperty>
|
||||||
<requiredProperty key="package">
|
<requiredProperty key="package">
|
||||||
<defaultValue>(not used)</defaultValue>
|
<defaultValue>(not used)</defaultValue>
|
||||||
|
@@ -23,6 +23,7 @@
|
|||||||
<includes>
|
<includes>
|
||||||
<include>archetype-resources/pom.xml</include>
|
<include>archetype-resources/pom.xml</include>
|
||||||
<include>archetype-resources/run.sh</include>
|
<include>archetype-resources/run.sh</include>
|
||||||
|
<include>META-INF/maven/archetype-metadata.xml</include>
|
||||||
</includes>
|
</includes>
|
||||||
<filtering>true</filtering>
|
<filtering>true</filtering>
|
||||||
</resource>
|
</resource>
|
||||||
@@ -31,6 +32,7 @@
|
|||||||
<excludes>
|
<excludes>
|
||||||
<exclude>archetype-resources/pom.xml</exclude>
|
<exclude>archetype-resources/pom.xml</exclude>
|
||||||
<exclude>archetype-resources/run.sh</exclude>
|
<exclude>archetype-resources/run.sh</exclude>
|
||||||
|
<exclude>META-INF/maven/archetype-metadata.xml</exclude>
|
||||||
</excludes>
|
</excludes>
|
||||||
<filtering>false</filtering>
|
<filtering>false</filtering>
|
||||||
</resource>
|
</resource>
|
||||||
|
@@ -10,7 +10,7 @@
|
|||||||
<defaultValue>org.alfresco</defaultValue>
|
<defaultValue>org.alfresco</defaultValue>
|
||||||
</requiredProperty>
|
</requiredProperty>
|
||||||
<requiredProperty key="alfresco_target_version">
|
<requiredProperty key="alfresco_target_version">
|
||||||
<defaultValue>5.0.c</defaultValue>
|
<defaultValue>@@alfresco.community.default.version@@</defaultValue>
|
||||||
</requiredProperty>
|
</requiredProperty>
|
||||||
<requiredProperty key="package">
|
<requiredProperty key="package">
|
||||||
<defaultValue>(not used)</defaultValue>
|
<defaultValue>(not used)</defaultValue>
|
||||||
|
@@ -13,6 +13,9 @@
|
|||||||
<relativePath>../../pom.xml</relativePath>
|
<relativePath>../../pom.xml</relativePath>
|
||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
|
<properties>
|
||||||
|
<pgsql.dialect.folder>${project.build.directory}/pg-dialect-tmp</pgsql.dialect.folder>
|
||||||
|
</properties>
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<!-- Enables JUnit remote testing (using JRebel) -->
|
<!-- Enables JUnit remote testing (using JRebel) -->
|
||||||
<dependency>
|
<dependency>
|
||||||
@@ -35,5 +38,88 @@
|
|||||||
<type>jar</type>
|
<type>jar</type>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
<!-- Copied PostgreSQL dialect files to generate H2 dialect files on-the-fly -->
|
||||||
|
<plugin>
|
||||||
|
<artifactId>maven-dependency-plugin</artifactId>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>extract-postgres-dialect</id>
|
||||||
|
<phase>generate-test-resources</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>unpack</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<artifactItems>
|
||||||
|
<artifactItem>
|
||||||
|
<groupId>org.alfresco</groupId>
|
||||||
|
<artifactId>alfresco-repository</artifactId>
|
||||||
|
<version>${alfresco.community.default.version}</version>
|
||||||
|
<includes>alfresco/dbscripts/create/org.hibernate.dialect.PostgreSQLDialect/*,alfresco/dbscripts/upgrade/*/org.hibernate.dialect.PostgreSQLDialect/*,alfresco/ibatis/org.hibernate.dialect.PostgreSQLDialect/*</includes>
|
||||||
|
<outputDirectory>${pgsql.dialect.folder}</outputDirectory>
|
||||||
|
</artifactItem>
|
||||||
|
</artifactItems>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<artifactId>maven-resources-plugin</artifactId>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>generate-h2-dialect</id>
|
||||||
|
<phase>generate-test-resources</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>copy-resources</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<outputDirectory>${project.build.outputDirectory}</outputDirectory>
|
||||||
|
<resources>
|
||||||
|
<resource>
|
||||||
|
<directory>${pgsql.dialect.folder}/alfresco/dbscripts/create/org.hibernate.dialect.PostgreSQLDialect</directory>
|
||||||
|
<includes>
|
||||||
|
<include>*</include>
|
||||||
|
</includes>
|
||||||
|
<targetPath>alfresco/dbscripts/create/org.hibernate.dialect.H2Dialect</targetPath>
|
||||||
|
</resource>
|
||||||
|
<resource>
|
||||||
|
<directory>${pgsql.dialect.folder}/alfresco/ibatis/org.hibernate.dialect.PostgreSQLDialect</directory>
|
||||||
|
<includes>
|
||||||
|
<include>*</include>
|
||||||
|
</includes>
|
||||||
|
<targetPath>alfresco/ibatis/org.hibernate.dialect.H2Dialect</targetPath>
|
||||||
|
</resource>
|
||||||
|
<!-- Upgrade scripts -->
|
||||||
|
<resource>
|
||||||
|
<directory>${pgsql.dialect.folder}/alfresco/dbscripts/upgrade/4.1/org.hibernate.dialect.PostgreSQLDialect</directory>
|
||||||
|
<includes>
|
||||||
|
<include>*</include>
|
||||||
|
</includes>
|
||||||
|
<targetPath>alfresco/dbscripts/upgrade/4.1/org.hibernate.dialect.H2Dialect</targetPath>
|
||||||
|
</resource>
|
||||||
|
<resource>
|
||||||
|
<directory>${pgsql.dialect.folder}/alfresco/dbscripts/upgrade/4.2/org.hibernate.dialect.PostgreSQLDialect</directory>
|
||||||
|
<includes>
|
||||||
|
<include>*</include>
|
||||||
|
</includes>
|
||||||
|
<targetPath>alfresco/dbscripts/upgrade/4.2/org.hibernate.dialect.H2Dialect</targetPath>
|
||||||
|
</resource>
|
||||||
|
<resource>
|
||||||
|
<directory>${pgsql.dialect.folder}/alfresco/dbscripts/upgrade/5.0/org.hibernate.dialect.PostgreSQLDialect</directory>
|
||||||
|
<includes>
|
||||||
|
<include>*</include>
|
||||||
|
</includes>
|
||||||
|
<targetPath>alfresco/dbscripts/upgrade/5.0/org.hibernate.dialect.H2Dialect</targetPath>
|
||||||
|
</resource>
|
||||||
|
</resources>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
|
||||||
|
</build>
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
@@ -113,7 +113,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.alfresco</groupId>
|
<groupId>org.alfresco</groupId>
|
||||||
<artifactId>alfresco-mmt</artifactId>
|
<artifactId>alfresco-mmt</artifactId>
|
||||||
<version>5.0.c</version>
|
<version>${alfresco.community.default.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.alfrescolabs.alfresco-technical-validation</groupId>
|
<groupId>org.alfrescolabs.alfresco-technical-validation</groupId>
|
||||||
|
2
pom.xml
2
pom.xml
@@ -120,6 +120,8 @@
|
|||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
<maven.archetype.version>2.2</maven.archetype.version>
|
<maven.archetype.version>2.2</maven.archetype.version>
|
||||||
<alfresco.sdk.parent.version>${project.version}</alfresco.sdk.parent.version>
|
<alfresco.sdk.parent.version>${project.version}</alfresco.sdk.parent.version>
|
||||||
|
<alfresco.community.default.version>5.0.c</alfresco.community.default.version>
|
||||||
|
<alfresco.enterprise.default.version>5.0</alfresco.enterprise.default.version>
|
||||||
<springloaded.version>1.2.0.RELEASE</springloaded.version>
|
<springloaded.version>1.2.0.RELEASE</springloaded.version>
|
||||||
<scm.url.base>https://github.com/Alfresco/alfresco-sdk</scm.url.base>
|
<scm.url.base>https://github.com/Alfresco/alfresco-sdk</scm.url.base>
|
||||||
</properties>
|
</properties>
|
||||||
|
@@ -37,7 +37,7 @@
|
|||||||
| For available versions please search on https://artifacts.alfresco.com/nexus/index.html
|
| For available versions please search on https://artifacts.alfresco.com/nexus/index.html
|
||||||
-->
|
-->
|
||||||
<alfresco.groupId>org.alfresco</alfresco.groupId>
|
<alfresco.groupId>org.alfresco</alfresco.groupId>
|
||||||
<alfresco.version>5.0.c</alfresco.version>
|
<alfresco.version>${alfresco.community.default.version}</alfresco.version>
|
||||||
<!-- By default uses community artifacts (alfresco|share). Overridden in the 'enterprise' profile, with 'alfresco-enterprise' and 'share-enterprise' -->
|
<!-- By default uses community artifacts (alfresco|share). Overridden in the 'enterprise' profile, with 'alfresco-enterprise' and 'share-enterprise' -->
|
||||||
<alfresco.repo.artifactId>alfresco</alfresco.repo.artifactId>
|
<alfresco.repo.artifactId>alfresco</alfresco.repo.artifactId>
|
||||||
<alfresco.share.artifactId>share</alfresco.share.artifactId>
|
<alfresco.share.artifactId>share</alfresco.share.artifactId>
|
||||||
@@ -496,7 +496,26 @@
|
|||||||
</resource>
|
</resource>
|
||||||
</resources>
|
</resources>
|
||||||
</configuration>
|
</configuration>
|
||||||
</execution>
|
</execution>
|
||||||
|
<execution>
|
||||||
|
<id>add-module-config-to-test-classpath</id>
|
||||||
|
<phase>process-test-resources</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>copy-resources</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<outputDirectory>${project.build.testOutputDirectory}</outputDirectory>
|
||||||
|
<resources>
|
||||||
|
<resource>
|
||||||
|
<directory>${app.amp.folder}/config</directory>
|
||||||
|
<includes>
|
||||||
|
<include>**/*</include>
|
||||||
|
</includes>
|
||||||
|
<filtering>${app.filtering.enabled}</filtering>
|
||||||
|
</resource>
|
||||||
|
</resources>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
</executions>
|
</executions>
|
||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
@@ -520,10 +539,6 @@
|
|||||||
<version>${maven.surefire.version}</version>
|
<version>${maven.surefire.version}</version>
|
||||||
<configuration>
|
<configuration>
|
||||||
<argLine>${app.testing.jvm.args}</argLine>
|
<argLine>${app.testing.jvm.args}</argLine>
|
||||||
<additionalClasspathElements>
|
|
||||||
<!-- Adds both the module config to test classpath -->
|
|
||||||
<additionalClasspathElement>${project.build.directory}/${project.build.finalName}/config</additionalClasspathElement>
|
|
||||||
</additionalClasspathElements>
|
|
||||||
</configuration>
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
@@ -792,7 +807,7 @@
|
|||||||
<profile>
|
<profile>
|
||||||
<id>enterprise</id>
|
<id>enterprise</id>
|
||||||
<properties>
|
<properties>
|
||||||
<alfresco.version>5.0</alfresco.version>
|
<alfresco.version>${alfresco.enterprise.default.version}</alfresco.version>
|
||||||
<alfresco.repo.artifactId>alfresco-enterprise</alfresco.repo.artifactId>
|
<alfresco.repo.artifactId>alfresco-enterprise</alfresco.repo.artifactId>
|
||||||
<alfresco.share.artifactId>share-enterprise</alfresco.share.artifactId>
|
<alfresco.share.artifactId>share-enterprise</alfresco.share.artifactId>
|
||||||
<!-- Not needed in the webapp for enterprise -->
|
<!-- Not needed in the webapp for enterprise -->
|
||||||
@@ -879,7 +894,6 @@
|
|||||||
</build>
|
</build>
|
||||||
</profile>
|
</profile>
|
||||||
<!-- Configures automatic embedded H2 database support for repository amps (if a test alfresco-global.properties is found) -->
|
<!-- Configures automatic embedded H2 database support for repository amps (if a test alfresco-global.properties is found) -->
|
||||||
<!-- TODO: Improve this, either by producing this dialect upstream or consolidating behavior in a parent pom (current only activation clause changes) -->
|
|
||||||
<profile>
|
<profile>
|
||||||
<id>config-h2-support</id>
|
<id>config-h2-support</id>
|
||||||
<activation>
|
<activation>
|
||||||
@@ -887,87 +901,6 @@
|
|||||||
<exists>src/test/properties/local/alfresco-global.properties</exists>
|
<exists>src/test/properties/local/alfresco-global.properties</exists>
|
||||||
</file>
|
</file>
|
||||||
</activation>
|
</activation>
|
||||||
<build>
|
|
||||||
<plugins>
|
|
||||||
<!-- Copied PostgreSQL dialect files to generate H2 dialect files on-the-fly -->
|
|
||||||
<plugin>
|
|
||||||
<artifactId>maven-dependency-plugin</artifactId>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<id>extract-postgres-dialect</id>
|
|
||||||
<phase>generate-test-resources</phase>
|
|
||||||
<goals>
|
|
||||||
<goal>unpack</goal>
|
|
||||||
</goals>
|
|
||||||
<configuration>
|
|
||||||
<artifactItems>
|
|
||||||
<artifactItem>
|
|
||||||
<groupId>${alfresco.groupId}</groupId>
|
|
||||||
<artifactId>alfresco-repository</artifactId>
|
|
||||||
<version>${alfresco.version}</version>
|
|
||||||
<includes>alfresco/dbscripts/create/org.hibernate.dialect.PostgreSQLDialect/*,alfresco/dbscripts/upgrade/*/org.hibernate.dialect.PostgreSQLDialect/*,alfresco/ibatis/org.hibernate.dialect.PostgreSQLDialect/*</includes>
|
|
||||||
<outputDirectory>${project.build.testOutputDirectory}</outputDirectory>
|
|
||||||
</artifactItem>
|
|
||||||
</artifactItems>
|
|
||||||
</configuration>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
<plugin>
|
|
||||||
<artifactId>maven-resources-plugin</artifactId>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<id>generate-h2-dialect</id>
|
|
||||||
<phase>generate-test-resources</phase>
|
|
||||||
<goals>
|
|
||||||
<goal>copy-resources</goal>
|
|
||||||
</goals>
|
|
||||||
<configuration>
|
|
||||||
<outputDirectory>${project.build.testOutputDirectory}</outputDirectory>
|
|
||||||
<resources>
|
|
||||||
<resource>
|
|
||||||
<directory>${project.build.testOutputDirectory}/alfresco/dbscripts/create/org.hibernate.dialect.PostgreSQLDialect</directory>
|
|
||||||
<includes>
|
|
||||||
<include>*</include>
|
|
||||||
</includes>
|
|
||||||
<targetPath>alfresco/dbscripts/create/org.hibernate.dialect.H2Dialect</targetPath>
|
|
||||||
</resource>
|
|
||||||
<resource>
|
|
||||||
<directory>${project.build.testOutputDirectory}/alfresco/ibatis/org.hibernate.dialect.PostgreSQLDialect</directory>
|
|
||||||
<includes>
|
|
||||||
<include>*</include>
|
|
||||||
</includes>
|
|
||||||
<targetPath>alfresco/ibatis/org.hibernate.dialect.H2Dialect</targetPath>
|
|
||||||
</resource>
|
|
||||||
<!-- Upgrade scripts -->
|
|
||||||
<resource>
|
|
||||||
<directory>${project.build.testOutputDirectory}/alfresco/dbscripts/upgrade/4.1/org.hibernate.dialect.PostgreSQLDialect</directory>
|
|
||||||
<includes>
|
|
||||||
<include>*</include>
|
|
||||||
</includes>
|
|
||||||
<targetPath>alfresco/dbscripts/upgrade/4.1/org.hibernate.dialect.H2Dialect</targetPath>
|
|
||||||
</resource>
|
|
||||||
<resource>
|
|
||||||
<directory>${project.build.testOutputDirectory}/alfresco/dbscripts/upgrade/4.2/org.hibernate.dialect.PostgreSQLDialect</directory>
|
|
||||||
<includes>
|
|
||||||
<include>*</include>
|
|
||||||
</includes>
|
|
||||||
<targetPath>alfresco/dbscripts/upgrade/4.2/org.hibernate.dialect.H2Dialect</targetPath>
|
|
||||||
</resource>
|
|
||||||
<resource>
|
|
||||||
<directory>${project.build.testOutputDirectory}/alfresco/dbscripts/upgrade/5.0/org.hibernate.dialect.PostgreSQLDialect</directory>
|
|
||||||
<includes>
|
|
||||||
<include>*</include>
|
|
||||||
</includes>
|
|
||||||
<targetPath>alfresco/dbscripts/upgrade/5.0/org.hibernate.dialect.H2Dialect</targetPath>
|
|
||||||
</resource>
|
|
||||||
</resources>
|
|
||||||
</configuration>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
</plugins>
|
|
||||||
</build>
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<!-- h2 Dependency -->
|
<!-- h2 Dependency -->
|
||||||
<dependency>
|
<dependency>
|
||||||
|
Reference in New Issue
Block a user