ACS-457: Build linkage, tagging and release (#4)

* ACS-457: Build linkage, tagging and release

- update .travis.settings.xml

* ACS-457: Build linkage, tagging and release

- add cleanup_cache.sh script

* ACS-457: Build linkage, tagging and release

- add init.sh script for before_install job phases

* ACS-457: Build linkage, tagging and release

- add build.sh script for install job phases

* ACS-457: Build linkage, tagging and release

- minor updates on the older travis and veracode scripts

* ACS-457: Build linkage, tagging and release

- reorganized and updated .travis.yml

* ACS-457: Build linkage, tagging and release

- add remote branch validation in the trigger_travis.sh script

* ACS-457: Build linkage, tagging and release

- update and propagate branch version numbers during the build

* ACS-457: Build linkage, tagging and release

- enable docker image squash for all image builds

* ACS-457: Build linkage, tagging and release

- shellcheck CI scripts

* ACS-457: Build linkage, tagging and release

- switch to TEST pom versions

* ACS-457: Build linkage, tagging and release

- post-merge fixes

* ACS-457: Build linkage, tagging and release

- update trigger_travis.sh scrips so they offer more debug info

* ACS-457: Build linkage, tagging and release

- clone upstream repositories with "--depth=1" (no history needed)
- add "-Dmaven.javadoc.skip=true" options in the build scripts

* ACS-457: Build linkage, tagging and release

- remove <scm> configuration from sub-modules
- remove <distributionManagement> configurations from submodules
- remove <repository> configuration from poms
- remove unnecessary and unused POM profiles

* ACS-457: Build linkage, tagging and release

- add pom <pluginManagement> section
- removed some plugin versions from downstream modules
- add a single common configuration for the *maven-relese-plugin*

* ACS-457: Build linkage, tagging and release

- post-merge fixes

* ACS-457: Build linkage, tagging and release

- update and reorganize the fabric8-maven-plugin configuration

* ACS-457: Build linkage, tagging and release

- extra debug info on the trigger_travis.sh scripts

* ACS-457: Build linkage, tagging and release

- modify the build.sh scripts so they checkout the upstream project tag

* ACS-457: Build linkage, tagging and release

- test different token variable for propagating builds

* ACS-457: Build linkage, tagging and release

- re-implement build.sh script logic to support PRs & branch builds
- restricted the build.sh script capabilities
- moved build functions to a separate .sh file

* ACS-457: Build linkage, tagging and release

- update release scripts

* ACS-457: Build linkage, tagging and release

- debug build scripts

* ACS-457: Build linkage, tagging and release

- fix build scripts

* ACS-457: Build linkage, tagging and release

- setup/update the S3 publishing jobs

* ACS-457: Build linkage, tagging and release

- update build scripts
- remove a few unnecessary TODOs

* ACS-457: Build linkage, tagging and release

- disable release jobs for now
This commit is contained in:
CezarLeahu
2020-08-12 00:24:51 +03:00
committed by GitHub
parent a660ce23ee
commit 3a0725ee77
27 changed files with 3818 additions and 3810 deletions

View File

@@ -25,10 +25,13 @@
<url>https://artifacts.alfresco.com/nexus/content/groups/public</url> <url>https://artifacts.alfresco.com/nexus/content/groups/public</url>
</pluginRepository> </pluginRepository>
</pluginRepositories> </pluginRepositories>
<properties>
<!-- WhiteSource token -->
<org.whitesource.orgToken>${env.WHITESOURCE_API_KEY}</org.whitesource.orgToken>
</properties>
</profile> </profile>
</profiles> </profiles>
<servers> <servers>
<server> <server>
<id>alfresco-public</id> <id>alfresco-public</id>

View File

@@ -1,268 +1,257 @@
dist: xenial ---
os: linux dist: xenial
language: java language: java
jdk: jdk: openjdk11
- openjdk11
services:
services: - docker
- docker
git:
cache: depth: false
directories: quiet: true
- $HOME/.m2
cache:
before_cache: directories:
- rm -rf $HOME/.m2/repository/org/alfresco/alfresco-community-repo - ${HOME}/.m2/repository
- rm -rf $HOME/.m2/repository/org/alfresco/alfresco-core
- rm -rf $HOME/.m2/repository/org/alfresco/alfresco-data-model # the cache can grow constantly
- rm -rf $HOME/.m2/repository/org/alfresco/alfresco-repository before_cache: bash scripts/travis/cleanup_cache.sh
- rm -rf $HOME/.m2/repository/org/alfresco/alfresco-remote-api
- rm -rf $HOME/.m2/repository/org/alfresco/content-services-community branches:
- rm -rf $HOME/.m2/repository/org/alfresco/alfresco-community-repo-* only:
- rm -rf $HOME/.m2/repository/org/alfresco/tas/alfresco-community-repo-*-test - master
- /release\/.*/
branches: - feature/ACS-457_travis-release-config
only:
- master env:
- /release\/.*/ global:
- TAS_SCRIPTS=../alfresco-community-repo/packaging/tests/scripts
env: - TAS_ENVIRONMENT=../alfresco-community-repo/packaging/tests/environment
global:
- TAS_SCRIPTS=../alfresco-community-repo/packaging/tests/scripts stages:
- TAS_ENVIRONMENT=../alfresco-community-repo/packaging/tests/environment - name: test
if: commit_message !~ /\[skip tests\]/
stages: - name: release
- name: test if: fork = false AND (branch = master OR branch =~ /release\/.*/) AND type != pull_request AND commit_message !~ /\[no-release\]/
if: commit_message !~ /\[skip tests\]/ - name: trigger_downstream
- release if: fork = false AND type != pull_request AND commit_message !~ /\[no-downstream\]/
- publish
- trigger_downstream before_install: travis_retry bash scripts/travis/init.sh
install: travis_retry bash scripts/travis/build.sh
before_install:
- "cp .travis.settings.xml $HOME/.m2/settings.xml" jobs:
- travis_retry mvn install -DskipTests=true -Dversion.edition=Community -PcommunityDocker -B -V include:
- name: "WhiteSource scan"
jobs: stage: test
include: # only on release branches or master and if it is not a PR
- stage: test if: fork = false AND (branch = master OR branch =~ /release\/.*/) AND type != pull_request
name: "WhiteSource scan" script:
# only on release branches or master and if it is not a PR # Download the latest version of WhiteSource Unified Agent
if: fork = false AND (branch = master OR branch =~ /release\/.*/) AND type != pull_request - curl -LJO https://github.com/whitesource/unified-agent-distribution/releases/latest/download/wss-unified-agent.jar
script: # Run WhiteSource Unified Agent
# Download the latest version of WhiteSource Unified Agent - java -jar wss-unified-agent.jar -apiKey ${WHITESOURCE_API_KEY} -c .wss-unified-agent.config -d ./packaging/war
- curl -LJO https://github.com/whitesource/unified-agent-distribution/releases/latest/download/wss-unified-agent.jar
# Run WhiteSource Unified Agent # - name: "Source Clear Scan"
- java -jar wss-unified-agent.jar -apiKey ${WHITESOURCE_API_KEY} -c .wss-unified-agent.config # # only on release branches or master and if it is not a PR
# if: fork = false AND (branch = master OR branch =~ /release\/.*/) AND type != pull_request
# - name: "Source Clear Scan" # script: skip
# # only on SP branches or master and if it is not a PR # addons:
# if: fork = false AND (branch = master OR branch =~ /release\/SP\/.*/) AND type != pull_request # srcclr: true
# script: skip
# addons: - name: "Core, Data-Model, Repository - AllUnitTestsSuite - Build and test"
# srcclr: true script:
- travis_retry mvn -B test -pl core,data-model
- name: "Core, Data-Model, Repository - AllUnitTestsSuite - Build and test" - travis_retry mvn -B test -pl repository -Dtest=AllUnitTestsSuite
script:
- travis_retry mvn test -pl core,data-model - name: "Repository - AppContext01TestSuite"
- mvn test -B -pl repository -Dtest=AllUnitTestsSuite before_script:
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
- name: "Repository - AppContext01TestSuite" - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
install: script: travis_wait 20 mvn -B test -pl repository -Dtest=AppContext01TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 - name: "Repository - AppContext02TestSuite"
script: travis_wait 20 mvn test -B -pl repository -Dtest=AppContext01TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco before_script:
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
- name: "Repository - AppContext02TestSuite" - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
install: script: travis_wait 20 mvn -B test -pl repository -Dtest=AppContext02TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 - name: "Repository - AppContext03TestSuite"
script: travis_wait 20 mvn test -B -pl repository -Dtest=AppContext02TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco before_script:
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
- name: "Repository - AppContext03TestSuite" - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
install: - docker run -d -p 8090:8090 -e JAVA_OPTS=" -Xms256m -Xmx256m" alfresco/alfresco-transform-core-aio:2.3.4
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' script: travis_wait 20 mvn -B test -pl repository -Dtest=AppContext03TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco -Dalfresco-pdf-renderer.url=http://localhost:8090/ -Djodconverter.url=http://localhost:8090/ -Dimg.url=http://localhost:8090/ -Dtika.url=http://localhost:8090/ -Dtransform.misc.url=http://localhost:8090/
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
- docker run -d -p 8090:8090 -e JAVA_OPTS=" -Xms256m -Xmx256m" alfresco/alfresco-transform-core-aio:2.3.4 - name: "Repository - AppContext04TestSuite"
script: travis_wait 20 mvn test -B -pl repository -Dtest=AppContext03TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco -Dalfresco-pdf-renderer.url=http://localhost:8090/ -Djodconverter.url=http://localhost:8090/ -Dimg.url=http://localhost:8090/ -Dtika.url=http://localhost:8090/ -Dtransform.misc.url=http://localhost:8090/ before_script:
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
- name: "Repository - AppContext04TestSuite" - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
install: - docker run -d -p 8090:8090 -e JAVA_OPTS=" -Xms256m -Xmx256m" alfresco/alfresco-transform-core-aio:2.3.4
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' script: travis_wait 20 mvn -B test -pl repository -Dtest=AppContext04TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
- docker run -d -p 8090:8090 -e JAVA_OPTS=" -Xms256m -Xmx256m" alfresco/alfresco-transform-core-aio:2.3.4 - name: "Repository - AppContext05TestSuite"
script: travis_wait 20 mvn test -B -pl repository -Dtest=AppContext04TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco before_script:
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
- name: "Repository - AppContext05TestSuite" - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
install: - mkdir -p "${HOME}/tmp"
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' - cp repository/src/test/resources/realms/alfresco-realm.json "${HOME}/tmp"
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 - export HOST_IP=$(hostname -I | cut -f1 -d' ')
- "mkdir -p $HOME/tmp" - docker run -d -e KEYCLOAK_USER=admin -e KEYCLOAK_PASSWORD=admin -e DB_VENDOR=h2 -p 8999:8080 -e KEYCLOAK_IMPORT=/tmp/alfresco-realm.json -v $HOME/tmp/alfresco-realm.json:/tmp/alfresco-realm.json quay.io/alfresco/alfresco-identity-service:1.2
- "cp repository/src/test/resources/realms/alfresco-realm.json $HOME/tmp" script: travis_wait 20 mvn -B test -pl repository -Dtest=AppContext05TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco "-Didentity-service.auth-server-url=http://${HOST_IP}:8999/auth"
- docker login quay.io -u ${QUAY_USERNAME} -p ${QUAY_PASSWORD}
- "export HOST_IP=$(ip address show | grep -E \"([0-9]{1,3}\\.){3}[0-9]{1,3}\" | grep -v 127.0.0.1 | awk '{ print $2 }' | head -n 1 )" - name: "Repository - AppContext06TestSuite"
- "export HOST_IP=$(echo ${HOST_IP%/*})" before_script:
- docker run -d -e KEYCLOAK_USER=admin -e KEYCLOAK_PASSWORD=admin -e DB_VENDOR=h2 -p 8999:8080 -e KEYCLOAK_IMPORT=/tmp/alfresco-realm.json -v $HOME/tmp/alfresco-realm.json:/tmp/alfresco-realm.json quay.io/alfresco/alfresco-identity-service:1.2 - docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
script: travis_wait 20 mvn test -B -pl repository -Dtest=AppContext05TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco "-Didentity-service.auth-server-url=http://${HOST_IP}:8999/auth" - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
- docker run -d -p 8090:8090 -e JAVA_OPTS=" -Xms256m -Xmx256m" alfresco/alfresco-transform-core-aio:2.3.4
- name: "Repository - AppContext06TestSuite" script: travis_wait 20 mvn -B test -pl repository -Dtest=AppContext06TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco -Dalfresco-pdf-renderer.url=http://localhost:8090/ -Djodconverter.url=http://localhost:8090/ -Dimg.url=http://localhost:8090/ -Dtika.url=http://localhost:8090/ -Dtransform.misc.url=http://localhost:8090/
install:
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' - name: "Repository - AppContextExtraTestSuite"
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 before_script:
- docker run -d -p 8090:8090 -e JAVA_OPTS=" -Xms256m -Xmx256m" alfresco/alfresco-transform-core-aio:2.3.4 - docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
script: travis_wait 20 mvn test -B -pl repository -Dtest=AppContext06TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco -Dalfresco-pdf-renderer.url=http://localhost:8090/ -Djodconverter.url=http://localhost:8090/ -Dimg.url=http://localhost:8090/ -Dtika.url=http://localhost:8090/ -Dtransform.misc.url=http://localhost:8090/ - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
script: travis_wait 20 mvn -B test -pl repository -Dtest=AppContextExtraTestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
- name: "Repository - AppContextExtraTestSuite"
install: - name: "Repository - MiscContextTestSuite"
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' before_script:
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 - docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
script: travis_wait 20 mvn test -B -pl repository -Dtest=AppContextExtraTestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
- docker run -d -p 8090:8090 -e JAVA_OPTS=" -Xms256m -Xmx256m" alfresco/alfresco-transform-core-aio:2.3.4
- name: "Repository - MiscContextTestSuite" script: travis_wait 20 mvn -B test -pl repository -Dtest=MiscContextTestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco -Dalfresco-pdf-renderer.url=http://localhost:8090/ -Djodconverter.url=http://localhost:8090/ -Dimg.url=http://localhost:8090/ -Dtika.url=http://localhost:8090/ -Dtransform.misc.url=http://localhost:8090/
install:
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' - name: "Repository - MySQL tests"
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 if: commit_message !~ /\[skip db\]/
- docker run -d -p 8090:8090 -e JAVA_OPTS=" -Xms256m -Xmx256m" alfresco/alfresco-transform-core-aio:2.3.4 before_script:
script: travis_wait 20 mvn test -B -pl repository -Dtest=MiscContextTestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco -Dalfresco-pdf-renderer.url=http://localhost:8090/ -Djodconverter.url=http://localhost:8090/ -Dimg.url=http://localhost:8090/ -Dtika.url=http://localhost:8090/ -Dtransform.misc.url=http://localhost:8090/ - docker run -d -p 3307:3306 -e MYSQL_ROOT_PASSWORD=alfresco -e MYSQL_USER=alfresco -e MYSQL_DATABASE=alfresco -e MYSQL_PASSWORD=alfresco mysql:5.7.23 --transaction-isolation='READ-COMMITTED'
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
- name: "Repository - MySQL tests" script: travis_wait 20 mvn -B test -pl repository -Dtest=AllDBTestsTestSuite -Ddb.driver=com.mysql.jdbc.Driver -Ddb.name=alfresco -Ddb.url=jdbc:mysql://localhost:3307/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
if: commit_message !~ /\[skip db\]/
install: - name: "Repository - PostgreSQL 10 tests"
- docker run -d -p 3307:3306 -e MYSQL_ROOT_PASSWORD=alfresco -e MYSQL_USER=alfresco -e MYSQL_DATABASE=alfresco -e MYSQL_PASSWORD=alfresco mysql:5.7.23 --transaction-isolation='READ-COMMITTED' if: commit_message !~ /\[skip db\]/
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 before_script:
script: travis_wait 20 mvn test -B -pl repository -Dtest=AllDBTestsTestSuite -Ddb.driver=com.mysql.jdbc.Driver -Ddb.name=alfresco -Ddb.url=jdbc:mysql://localhost:3307/alfresco -Ddb.username=alfresco -Ddb.password=alfresco - docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:10.9 postgres -c 'max_connections=300'
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
- name: "Repository - PostgreSQL 10 tests" script: travis_wait 20 mvn -B test -pl repository -Dtest=AllDBTestsTestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
if: commit_message !~ /\[skip db\]/
install: - name: "Repository - PostgreSQL 11 tests"
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:10.9 postgres -c 'max_connections=300' if: commit_message !~ /\[skip db\]/
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 before_script:
script: travis_wait 20 mvn test -B -pl repository -Dtest=AllDBTestsTestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco - docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
- name: "Repository - PostgreSQL 11 tests" script: travis_wait 20 mvn -B test -pl repository -Dtest=AllDBTestsTestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
if: commit_message !~ /\[skip db\]/
install: - name: "Repository - MariaDB tests"
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' if: commit_message !~ /\[skip db\]/
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 before_script:
script: travis_wait 20 mvn test -B -pl repository -Dtest=AllDBTestsTestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco - docker run -d -p 3307:3306 --name mariadb -e MYSQL_ROOT_PASSWORD=alfresco -e MYSQL_USER=alfresco -e MYSQL_DATABASE=alfresco -e MYSQL_PASSWORD=alfresco mariadb:10.2.18 --transaction-isolation=READ-COMMITTED --max-connections=300 --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
- name: "Repository - MariaDB tests" script: travis_wait 20 mvn -B test -pl repository -Dtest=AllDBTestsTestSuite -Ddb.name=alfresco -Ddb.url=jdbc:mariadb://localhost:3307/alfresco?useUnicode=yes\&characterEncoding=UTF-8 -Ddb.username=alfresco -Ddb.password=alfresco -Ddb.driver=org.mariadb.jdbc.Driver
if: commit_message !~ /\[skip db\]/
install: - name: "Remote-api - AppContext01TestSuite"
- docker run -d -p 3307:3306 --name mariadb -e MYSQL_ROOT_PASSWORD=alfresco -e MYSQL_USER=alfresco -e MYSQL_DATABASE=alfresco -e MYSQL_PASSWORD=alfresco mariadb:10.2.18 --transaction-isolation=READ-COMMITTED --max-connections=300 --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci before_script:
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 - docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
script: travis_wait 20 mvn test -B -pl repository -Dtest=AllDBTestsTestSuite -Ddb.name=alfresco -Ddb.url=jdbc:mariadb://localhost:3307/alfresco?useUnicode=yes\&characterEncoding=UTF-8 -Ddb.username=alfresco -Ddb.password=alfresco -Ddb.driver=org.mariadb.jdbc.Driver - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
script: travis_wait 20 mvn -B test -pl remote-api -Dtest=AppContext01TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
- name: "Remote-api - AppContext01TestSuite"
install: - name: "Remote-api - AppContext02TestSuite"
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' before_script:
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 - docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
script: travis_wait 20 mvn test -B -pl remote-api -Dtest=AppContext01TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
script: travis_wait 20 mvn -B test -pl remote-api -Dtest=AppContext02TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
- name: "Remote-api - AppContext02TestSuite"
install: - name: "Remote-api - AppContext03TestSuite"
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' before_script:
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 - docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
script: travis_wait 20 mvn test -B -pl remote-api -Dtest=AppContext02TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
script: travis_wait 20 mvn -B test -pl remote-api -Dtest=AppContext03TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
- name: "Remote-api - AppContext03TestSuite"
install: - name: "Remote-api - AppContext04TestSuite"
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' before_script:
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 - docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
script: travis_wait 20 mvn test -B -pl remote-api -Dtest=AppContext03TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
script: travis_wait 20 mvn -B test -pl remote-api -Dtest=AppContext04TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
- name: "Remote-api - AppContext04TestSuite"
install: - name: "Remote-api - AppContextExtraTestSuite"
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' before_script:
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 - docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300'
script: travis_wait 20 mvn test -B -pl remote-api -Dtest=AppContext04TestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco - docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8
script: travis_wait 20 mvn -B test -pl remote-api -Dtest=AppContextExtraTestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco
- name: "Remote-api - AppContextExtraTestSuite"
install: - name: "REST API TAS tests part1"
- docker run -d -p 5433:5432 -e POSTGRES_PASSWORD=alfresco -e POSTGRES_USER=alfresco -e POSTGRES_DB=alfresco postgres:11.7 postgres -c 'max_connections=300' if: commit_message =~ /\[tas\]/
- docker run -d -p 61616:61616 -p 5672:5672 alfresco/alfresco-activemq:5.15.8 before_script:
script: travis_wait 20 mvn test -B -pl remote-api -Dtest=AppContextExtraTestSuite -Ddb.driver=org.postgresql.Driver -Ddb.name=alfresco -Ddb.url=jdbc:postgresql://localhost:5433/alfresco -Ddb.username=alfresco -Ddb.password=alfresco - ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal+transforms.yml
- ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco"
- name: "REST API TAS tests part1" script:
jdk: openjdk11 - travis_wait 60 mvn -B install -f packaging/tests/tas-restapi/pom.xml -Pall-tas-tests,run-restapi-part1 -Denvironment=default -DrunBugs=false
if: commit_message =~ /\[tas\]/
install: - name: "REST API TAS tests part2"
- ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal+transforms.yml if: commit_message =~ /\[tas\]/
- ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco" before_script:
script: - ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal+transforms.yml
- travis_wait 60 mvn install -f packaging/tests/tas-restapi/pom.xml -Pall-tas-tests,run-restapi-part1 -Denvironment=default -DrunBugs=false - ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco"
script:
- name: "REST API TAS tests part2" - travis_wait 60 mvn -B install -f packaging/tests/tas-restapi/pom.xml -Pall-tas-tests,run-restapi-part2 -Denvironment=default -DrunBugs=false
jdk: openjdk11
if: commit_message =~ /\[tas\]/ - name: "REST API TAS tests part3"
install: if: commit_message =~ /\[tas\]/
- ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal+transforms.yml before_script:
- ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco" - ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal+transforms.yml
script: - ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco"
- travis_wait 60 mvn install -f packaging/tests/tas-restapi/pom.xml -Pall-tas-tests,run-restapi-part2 -Denvironment=default -DrunBugs=false script:
- travis_wait 60 mvn -B install -f packaging/tests/tas-restapi/pom.xml -Pall-tas-tests,run-restapi-part3 -Denvironment=default -DrunBugs=false
- name: "REST API TAS tests part3"
jdk: openjdk11 - name: "CMIS TAS tests"
if: commit_message =~ /\[tas\]/ if: commit_message =~ /\[tas\]/
install: before_script:
- ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal+transforms.yml - ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal+transforms.yml
- ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco" - ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco"
script: script:
- travis_wait 60 mvn install -f packaging/tests/tas-restapi/pom.xml -Pall-tas-tests,run-restapi-part3 -Denvironment=default -DrunBugs=false - travis_wait 40 mvn -B install -f packaging/tests/tas-cmis/pom.xml -Pall-tas-tests -Denvironment=default -DrunBugs=false
- name: "CMIS TAS tests" - name: "Email TAS tests"
jdk: openjdk11 if: commit_message =~ /\[tas\]/
if: commit_message =~ /\[tas\]/ before_script:
install: - ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal.yml
- ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal+transforms.yml - ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco"
- ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco" script:
script: - travis_wait 30 mvn -B install -f packaging/tests/tas-email/pom.xml -Pall-tas-tests -Denvironment=default -DrunBugs=false
- travis_wait 40 mvn install -f packaging/tests/tas-cmis/pom.xml -Pall-tas-tests -Denvironment=default -DrunBugs=false
- name: "WebDAV TAS tests"
- name: "Email TAS tests" if: commit_message =~ /\[tas\]/
jdk: openjdk11 before_script:
if: commit_message =~ /\[tas\]/ - ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal.yml
install: - ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco"
- ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal.yml script:
- ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco" - travis_wait 30 mvn -B install -f packaging/tests/tas-webdav/pom.xml -Pall-tas-tests -Denvironment=default -DrunBugs=false
script:
- travis_wait 30 mvn install -f packaging/tests/tas-email/pom.xml -Pall-tas-tests -Denvironment=default -DrunBugs=false - name: "Integration TAS tests"
if: commit_message =~ /\[tas\]/
- name: "WebDAV TAS tests" before_script:
jdk: openjdk11 - ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal.yml
if: commit_message =~ /\[tas\]/ - ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco"
install: script:
- ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal.yml - travis_wait 30 mvn -B install -f packaging/tests/tas-integration/pom.xml -Pall-tas-tests -Denvironment=default -DrunBugs=false
- ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco"
script: # TODO enable job
- travis_wait 30 mvn install -f packaging/tests/tas-webdav/pom.xml -Pall-tas-tests -Denvironment=default -DrunBugs=false - name: "Push to Nexus"
stage: release
- name: "Integration TAS tests" if: false
jdk: openjdk11 install: travis_retry travis_wait 30 mvn -B -V install -DskipTests -Dmaven.javadoc.skip=true -Pinternal
if: commit_message =~ /\[tas\]/ before_script: bash scripts/travis/verify_release_tag.sh
install: script: travis_wait 40 bash scripts/travis/maven_release.sh
- ${TAS_SCRIPTS}/start-compose.sh ${TAS_ENVIRONMENT}/docker-compose-minimal.yml
- ${TAS_SCRIPTS}/wait-for-alfresco-start.sh "http://localhost:8082/alfresco" - name: "Trigger alfresco-enterprise-repo build"
script: stage: trigger_downstream
- travis_wait 30 mvn install -f packaging/tests/tas-integration/pom.xml -Pall-tas-tests -Denvironment=default -DrunBugs=false before_install: skip
install: skip
# Comment out for now to avoid pushing 8.300 to nuxus until we are ready script: bash scripts/travis/trigger_travis.sh "Alfresco" "alfresco-enterprise-repo" "${TRAVIS_BRANCH}"
# - stage: release
# name: "Push to Nexus" # TODO enable or delete job
# if: fork = false AND (branch = master OR branch =~ /release\/.*/) AND type != pull_request AND commit_message !~ /\[no-release\]/ - name: "Trigger acs-community-packaging build"
# before_install: stage: trigger_downstream
# - "cp .travis.settings.xml $HOME/.m2/settings.xml" if: false
# script: before_install: skip
# # Use full history for release install: skip
# - git checkout -B "${TRAVIS_BRANCH}" script: bash scripts/travis/trigger_travis.sh "Alfresco" "acs-community-packaging" "${TRAVIS_BRANCH}"
# # Add email to link commits to user
# - git config user.email "${GIT_EMAIL}"
# # Skip building of release commits
# - mvn --batch-mode -q -DscmCommentPrefix="[maven-release-plugin][skip ci] " -Dusername="${GIT_USERNAME}" -Dpassword="${GIT_PASSWORD}" -DskipTests -Darguments=-DskipTests release:clean release:prepare release:perform
# - name: "Trigger alfresco-enterprise-repo build"
# stage: trigger_downstream
# # for all active branches and if it is not a PR
# if: fork = false AND type != pull_request AND commit_message !~ /\[no-downstream\]/
# install: skip
# script: bash trigger-travis.sh "Alfresco" "alfresco-enterprise-repo-play1" "${TRAVIS_BRANCH}"

View File

@@ -1,177 +1,150 @@
<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"> <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> <modelVersion>4.0.0</modelVersion>
<artifactId>alfresco-core</artifactId> <artifactId>alfresco-core</artifactId>
<name>Alfresco Core</name> <name>Alfresco Core</name>
<description>Alfresco core libraries and utils</description> <description>Alfresco core libraries and utils</description>
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo</artifactId> <artifactId>alfresco-community-repo</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<scm> <dependencies>
<connection>scm:git:https://github.com/Alfresco/alfresco-core.git</connection> <dependency>
<developerConnection>scm:git:https://github.com/Alfresco/alfresco-core.git</developerConnection> <groupId>commons-codec</groupId>
<url>https://github.com/Alfresco/alfresco-core</url> <artifactId>commons-codec</artifactId>
<tag>HEAD</tag> </dependency>
</scm> <dependency>
<groupId>commons-httpclient</groupId>
<distributionManagement> <artifactId>commons-httpclient</artifactId>
<repository> </dependency>
<id>alfresco-public</id> <dependency>
<url>https://artifacts.alfresco.com/nexus/content/repositories/releases</url> <groupId>commons-logging</groupId>
</repository> <artifactId>commons-logging</artifactId>
</distributionManagement> </dependency>
<dependency>
<dependencies> <groupId>commons-io</groupId>
<dependency> <artifactId>commons-io</artifactId>
<groupId>commons-codec</groupId> </dependency>
<artifactId>commons-codec</artifactId> <dependency>
</dependency> <groupId>org.apache.commons</groupId>
<dependency> <artifactId>commons-math3</artifactId>
<groupId>commons-httpclient</groupId> <version>3.6.1</version>
<artifactId>commons-httpclient</artifactId> </dependency>
</dependency> <dependency>
<dependency> <groupId>org.safehaus.jug</groupId>
<groupId>commons-logging</groupId> <artifactId>jug</artifactId>
<artifactId>commons-logging</artifactId> <version>2.0.0</version>
</dependency> <classifier>asl</classifier>
<dependency> </dependency>
<groupId>commons-io</groupId> <dependency>
<artifactId>commons-io</artifactId> <groupId>log4j</groupId>
</dependency> <artifactId>log4j</artifactId>
<dependency> <version>1.2.17</version>
<groupId>org.apache.commons</groupId> </dependency>
<artifactId>commons-math3</artifactId> <dependency>
<version>3.6.1</version> <groupId>org.json</groupId>
</dependency> <artifactId>json</artifactId>
<dependency> </dependency>
<groupId>org.safehaus.jug</groupId> <dependency>
<artifactId>jug</artifactId> <groupId>org.springframework</groupId>
<version>2.0.0</version> <artifactId>spring-orm</artifactId>
<classifier>asl</classifier> <!-- exclude spring-jcl which is brought in by spring-core -->
</dependency> <!-- see https://issues.alfresco.com/jira/browse/REPO-4774 -->
<dependency> <exclusions>
<groupId>log4j</groupId> <exclusion>
<artifactId>log4j</artifactId> <groupId>org.springframework</groupId>
<version>1.2.17</version> <artifactId>spring-jcl</artifactId>
</dependency> </exclusion>
<dependency> </exclusions>
<groupId>org.json</groupId> </dependency>
<artifactId>json</artifactId> <dependency>
</dependency> <groupId>org.springframework</groupId>
<dependency> <artifactId>spring-context</artifactId>
<groupId>org.springframework</groupId> </dependency>
<artifactId>spring-orm</artifactId> <dependency>
<!-- exclude spring-jcl which is brought in by spring-core --> <groupId>org.quartz-scheduler</groupId>
<!-- see https://issues.alfresco.com/jira/browse/REPO-4774 --> <artifactId>quartz</artifactId>
<exclusions> <!-- exclude c3p0 -->
<exclusion> <!-- see https://issues.alfresco.com/jira/browse/REPO-3447 -->
<groupId>org.springframework</groupId> <exclusions>
<artifactId>spring-jcl</artifactId> <exclusion>
</exclusion> <groupId>com.mchange</groupId>
</exclusions> <artifactId>*</artifactId>
</dependency> </exclusion>
<dependency> </exclusions>
<groupId>org.springframework</groupId> </dependency>
<artifactId>spring-context</artifactId> <dependency>
</dependency> <groupId>org.alfresco.surf</groupId>
<dependency> <artifactId>spring-surf-core-configservice</artifactId>
<groupId>org.quartz-scheduler</groupId> </dependency>
<artifactId>quartz</artifactId> <dependency>
<!-- exclude c3p0 --> <groupId>jakarta.xml.bind</groupId>
<!-- see https://issues.alfresco.com/jira/browse/REPO-3447 --> <artifactId>jakarta.xml.bind-api</artifactId>
<exclusions> </dependency>
<exclusion> <dependency>
<groupId>com.mchange</groupId> <groupId>com.sun.xml.bind</groupId>
<artifactId>*</artifactId> <artifactId>jaxb-core</artifactId>
</exclusion> <version>2.3.0.1</version>
</exclusions> </dependency>
</dependency> <dependency>
<dependency> <groupId>org.codehaus.guessencoding</groupId>
<groupId>org.alfresco.surf</groupId> <artifactId>guessencoding</artifactId>
<artifactId>spring-surf-core-configservice</artifactId> <version>1.4</version>
</dependency> </dependency>
<dependency> <dependency>
<groupId>jakarta.xml.bind</groupId> <groupId>jakarta.transaction</groupId>
<artifactId>jakarta.xml.bind-api</artifactId> <artifactId>jakarta.transaction-api</artifactId>
</dependency> </dependency>
<dependency> <dependency>
<groupId>com.sun.xml.bind</groupId> <groupId>joda-time</groupId>
<artifactId>jaxb-core</artifactId> <artifactId>joda-time</artifactId>
<version>2.3.0.1</version> </dependency>
</dependency>
<dependency> <!-- provided dependencies -->
<groupId>org.codehaus.guessencoding</groupId> <dependency>
<artifactId>guessencoding</artifactId> <groupId>javax.servlet</groupId>
<version>1.4</version> <artifactId>javax.servlet-api</artifactId>
</dependency> <scope>provided</scope>
<dependency> </dependency>
<groupId>jakarta.transaction</groupId>
<artifactId>jakarta.transaction-api</artifactId> <!-- Test only dependencies, as popped up while running mvn test -->
</dependency> <dependency>
<dependency> <groupId>org.slf4j</groupId>
<groupId>joda-time</groupId> <artifactId>slf4j-log4j12</artifactId>
<artifactId>joda-time</artifactId> <scope>test</scope>
</dependency> </dependency>
<dependency>
<!-- provided dependencies --> <groupId>junit</groupId>
<dependency> <artifactId>junit</artifactId>
<groupId>javax.servlet</groupId> <scope>test</scope>
<artifactId>javax.servlet-api</artifactId> </dependency>
<scope>provided</scope> <dependency>
</dependency> <groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<!-- Test only dependencies, as popped up while running mvn test --> <scope>test</scope>
<dependency> </dependency>
<groupId>org.slf4j</groupId> <dependency>
<artifactId>slf4j-log4j12</artifactId> <groupId>commons-dbcp</groupId>
<scope>test</scope> <artifactId>commons-dbcp</artifactId>
</dependency> <scope>test</scope>
<dependency> </dependency>
<groupId>junit</groupId> </dependencies>
<artifactId>junit</artifactId>
<scope>test</scope> <build>
</dependency> <plugins>
<dependency> <plugin>
<groupId>org.mockito</groupId> <artifactId>maven-jar-plugin</artifactId>
<artifactId>mockito-core</artifactId> <executions>
<scope>test</scope> <execution>
</dependency> <goals>
<dependency> <goal>test-jar</goal>
<groupId>commons-dbcp</groupId> </goals>
<artifactId>commons-dbcp</artifactId> </execution>
<scope>test</scope> </executions>
</dependency> </plugin>
</dependencies> </plugins>
</build>
<build>
<pluginManagement> </project>
<plugins>
<plugin>
<artifactId>maven-release-plugin</artifactId>
<configuration>
<autoVersionSubmodules>true</autoVersionSubmodules>
<tagNameFormat>@{project.version}</tagNameFormat>
</configuration>
</plugin>
</plugins>
</pluginManagement>
<plugins>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<version>${dependency.maven-jar-plugin.version}</version>
<executions>
<execution>
<goals>
<goal>test-jar</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>

View File

@@ -1,337 +1,315 @@
<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/xsd/maven-4.0.0.xsd"> <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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>alfresco-data-model</artifactId> <artifactId>alfresco-data-model</artifactId>
<name>Alfresco Data Model</name> <name>Alfresco Data Model</name>
<description>Alfresco Data Model classes</description> <description>Alfresco Data Model classes</description>
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo</artifactId> <artifactId>alfresco-community-repo</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<scm> <properties>
<connection>scm:git:https://github.com/Alfresco/alfresco-data-model.git</connection> <dependency.tika.version>1.24.1</dependency.tika.version>
<developerConnection>scm:git:https://github.com/Alfresco/alfresco-data-model.git</developerConnection> <!-- Files to exclude from SonarQube analysis -->
<url>https://github.com/Alfresco/alfresco-data-model</url> <sonar.exclusions>
<tag>HEAD</tag> source/java/org/alfresco/repo/search/impl/parsers/CMIS*er.java,
</scm> source/java/org/alfresco/repo/search/impl/parsers/FTSParser.java,
source/java/org/alfresco/repo/search/impl/parsers/FTSLexer.java
<distributionManagement> </sonar.exclusions>
<repository> </properties>
<id>alfresco-public</id>
<url>https://artifacts.alfresco.com/nexus/content/repositories/releases</url> <build>
</repository> <plugins>
</distributionManagement> <plugin>
<groupId>org.jibx</groupId>
<properties> <artifactId>maven-jibx-plugin</artifactId>
<dependency.tika.version>1.24.1</dependency.tika.version> <configuration>
<!-- Files to exclude from SonarQube analysis --> <load>true</load>
<sonar.exclusions> <schemaBindingDirectory>${project.build.sourceDirectory}/org/alfresco/repo/dictionary</schemaBindingDirectory>
source/java/org/alfresco/repo/search/impl/parsers/CMIS*er.java, <includeSchemaBindings>
source/java/org/alfresco/repo/search/impl/parsers/FTSParser.java, <includeSchemaBinding>m2binding.xml</includeSchemaBinding>
source/java/org/alfresco/repo/search/impl/parsers/FTSLexer.java </includeSchemaBindings>
</sonar.exclusions> </configuration>
</properties> <executions>
<execution>
<build> <id>bind-sources</id>
<plugins> <goals>
<plugin> <goal>bind</goal>
<groupId>org.jibx</groupId> </goals>
<artifactId>maven-jibx-plugin</artifactId> </execution>
<configuration> </executions>
<load>true</load> </plugin>
<schemaBindingDirectory>${project.build.sourceDirectory}/org/alfresco/repo/dictionary</schemaBindingDirectory>
<includeSchemaBindings> <!-- ACE-3329 Create _en.properties message files -->
<includeSchemaBinding>m2binding.xml</includeSchemaBinding> <plugin>
</includeSchemaBindings> <artifactId>maven-antrun-plugin</artifactId>
</configuration> <executions>
<executions> <execution>
<execution> <id>duplicate-english-messages</id>
<id>bind-sources</id> <phase>generate-resources</phase>
<goals> <goals>
<goal>bind</goal> <goal>run</goal>
</goals> </goals>
</execution> </execution>
</executions> </executions>
</plugin> <configuration>
<target>
<!-- ACE-3329 Create _en.properties message files --> <copy todir="${project.build.outputDirectory}">
<plugin> <fileset dir="${basedir}/src/main/resources" includes="alfresco/messages/**/*.properties" />
<artifactId>maven-antrun-plugin</artifactId> <mapper type="regexp" from="^([^_]*).properties$" to="\1_en.properties" />
<executions> </copy>
<execution> </target>
<id>duplicate-english-messages</id> </configuration>
<phase>generate-resources</phase> </plugin>
<goals> <plugin>
<goal>run</goal> <artifactId>maven-jar-plugin</artifactId>
</goals> <executions>
</execution> <execution>
</executions> <goals>
<configuration> <goal>test-jar</goal>
<target> </goals>
<copy todir="${project.build.outputDirectory}"> </execution>
<fileset dir="${basedir}/src/main/resources" includes="alfresco/messages/**/*.properties" /> </executions>
<mapper type="regexp" from="^([^_]*).properties$" to="\1_en.properties" /> </plugin>
</copy> </plugins>
</target>
</configuration> <pluginManagement>
</plugin> <plugins>
<plugin> <!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.-->
<artifactId>maven-jar-plugin</artifactId> <plugin>
<version>${dependency.maven-jar-plugin.version}</version> <groupId>org.eclipse.m2e</groupId>
<executions> <artifactId>lifecycle-mapping</artifactId>
<execution> <version>1.0.0</version>
<goals> <configuration>
<goal>test-jar</goal> <lifecycleMappingMetadata>
</goals> <pluginExecutions>
</execution> <pluginExecution>
</executions> <pluginExecutionFilter>
</plugin> <groupId>org.jibx</groupId>
</plugins> <artifactId>
maven-jibx-plugin
<pluginManagement> </artifactId>
<plugins> <versionRange>
<!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.--> [1.2.5,)
<plugin> </versionRange>
<groupId>org.eclipse.m2e</groupId> <goals>
<artifactId>lifecycle-mapping</artifactId> <goal>bind</goal>
<version>1.0.0</version> </goals>
<configuration> </pluginExecutionFilter>
<lifecycleMappingMetadata> <action>
<pluginExecutions> <execute>
<pluginExecution> <runOnConfiguration>true</runOnConfiguration>
<pluginExecutionFilter> <runOnIncremental>true</runOnIncremental>
<groupId>org.jibx</groupId> </execute>
<artifactId> </action>
maven-jibx-plugin </pluginExecution>
</artifactId> </pluginExecutions>
<versionRange> </lifecycleMappingMetadata>
[1.2.5,) </configuration>
</versionRange> </plugin>
<goals> </plugins>
<goal>bind</goal> </pluginManagement>
</goals> </build>
</pluginExecutionFilter>
<action> <dependencies>
<execute> <dependency>
<runOnConfiguration>true</runOnConfiguration> <groupId>org.alfresco</groupId>
<runOnIncremental>true</runOnIncremental> <artifactId>alfresco-core</artifactId>
</execute> </dependency>
</action> <!--
</pluginExecution> | provided dependencies (are not transitive and not included in webapps)
</pluginExecutions> | see http://maven.apache.org/guides/introduction/introduction-to-dependency-mechanism.html#Dependency_Scope
</lifecycleMappingMetadata> -->
</configuration> <dependency>
</plugin> <groupId>javax.servlet</groupId>
<plugin> <artifactId>javax.servlet-api</artifactId>
<artifactId>maven-release-plugin</artifactId> <scope>provided</scope>
<configuration> </dependency>
<autoVersionSubmodules>true</autoVersionSubmodules> <!--
<tagNameFormat>@{project.version}</tagNameFormat> | compile dependencies
</configuration> -->
</plugin> <dependency>
</plugins> <groupId>org.jibx</groupId>
</pluginManagement> <artifactId>jibx-run</artifactId>
</build> <version>1.3.3</version>
</dependency>
<dependencies> <dependency>
<dependency> <groupId>com.fasterxml.jackson.core</groupId>
<groupId>org.alfresco</groupId> <artifactId>jackson-annotations</artifactId>
<artifactId>alfresco-core</artifactId> <version>${dependency.jackson.version}</version>
</dependency> </dependency>
<!-- <dependency>
| provided dependencies (are not transitive and not included in webapps) <groupId>org.antlr</groupId>
| see http://maven.apache.org/guides/introduction/introduction-to-dependency-mechanism.html#Dependency_Scope <artifactId>antlr</artifactId>
--> <version>${dependency.antlr.version}</version>
<dependency> </dependency>
<groupId>javax.servlet</groupId> <!-- REPO-5047 - Replaces org.codehaus.woodstox:woodstox-core-asl -->
<artifactId>javax.servlet-api</artifactId> <dependency>
<scope>provided</scope> <groupId>com.fasterxml.woodstox</groupId>
</dependency> <artifactId>woodstox-core</artifactId>
<!-- <version>5.0.3</version>
| compile dependencies </dependency>
--> <!-- REPO-5047 - Replaces org.apache.geronimo.specs:geronimo-ws-metadata_2.0_spec -->
<dependency> <dependency>
<groupId>org.jibx</groupId> <groupId>jakarta.jws</groupId>
<artifactId>jibx-run</artifactId> <artifactId>jakarta.jws-api</artifactId>
<version>1.3.3</version> <version>1.1.1</version>
</dependency> </dependency>
<dependency> <!-- REPO-5047 - Replaces org.apache.geronimo.specs:geronimo-jta_1.1_spec -->
<groupId>com.fasterxml.jackson.core</groupId> <dependency>
<artifactId>jackson-annotations</artifactId> <groupId>jakarta.transaction</groupId>
<version>${dependency.jackson.version}</version> <artifactId>jakarta.transaction-api</artifactId>
</dependency> </dependency>
<dependency> <!-- REPO-5047 - Replaces javax.annotation:javax.annotation-api -->
<groupId>org.antlr</groupId> <dependency>
<artifactId>antlr</artifactId> <groupId>jakarta.annotation</groupId>
<version>${dependency.antlr.version}</version> <artifactId>jakarta.annotation-api</artifactId>
</dependency> <version>1.3.5</version>
<!-- REPO-5047 - Replaces org.codehaus.woodstox:woodstox-core-asl --> </dependency>
<dependency> <!-- REPO-5047 - Replaces com.sun.activation:javax.activation -->
<groupId>com.fasterxml.woodstox</groupId> <dependency>
<artifactId>woodstox-core</artifactId> <groupId>com.sun.activation</groupId>
<version>5.0.3</version> <artifactId>jakarta.activation</artifactId>
</dependency> <version>1.2.2</version>
<!-- REPO-5047 - Replaces org.apache.geronimo.specs:geronimo-ws-metadata_2.0_spec --> </dependency>
<dependency> <!-- the cxf libs were updated, see dependencyManagement section -->
<groupId>jakarta.jws</groupId> <dependency>
<artifactId>jakarta.jws-api</artifactId> <groupId>org.apache.chemistry.opencmis</groupId>
<version>1.1.1</version> <artifactId>chemistry-opencmis-commons-impl</artifactId>
</dependency> <version>${dependency.opencmis.version}</version>
<!-- REPO-5047 - Replaces org.apache.geronimo.specs:geronimo-jta_1.1_spec --> <exclusions>
<dependency> <exclusion>
<groupId>jakarta.transaction</groupId> <groupId>com.sun.xml.messaging.saaj</groupId>
<artifactId>jakarta.transaction-api</artifactId> <artifactId>saaj-impl</artifactId>
</dependency> </exclusion>
<!-- REPO-5047 - Replaces javax.annotation:javax.annotation-api --> <!-- Duplicates classes from com.fasterxml.woodstox:woodstox-core -->
<dependency> <exclusion>
<groupId>jakarta.annotation</groupId> <groupId>org.codehaus.woodstox</groupId>
<artifactId>jakarta.annotation-api</artifactId> <artifactId>woodstox-core-asl</artifactId>
<version>1.3.5</version> </exclusion>
</dependency> </exclusions>
<!-- REPO-5047 - Replaces com.sun.activation:javax.activation --> </dependency>
<dependency> <dependency>
<groupId>com.sun.activation</groupId> <groupId>org.apache.chemistry.opencmis</groupId>
<artifactId>jakarta.activation</artifactId> <artifactId>chemistry-opencmis-server-bindings</artifactId>
<version>1.2.2</version> <version>${dependency.opencmis.version}</version>
</dependency> <exclusions>
<!-- the cxf libs were updated, see dependencyManagement section --> <exclusion>
<dependency> <groupId>commons-lang</groupId>
<groupId>org.apache.chemistry.opencmis</groupId> <artifactId>commons-lang3</artifactId>
<artifactId>chemistry-opencmis-commons-impl</artifactId> </exclusion>
<version>${dependency.opencmis.version}</version> <!-- Duplicates classes from jakarta.jws:jakarta.jws-api -->
<exclusions> <exclusion>
<exclusion> <groupId>org.apache.geronimo.specs</groupId>
<groupId>com.sun.xml.messaging.saaj</groupId> <artifactId>geronimo-ws-metadata_2.0_spec</artifactId>
<artifactId>saaj-impl</artifactId> </exclusion>
</exclusion> <!-- Duplicates classes from jakarta.transaction:jakarta.transaction-api -->
<!-- Duplicates classes from com.fasterxml.woodstox:woodstox-core --> <exclusion>
<exclusion> <groupId>org.apache.geronimo.specs</groupId>
<groupId>org.codehaus.woodstox</groupId> <artifactId>geronimo-jta_1.1_spec</artifactId>
<artifactId>woodstox-core-asl</artifactId> </exclusion>
</exclusion> <!-- Duplicates classes from jakarta.annotation:jakarta.annotation-api -->
</exclusions> <exclusion>
</dependency> <groupId>javax.annotation</groupId>
<dependency> <artifactId>javax.annotation-api</artifactId>
<groupId>org.apache.chemistry.opencmis</groupId> </exclusion>
<artifactId>chemistry-opencmis-server-bindings</artifactId> <!-- Duplicates classes from com.sun.activation:jakarta.activation -->
<version>${dependency.opencmis.version}</version> <exclusion>
<exclusions> <groupId>com.sun.activation</groupId>
<exclusion> <artifactId>javax.activation</artifactId>
<groupId>commons-lang</groupId> </exclusion>
<artifactId>commons-lang3</artifactId> </exclusions>
</exclusion> </dependency>
<!-- Duplicates classes from jakarta.jws:jakarta.jws-api --> <!-- This is now deployed at:
<exclusion> | http://artifacts.alfresco.com/nexus/content/repositories/thirdparty/org/acegisecurity/acegi-security/0.8.2_patched/
<groupId>org.apache.geronimo.specs</groupId> -->
<artifactId>geronimo-ws-metadata_2.0_spec</artifactId> <dependency>
</exclusion> <groupId>org.acegisecurity</groupId>
<!-- Duplicates classes from jakarta.transaction:jakarta.transaction-api --> <artifactId>acegi-security</artifactId>
<exclusion> <version>0.8.2_patched</version>
<groupId>org.apache.geronimo.specs</groupId> </dependency>
<artifactId>geronimo-jta_1.1_spec</artifactId> <dependency>
</exclusion> <groupId>org.alfresco</groupId>
<!-- Duplicates classes from jakarta.annotation:jakarta.annotation-api --> <artifactId>alfresco-xmlfactory</artifactId>
<exclusion> <version>1.3</version>
<groupId>javax.annotation</groupId> </dependency>
<artifactId>javax.annotation-api</artifactId> <dependency>
</exclusion> <groupId>xerces</groupId>
<!-- Duplicates classes from com.sun.activation:jakarta.activation --> <artifactId>xercesImpl</artifactId>
<exclusion> </dependency>
<groupId>com.sun.activation</groupId> <!-- Tika -->
<artifactId>javax.activation</artifactId> <dependency>
</exclusion> <groupId>org.apache.tika</groupId>
</exclusions> <artifactId>tika-core</artifactId>
</dependency> <version>${dependency.tika.version}</version>
<!-- This is now deployed at: </dependency>
| http://artifacts.alfresco.com/nexus/content/repositories/thirdparty/org/acegisecurity/acegi-security/0.8.2_patched/ <dependency>
--> <groupId>org.apache.tika</groupId>
<dependency> <artifactId>tika-parsers</artifactId>
<groupId>org.acegisecurity</groupId> <version>${dependency.tika.version}</version>
<artifactId>acegi-security</artifactId> <exclusions>
<version>0.8.2_patched</version> <exclusion>
</dependency> <groupId>com.tdunning</groupId>
<dependency> <artifactId>json</artifactId>
<groupId>org.alfresco</groupId> </exclusion>
<artifactId>alfresco-xmlfactory</artifactId> <exclusion>
<version>1.3</version> <groupId>org.bouncycastle</groupId>
</dependency> <artifactId>bcprov-jdk15on</artifactId>
<dependency> </exclusion>
<groupId>xerces</groupId> <exclusion>
<artifactId>xercesImpl</artifactId> <groupId>asm</groupId>
</dependency> <artifactId>asm</artifactId>
<!-- Tika --> </exclusion>
<dependency> <!-- Duplicate classes from com.sun.xml.bind:jaxb-core-->
<groupId>org.apache.tika</groupId> <exclusion>
<artifactId>tika-core</artifactId> <groupId>org.glassfish.jaxb</groupId>
<version>${dependency.tika.version}</version> <artifactId>txw2</artifactId>
</dependency> </exclusion>
<dependency> <exclusion>
<groupId>org.apache.tika</groupId> <groupId>com.sun.istack</groupId>
<artifactId>tika-parsers</artifactId> <artifactId>istack-commons-runtime</artifactId>
<version>${dependency.tika.version}</version> </exclusion>
<exclusions> <!-- Duplicates classes from jakarta.jws:jakarta.jws-api -->
<exclusion> <exclusion>
<groupId>com.tdunning</groupId> <groupId>org.apache.geronimo.specs</groupId>
<artifactId>json</artifactId> <artifactId>geronimo-ws-metadata_2.0_spec</artifactId>
</exclusion> </exclusion>
<exclusion> <!-- Duplicates classes from jakarta.transaction:jakarta.transaction-api -->
<groupId>org.bouncycastle</groupId> <exclusion>
<artifactId>bcprov-jdk15on</artifactId> <groupId>org.apache.geronimo.specs</groupId>
</exclusion> <artifactId>geronimo-jta_1.1_spec</artifactId>
<exclusion> </exclusion>
<groupId>asm</groupId> <!-- Duplicates classes from jakarta.annotation:jakarta.annotation-api -->
<artifactId>asm</artifactId> <exclusion>
</exclusion> <groupId>javax.annotation</groupId>
<!-- Duplicate classes from com.sun.xml.bind:jaxb-core--> <artifactId>javax.annotation-api</artifactId>
<exclusion> </exclusion>
<groupId>org.glassfish.jaxb</groupId> <!-- Duplicates classes from com.sun.activation:jakarta.activation -->
<artifactId>txw2</artifactId> <exclusion>
</exclusion> <groupId>com.sun.activation</groupId>
<exclusion> <artifactId>javax.activation</artifactId>
<groupId>com.sun.istack</groupId> </exclusion>
<artifactId>istack-commons-runtime</artifactId> </exclusions>
</exclusion> </dependency>
<!-- Duplicates classes from jakarta.jws:jakarta.jws-api -->
<exclusion> <!-- Test dependencies -->
<groupId>org.apache.geronimo.specs</groupId> <dependency>
<artifactId>geronimo-ws-metadata_2.0_spec</artifactId> <groupId>junit</groupId>
</exclusion> <artifactId>junit</artifactId>
<!-- Duplicates classes from jakarta.transaction:jakarta.transaction-api --> <scope>test</scope>
<exclusion> </dependency>
<groupId>org.apache.geronimo.specs</groupId> <dependency>
<artifactId>geronimo-jta_1.1_spec</artifactId> <groupId>org.antlr</groupId>
</exclusion> <artifactId>gunit</artifactId>
<!-- Duplicates classes from jakarta.annotation:jakarta.annotation-api --> <scope>test</scope>
<exclusion> </dependency>
<groupId>javax.annotation</groupId> <dependency>
<artifactId>javax.annotation-api</artifactId> <groupId>org.mockito</groupId>
</exclusion> <artifactId>mockito-core</artifactId>
<!-- Duplicates classes from com.sun.activation:jakarta.activation --> <scope>test</scope>
<exclusion> </dependency>
<groupId>com.sun.activation</groupId> </dependencies>
<artifactId>javax.activation</artifactId>
</exclusion> </project>
</exclusions>
</dependency>
<!-- Test dependencies -->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.antlr</groupId>
<artifactId>gunit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
</project>

View File

@@ -1,292 +1,266 @@
<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/xsd/maven-4.0.0.xsd"> <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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>alfresco-community-repo-docker</artifactId> <artifactId>alfresco-community-repo-docker</artifactId>
<name>Alfresco Community Repo Docker Base Builder</name> <name>Alfresco Community Repo Docker Base Builder</name>
<packaging>pom</packaging> <packaging>pom</packaging>
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo-packaging</artifactId> <artifactId>alfresco-community-repo-packaging</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<properties> <properties>
<image.name>alfresco/alfresco-community-repo-base</image.name> <image.name>alfresco/alfresco-community-repo-base</image.name>
<image.registry>quay.io</image.registry> </properties>
</properties>
<build>
<build> <plugins>
<plugins> <plugin>
<plugin> <groupId>org.apache.maven.plugins</groupId>
<groupId>org.apache.maven.plugins</groupId> <artifactId>maven-resources-plugin</artifactId>
<artifactId>maven-resources-plugin</artifactId> <executions>
<version>3.1.0</version> <execution>
<executions> <id>copy-licenses</id>
<execution> <phase>process-resources</phase>
<id>copy-licenses</id> <goals>
<phase>process-resources</phase> <goal>copy-resources</goal>
<goals> </goals>
<goal>copy-resources</goal> <configuration>
</goals> <resources>
<configuration> <resource>
<resources> <!-- Extract licenses directory -->
<resource> <directory>../distribution/src/main/resources/licenses</directory>
<!-- Extract licenses directory --> <filtering>false</filtering>
<directory>../distribution/src/main/resources/licenses</directory> </resource>
<filtering>false</filtering> </resources>
</resource> <outputDirectory>${project.build.directory}/licenses</outputDirectory>
</resources> </configuration>
<outputDirectory>${project.build.directory}/licenses</outputDirectory> </execution>
</configuration> </executions>
</execution> </plugin>
</executions> <plugin>
</plugin> <groupId>org.apache.maven.plugins</groupId>
<plugin> <artifactId>maven-dependency-plugin</artifactId>
<groupId>org.apache.maven.plugins</groupId> <executions>
<artifactId>maven-dependency-plugin</artifactId> <execution>
<version>3.1.2</version> <id>unpack-war-files</id>
<executions> <phase>process-resources</phase>
<execution> <goals>
<id>unpack-war-files</id> <goal>unpack</goal>
<phase>process-resources</phase> </goals>
<goals> <configuration>
<goal>unpack</goal> <artifactItems>
</goals> <artifactItem>
<configuration> <groupId>org.alfresco</groupId>
<artifactItems> <artifactId>content-services-community</artifactId>
<artifactItem> <version>${project.version}</version>
<groupId>org.alfresco</groupId> <type>war</type>
<artifactId>content-services-community</artifactId> <overWrite>false</overWrite>
<version>${project.version}</version> <outputDirectory>${project.build.directory}/war/alfresco</outputDirectory>
<type>war</type> </artifactItem>
<overWrite>false</overWrite> <artifactItem>
<outputDirectory>${project.build.directory}/war/alfresco</outputDirectory> <groupId>org.alfresco</groupId>
</artifactItem> <artifactId>alfresco-server-root</artifactId>
<artifactItem> <version>${dependency.alfresco-server-root.version}</version>
<groupId>org.alfresco</groupId> <type>war</type>
<artifactId>alfresco-server-root</artifactId> <outputDirectory>${project.build.directory}/war/ROOT</outputDirectory>
<version>${dependency.alfresco-server-root.version}</version> </artifactItem>
<type>war</type> <artifactItem>
<outputDirectory>${project.build.directory}/war/ROOT</outputDirectory> <groupId>org.alfresco.aos-module</groupId>
</artifactItem> <artifactId>alfresco-vti-bin</artifactId>
<artifactItem> <type>war</type>
<groupId>org.alfresco.aos-module</groupId> <outputDirectory>${project.build.directory}/war/_vti_bin</outputDirectory>
<artifactId>alfresco-vti-bin</artifactId> </artifactItem>
<type>war</type> </artifactItems>
<outputDirectory>${project.build.directory}/war/_vti_bin</outputDirectory> </configuration>
</artifactItem> </execution>
</artifactItems> <execution>
</configuration> <id>copy-jdbc-connectors</id>
</execution> <phase>process-resources</phase>
<execution> <goals>
<id>copy-jdbc-connectors</id> <goal>copy</goal>
<phase>process-resources</phase> </goals>
<goals> <configuration>
<goal>copy</goal> <artifactItems>
</goals> <artifactItem>
<configuration> <groupId>org.postgresql</groupId>
<artifactItems> <artifactId>postgresql</artifactId>
<artifactItem> <type>jar</type>
<groupId>org.postgresql</groupId> <overWrite>false</overWrite>
<artifactId>postgresql</artifactId> <outputDirectory>${project.build.directory}/connector</outputDirectory>
<type>jar</type> </artifactItem>
<overWrite>false</overWrite> <artifactItem>
<outputDirectory>${project.build.directory}/connector</outputDirectory> <groupId>org.alfresco</groupId>
</artifactItem> <artifactId>alfresco-mmt</artifactId>
<artifactItem> <type>jar</type>
<groupId>org.alfresco</groupId> <overWrite>false</overWrite>
<artifactId>alfresco-mmt</artifactId> <outputDirectory>${project.build.directory}/alfresco-mmt</outputDirectory>
<type>jar</type> </artifactItem>
<overWrite>false</overWrite> </artifactItems>
<outputDirectory>${project.build.directory}/alfresco-mmt</outputDirectory> </configuration>
</artifactItem> </execution>
</artifactItems>
</configuration> <execution>
</execution> <id>copy-amps</id>
<phase>process-resources</phase>
<execution> <goals>
<id>copy-amps</id> <goal>copy</goal>
<phase>process-resources</phase> </goals>
<goals> <configuration>
<goal>copy</goal> <artifactItems>
</goals> <artifactItem>
<configuration> <groupId>org.alfresco.aos-module</groupId>
<artifactItems> <artifactId>alfresco-aos-module</artifactId>
<artifactItem> <type>amp</type>
<groupId>org.alfresco.aos-module</groupId> <overWrite>false</overWrite>
<artifactId>alfresco-aos-module</artifactId> <outputDirectory>${project.build.directory}/amps</outputDirectory>
<type>amp</type> </artifactItem>
<overWrite>false</overWrite> <artifactItem>
<outputDirectory>${project.build.directory}/amps</outputDirectory> <groupId>org.alfresco.integrations</groupId>
</artifactItem> <artifactId>alfresco-googledrive-repo-community</artifactId>
<artifactItem> <type>amp</type>
<groupId>org.alfresco.integrations</groupId> <overWrite>false</overWrite>
<artifactId>alfresco-googledrive-repo-community</artifactId> <outputDirectory>${project.build.directory}/amps</outputDirectory>
<type>amp</type> </artifactItem>
<overWrite>false</overWrite> </artifactItems>
<outputDirectory>${project.build.directory}/amps</outputDirectory> </configuration>
</artifactItem> </execution>
</artifactItems> </executions>
</configuration> </plugin>
</execution> </plugins>
</executions> </build>
</plugin>
<profiles>
<plugin> <profile>
<groupId>io.fabric8</groupId> <id>communityDocker</id>
<artifactId>fabric8-maven-plugin</artifactId> <!-- builds "image:latest" locally -->
<version>${dependency.fabric8.version}</version> <build>
<configuration> <plugins>
<images> <plugin>
<image> <groupId>io.fabric8</groupId>
<name>${image.name}</name> <artifactId>fabric8-maven-plugin</artifactId>
<build> <configuration>
<dockerFileDir>${project.basedir}/</dockerFileDir> <images>
</build> <image>
</image> <name>${image.name}:${image.tag}</name>
</images> <build>
</configuration> <dockerFileDir>${project.basedir}/</dockerFileDir>
</plugin> <buildOptions>
</plugins> <squash>true</squash>
</build> </buildOptions>
</build>
<profiles> </image>
<profile> </images>
<id>communityDocker</id> </configuration>
<build> <executions>
<plugins> <execution>
<plugin> <id>build-image</id>
<groupId>io.fabric8</groupId> <phase>install</phase>
<artifactId>fabric8-maven-plugin</artifactId> <goals>
<version>${dependency.fabric8.version}</version> <goal>build</goal>
<executions> </goals>
<execution> </execution>
<id>build-image</id> </executions>
<phase>install</phase> </plugin>
<goals> </plugins>
<goal>build</goal> </build>
</goals> </profile>
</execution>
</executions> <profile>
</plugin> <id>internal</id>
</plugins> <!-- publishes "image:latest" on Quay & DockerHub -->
</build> <build>
</profile> <plugins>
<plugin>
<profile> <groupId>io.fabric8</groupId>
<id>internal</id> <artifactId>fabric8-maven-plugin</artifactId>
<build> <configuration>
<plugins> <images>
<plugin> <!-- Quay image -->
<groupId>io.fabric8</groupId> <image>
<artifactId>fabric8-maven-plugin</artifactId> <name>${image.name}:${image.tag}</name>
<version>${dependency.fabric8.version}</version> <registry>${image.registry}</registry>
<configuration> <build>
<images> <dockerFileDir>${project.basedir}/</dockerFileDir>
<image> <buildOptions>
<name>${image.name}:${image.tag}</name> <squash>true</squash>
<registry>${image.registry}</registry> </buildOptions>
<build> </build>
<dockerFileDir>${project.basedir}/</dockerFileDir> </image>
</build> <!-- DockerHub image -->
</image> <image>
</images> <name>${image.name}:${image.tag}</name>
</configuration> <build>
<executions> <dockerFileDir>${project.basedir}/</dockerFileDir>
<execution> <buildOptions>
<id>build-push-image</id> <squash>true</squash>
<phase>install</phase> </buildOptions>
<goals> </build>
<goal>build</goal> </image>
<goal>push</goal> </images>
</goals> </configuration>
</execution> <executions>
</executions> <execution>
</plugin> <id>build-push-image</id>
</plugins> <phase>install</phase>
</build> <goals>
</profile> <goal>build</goal>
<goal>push</goal>
<profile> </goals>
<id>master</id> </execution>
<build> </executions>
<plugins> </plugin>
<plugin> </plugins>
<groupId>io.fabric8</groupId> </build>
<artifactId>fabric8-maven-plugin</artifactId> </profile>
<version>${dependency.fabric8.version}</version>
<configuration> <profile>
<images> <id>release</id>
<image> <!-- publishes "image:release_version" on Quay & DockerHub -->
<name>${image.name}</name> <build>
<registry>${image.registry}</registry> <plugins>
<build> <plugin>
<dockerFileDir>${project.basedir}/</dockerFileDir> <groupId>io.fabric8</groupId>
</build> <artifactId>fabric8-maven-plugin</artifactId>
</image> <configuration combine.self="override">
<image> <images>
<name>${image.name}</name> <!-- Quay image -->
<build> <image>
<dockerFileDir>${project.basedir}/</dockerFileDir> <name>${image.name}:${project.version}</name>
</build> <registry>${image.registry}</registry>
</image> <build>
</images> <dockerFileDir>${project.basedir}/</dockerFileDir>
</configuration> <buildOptions>
<executions> <squash>true</squash>
<execution> </buildOptions>
<id>build-push-image</id> </build>
<phase>install</phase> </image>
<goals> <!-- DockerHub image -->
<goal>build</goal> <image>
<goal>push</goal> <name>${image.name}:${project.version}</name>
</goals> <build>
</execution> <dockerFileDir>${project.basedir}/</dockerFileDir>
</executions> <buildOptions>
</plugin> <squash>true</squash>
</plugins> </buildOptions>
</build> </build>
</profile> </image>
</images>
<profile> </configuration>
<id>release</id> <executions>
<build> <execution>
<plugins> <id>build-push-image</id>
<plugin> <phase>deploy</phase>
<groupId>io.fabric8</groupId> <goals>
<artifactId>fabric8-maven-plugin</artifactId> <goal>build</goal>
<version>${dependency.fabric8.version}</version> <goal>push</goal>
<configuration> </goals>
<images> </execution>
<image> </executions>
<alias>quay.io</alias> </plugin>
<name>${image.name}:${project.version}</name> </plugins>
<registry>${image.registry}</registry> </build>
<build> </profile>
<dockerFileDir>${project.basedir}/</dockerFileDir> </profiles>
</build> </project>
</image>
<image>
<alias>dockerhub</alias>
<name>${image.name}:${project.version}</name>
<build>
<dockerFileDir>${project.basedir}/</dockerFileDir>
</build>
</image>
</images>
</configuration>
<executions>
<execution>
<id>build-push-image</id>
<phase>deploy</phase>
<goals>
<goal>build</goal>
<goal>push</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>

View File

@@ -7,31 +7,12 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo</artifactId> <artifactId>alfresco-community-repo</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<scm>
<connection>scm:git:https://github.com/Alfresco/alfresco-community-repo-packaging.git</connection>
<developerConnection>scm:git:https://github.com/Alfresco/alfresco-community-repo-packaging.git</developerConnection>
<url>https://github.com/Alfresco/alfresco-community-repo-packaging</url>
<tag>HEAD</tag>
</scm>
<distributionManagement>
<repository>
<id>alfresco-internal</id>
<url>https://artifacts.alfresco.com/nexus/content/repositories/releases</url>
</repository>
<snapshotRepository>
<id>alfresco-internal-snapshots</id>
<url>https://artifacts.alfresco.com/nexus/content/repositories/snapshots</url>
</snapshotRepository>
</distributionManagement>
<properties> <properties>
<!-- Set to "Community Early Access" to add to the version.edition property in version.properties -->
<version.edition>Community</version.edition>
<image.tag>latest</image.tag> <image.tag>latest</image.tag>
<image.registry>quay.io</image.registry>
<installer.version.name>${project.version}</installer.version.name> <installer.version.name>${project.version}</installer.version.name>
<alfresco.package.name>alfresco-community</alfresco.package.name> <alfresco.package.name>alfresco-community</alfresco.package.name>
@@ -39,6 +20,16 @@
</properties> </properties>
<profiles> <profiles>
<profile>
<id>fullBuild</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<modules>
<module>war</module>
<module>docker-alfresco</module>
</modules>
</profile>
<profile> <profile>
<id>community</id> <id>community</id>
<modules> <modules>
@@ -52,16 +43,6 @@
<module>docker-alfresco</module> <module>docker-alfresco</module>
</modules> </modules>
</profile> </profile>
<profile>
<id>fullBuild</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<modules>
<module>war</module>
<module>docker-alfresco</module>
</modules>
</profile>
<profile> <profile>
<id>all-tas-tests</id> <id>all-tas-tests</id>
<modules> <modules>

View File

@@ -1,17 +0,0 @@
#!/usr/bin/env bash
set -ev
if [ -z ${COMM_RELEASE_VERSION} ] || [ -z ${RELEASE_VERSION} ];
then
echo "Please provide a COMM_RELEASE_VERSION and RELEASE_VERSION in the format <acs-version>-<additional-info> (6.3.0-EA or 6.3.0-SNAPSHOT)"
exit -1
fi
build_number=$1
branch_name=$2
build_stage=release
SOURCE=s3://alfresco-artefacts-staging/alfresco-content-services-community/$build_stage/$branch_name/$build_number
DESTINATION=s3://eu.dl.alfresco.com/release/community/$COMM_RELEASE_VERSION-build-$build_number
aws s3 cp --acl private $SOURCE/alfresco.war $DESTINATION/alfresco.war
aws s3 cp --acl private $SOURCE/alfresco-content-services-community-distribution-$RELEASE_VERSION.zip $DESTINATION/alfresco-content-services-community-distribution-$RELEASE_VERSION.zip

View File

@@ -1,31 +0,0 @@
#!/usr/bin/env bash
set -e
releaseVersion=$1
developmentVersion=$2
scm_path=$(mvn help:evaluate -Dexpression=project.scm.url -q -DforceStdout)
# Use full history for release
git checkout -B "${TRAVIS_BRANCH}"
# Add email to link commits to user
git config user.email "${GIT_EMAIL}"
if [ -z ${releaseVersion} ] || [ -z ${developmentVersion} ];
then echo "Please provide a Release and Development verison in the format <acs-version>-<additional-info> (6.3.0-EA or 6.3.0-SNAPSHOT)"
exit -1
else
mvn --batch-mode \
-PfullBuild,all-tas-tests \
-Dusername="${GIT_USERNAME}" \
-Dpassword="${GIT_PASSWORD}" \
-DreleaseVersion=${releaseVersion} \
-DdevelopmentVersion=${developmentVersion} \
-Dbuild-number=${TRAVIS_BUILD_NUMBER} \
-Dbuild-name="${TRAVIS_BUILD_STAGE_NAME}" \
-Dscm-path=${scm_path} \
-DscmCommentPrefix="[maven-release-plugin][skip ci]" \
-DskipTests \
"-Darguments=-DskipTests -Dbuild-number=${TRAVIS_BUILD_NUMBER} '-Dbuild-name=${TRAVIS_BUILD_STAGE_NAME}' -Dscm-path=${scm_path} -PfullBuild,all-tas-tests" \
release:clean release:prepare release:perform \
-Prelease
fi

View File

@@ -1,31 +0,0 @@
#!/usr/bin/env bash
set -e
if [ -v ${RELEASE_VERSION} ]||[ -z ${RELEASE_VERSION} ]; then
echo "Please provide a RELEASE_VERSION in the format <acs-version>-<additional-info> (6.3.0-EA or 6.3.0-SNAPSHOT)"
exit -1
fi
# get the image name from the pom file
alfresco_docker_image=$(mvn help:evaluate -f ./docker-alfresco/pom.xml -Dexpression=image.name -q -DforceStdout)
docker_image_full_name="$alfresco_docker_image:$RELEASE_VERSION"
function docker_image_exists() {
local image_full_name="$1"; shift
local wait_time="${1:-5}"
local search_term='Pulling|is up to date|not found'
echo "Looking to see if $image_full_name already exists..."
local result="$((timeout --preserve-status "$wait_time" docker 2>&1 pull "$image_full_name" &) | grep -v 'Pulling repository' | egrep -o "$search_term")"
test "$result" || { echo "Timed out too soon. Try using a wait_time greater than $wait_time..."; return 1 ;}
if echo $result | grep -vq 'not found'; then
true
else
false
fi
}
if docker_image_exists $docker_image_full_name; then
echo "Tag $RELEASE_VERSION already pushed, release process will interrupt."
exit -1
else
echo "The $RELEASE_VERSION tag was not found"
fi

View File

@@ -1,24 +1,24 @@
<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/xsd/maven-4.0.0.xsd"> <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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>alfresco-community-repo-tests</artifactId> <artifactId>alfresco-community-repo-tests</artifactId>
<packaging>pom</packaging> <packaging>pom</packaging>
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo-packaging</artifactId> <artifactId>alfresco-community-repo-packaging</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<modules> <modules>
<module>tas-restapi</module> <module>tas-restapi</module>
<module>tas-cmis</module> <module>tas-cmis</module>
<module>tas-email</module> <module>tas-email</module>
<module>tas-webdav</module> <module>tas-webdav</module>
<module>tas-integration</module> <module>tas-integration</module>
</modules> </modules>
<properties> <properties>
<!-- TAS tests require an old version --> <!-- TAS tests require an old version -->
<dependency.org-json.version>20170516</dependency.org-json.version> <dependency.org-json.version>20170516</dependency.org-json.version>
</properties> </properties>
</project> </project>

View File

@@ -1,64 +1,64 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<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/xsd/maven-4.0.0.xsd"> <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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<groupId>org.alfresco.tas</groupId> <groupId>org.alfresco.tas</groupId>
<artifactId>alfresco-community-repo-cmis-test</artifactId> <artifactId>alfresco-community-repo-cmis-test</artifactId>
<name>cmis test</name> <name>cmis test</name>
<packaging>jar</packaging> <packaging>jar</packaging>
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo-tests</artifactId> <artifactId>alfresco-community-repo-tests</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<developers> <developers>
<developer> <developer>
<name>Paul Brodner</name> <name>Paul Brodner</name>
<roles> <roles>
<role>Test Automation Architect</role> <role>Test Automation Architect</role>
</roles> </roles>
</developer> </developer>
</developers> </developers>
<properties> <properties>
<suiteXmlFile>${project.basedir}/src/test/resources/cmis-suite.xml</suiteXmlFile> <suiteXmlFile>${project.basedir}/src/test/resources/cmis-suite.xml</suiteXmlFile>
</properties> </properties>
<dependencies> <dependencies>
<dependency> <dependency>
<groupId>org.alfresco.tas</groupId> <groupId>org.alfresco.tas</groupId>
<artifactId>cmis</artifactId> <artifactId>cmis</artifactId>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
</dependencies> </dependencies>
<build> <build>
<plugins> <plugins>
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId> <artifactId>maven-surefire-plugin</artifactId>
<configuration> <configuration>
<suiteXmlFiles> <suiteXmlFiles>
<suiteXmlFile>${suiteXmlFile}</suiteXmlFile> <suiteXmlFile>${suiteXmlFile}</suiteXmlFile>
</suiteXmlFiles> </suiteXmlFiles>
<argLine> <argLine>
--illegal-access=warn --illegal-access=warn
</argLine> </argLine>
</configuration> </configuration>
</plugin> </plugin>
<!-- Build only test jar --> <!-- Build only test jar -->
<plugin> <plugin>
<groupId>org.apache.maven.plugins</groupId> <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId> <artifactId>maven-jar-plugin</artifactId>
<executions> <executions>
<execution> <execution>
<goals> <goals>
<goal>test-jar</goal> <goal>test-jar</goal>
</goals> </goals>
</execution> </execution>
</executions> </executions>
</plugin> </plugin>
</plugins> </plugins>
</build> </build>
</project> </project>

View File

@@ -9,8 +9,8 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo-tests</artifactId> <artifactId>alfresco-community-repo-tests</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<developers> <developers>
<developer> <developer>

View File

@@ -9,8 +9,8 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo-tests</artifactId> <artifactId>alfresco-community-repo-tests</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<developers> <developers>
<developer> <developer>

View File

@@ -9,8 +9,8 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo-tests</artifactId> <artifactId>alfresco-community-repo-tests</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<developers> <developers>
<developer> <developer>

View File

@@ -9,8 +9,8 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo-tests</artifactId> <artifactId>alfresco-community-repo-tests</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<developers> <developers>
<developer> <developer>

View File

@@ -1,282 +1,259 @@
<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/xsd/maven-4.0.0.xsd"> <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/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>content-services-community</artifactId> <artifactId>content-services-community</artifactId>
<name>Alfresco Content Services Community WAR</name> <name>Alfresco Content Services Community WAR</name>
<packaging>war</packaging> <packaging>war</packaging>
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo-packaging</artifactId> <artifactId>alfresco-community-repo-packaging</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<properties> <properties>
<scm-path>local/development/workspace</scm-path> <scm-path>${project.parent.parent.scm.url}</scm-path>
<scm-revision>${buildNumber}</scm-revision> <scm-revision>${build-number}</scm-revision>
<licenseName>community</licenseName> <licenseName>community</licenseName>
</properties> </properties>
<dependencies> <dependencies>
<dependency> <dependency>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-repository</artifactId> <artifactId>alfresco-repository</artifactId>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-remote-api</artifactId> <artifactId>alfresco-remote-api</artifactId>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-trashcan-cleaner</artifactId> <artifactId>alfresco-trashcan-cleaner</artifactId>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.alfresco.services</groupId> <groupId>org.alfresco.services</groupId>
<artifactId>alfresco-messaging-repo</artifactId> <artifactId>alfresco-messaging-repo</artifactId>
</dependency> </dependency>
<dependency> <dependency>
<groupId>xalan</groupId> <groupId>xalan</groupId>
<artifactId>xalan</artifactId> <artifactId>xalan</artifactId>
</dependency> </dependency>
<dependency> <dependency>
<groupId>commons-logging</groupId> <groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId> <artifactId>commons-logging</artifactId>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.apache.avalon.framework</groupId> <groupId>org.apache.avalon.framework</groupId>
<artifactId>avalon-framework-api</artifactId> <artifactId>avalon-framework-api</artifactId>
<version>4.3.1</version> <version>4.3.1</version>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.apache.avalon.framework</groupId> <groupId>org.apache.avalon.framework</groupId>
<artifactId>avalon-framework-impl</artifactId> <artifactId>avalon-framework-impl</artifactId>
<version>4.3.1</version> <version>4.3.1</version>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-log-sanitizer</artifactId> <artifactId>alfresco-log-sanitizer</artifactId>
</dependency> </dependency>
<!-- REPO-3918 needed libraries for Java 11 --> <!-- REPO-3918 needed libraries for Java 11 -->
<dependency> <dependency>
<groupId>org.glassfish.jaxb</groupId> <groupId>org.glassfish.jaxb</groupId>
<artifactId>jaxb-runtime</artifactId> <artifactId>jaxb-runtime</artifactId>
<version>2.3.2</version> <version>2.3.2</version>
</dependency> </dependency>
<dependency> <dependency>
<groupId>javax.xml.soap</groupId> <groupId>javax.xml.soap</groupId>
<artifactId>javax.xml.soap-api</artifactId> <artifactId>javax.xml.soap-api</artifactId>
<version>1.4.0</version> <version>1.4.0</version>
</dependency> </dependency>
<!-- 'provided' dependencies, not packaged in war --> <!-- 'provided' dependencies, not packaged in war -->
<dependency> <dependency>
<groupId>javax.servlet</groupId> <groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId> <artifactId>javax.servlet-api</artifactId>
<scope>provided</scope> <scope>provided</scope>
</dependency> </dependency>
<!-- Test dependencies --> <!-- Test dependencies -->
<dependency> <dependency>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-core</artifactId> <artifactId>alfresco-core</artifactId>
<classifier>tests</classifier> <classifier>tests</classifier>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-repository</artifactId> <artifactId>alfresco-repository</artifactId>
<classifier>tests</classifier> <classifier>tests</classifier>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-remote-api</artifactId> <artifactId>alfresco-remote-api</artifactId>
<classifier>tests</classifier> <classifier>tests</classifier>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
<!-- required by GDocs--> <!-- required by GDocs-->
<dependency> <dependency>
<groupId>commons-lang</groupId> <groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId> <artifactId>commons-lang</artifactId>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.springframework</groupId> <groupId>org.springframework</groupId>
<artifactId>spring-test</artifactId> <artifactId>spring-test</artifactId>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.mockito</groupId> <groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId> <artifactId>mockito-core</artifactId>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.apache.shale</groupId> <groupId>org.apache.shale</groupId>
<artifactId>shale-test</artifactId> <artifactId>shale-test</artifactId>
<version>1.0.5</version> <version>1.0.5</version>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.postgresql</groupId> <groupId>org.postgresql</groupId>
<artifactId>postgresql</artifactId> <artifactId>postgresql</artifactId>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
<dependency> <dependency>
<groupId>mysql</groupId> <groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId> <artifactId>mysql-connector-java</artifactId>
<scope>test</scope> <scope>test</scope>
</dependency> </dependency>
</dependencies> </dependencies>
<build> <build>
<finalName>alfresco</finalName> <finalName>alfresco</finalName>
<resources> <resources>
<!-- Allow replacing variables inside version.properties --> <!-- Allow replacing variables inside version.properties -->
<resource> <resource>
<directory>src/main/resources</directory> <directory>src/main/resources</directory>
<excludes> <excludes>
<exclude>alfresco/version.properties</exclude> <exclude>alfresco/version.properties</exclude>
</excludes> </excludes>
</resource> </resource>
<resource> <resource>
<directory>src/main/resources</directory> <directory>src/main/resources</directory>
<includes> <includes>
<include>alfresco/version.properties</include> <include>alfresco/version.properties</include>
</includes> </includes>
<filtering>true</filtering> <filtering>true</filtering>
</resource> </resource>
</resources> </resources>
<plugins> <plugins>
<!-- Creates a scm revision and stores in ${buildNumber} variable --> <plugin>
<plugin> <artifactId>maven-dependency-plugin</artifactId>
<groupId>org.codehaus.mojo</groupId> <executions>
<artifactId>buildnumber-maven-plugin</artifactId> <!-- CLOUD-1967 Put core log4j config in WEB-INF/classes, so that it's first in classloader -->
<version>1.4</version> <execution>
<executions> <id>fetch-log4j-config</id>
<execution> <phase>prepare-package</phase>
<phase>validate</phase> <goals>
<goals> <goal>unpack</goal>
<goal>create</goal> </goals>
</goals> <configuration>
</execution> <artifactItems>
</executions> <artifactItem>
<configuration> <groupId>org.alfresco</groupId>
<shortRevisionLength>8</shortRevisionLength> <artifactId>alfresco-core</artifactId>
</configuration> </artifactItem>
</plugin> </artifactItems>
<plugin> <includes>log*.properties</includes>
<artifactId>maven-dependency-plugin</artifactId> <outputDirectory>${project.build.outputDirectory}</outputDirectory>
<executions> </configuration>
<!-- CLOUD-1967 Put core log4j config in WEB-INF/classes, so that it's first in classloader --> </execution>
<execution> </executions>
<id>fetch-log4j-config</id> </plugin>
<phase>prepare-package</phase>
<goals> <plugin>
<goal>unpack</goal> <artifactId>maven-war-plugin</artifactId>
</goals> <version>3.3.1</version>
<configuration> <!-- This allows overlays to be prepared on the FS for minification and faster run -->
<artifactItems> <executions>
<artifactItem> <execution>
<groupId>org.alfresco</groupId> <id>pre-exploded-war</id>
<artifactId>alfresco-core</artifactId> <goals>
</artifactItem> <goal>exploded</goal>
</artifactItems> </goals>
<includes>log*.properties</includes> <phase>prepare-package</phase>
<outputDirectory>${project.build.outputDirectory}</outputDirectory> </execution>
</configuration> </executions>
</execution> </plugin>
</executions>
</plugin> <plugin>
<groupId>org.codehaus.mojo</groupId>
<plugin> <artifactId>license-maven-plugin</artifactId>
<artifactId>maven-war-plugin</artifactId> <configuration>
<version>3.3.1</version> <addJavaLicenseAfterPackage>false</addJavaLicenseAfterPackage>
<!-- This allows overlays to be prepared on the FS for minification and faster run --> <organizationName>Alfresco Software Limited</organizationName>
<executions> <failOnMissingHeader>true</failOnMissingHeader>
<execution> <failOnNotUptodateHeader>true</failOnNotUptodateHeader>
<id>pre-exploded-war</id> <licenseResolver>classpath://alfresco</licenseResolver>
<goals> <licenseName>${licenseName}</licenseName>
<goal>exploded</goal> <roots>
</goals> <root>src</root>
<phase>prepare-package</phase> </roots>
</execution> <includes>
</executions> <include>**/*.java</include>
</plugin> <include>**/*.jsp</include>
</includes>
<plugin> </configuration>
<groupId>org.codehaus.mojo</groupId> <executions>
<artifactId>license-maven-plugin</artifactId> <execution>
<configuration> <id>check-licenses</id>
<addJavaLicenseAfterPackage>false</addJavaLicenseAfterPackage> <phase>compile</phase>
<organizationName>Alfresco Software Limited</organizationName> <goals>
<failOnMissingHeader>true</failOnMissingHeader> <goal>check-file-header</goal>
<failOnNotUptodateHeader>true</failOnNotUptodateHeader> </goals>
<licenseResolver>classpath://alfresco</licenseResolver> </execution>
<licenseName>${licenseName}</licenseName> </executions>
<roots> <dependencies>
<root>src</root> <dependency>
</roots> <groupId>org.alfresco</groupId>
<includes> <artifactId>alfresco-license-headers</artifactId>
<include>**/*.java</include> <version>1.0</version>
<include>**/*.jsp</include> </dependency>
</includes> </dependencies>
</configuration> </plugin>
<executions> </plugins>
<execution> <pluginManagement>
<id>check-licenses</id> <plugins>
<phase>compile</phase> <!-- Specify the source version to get around a "feature" in JDK 11.0.2 currently used by travis-->
<goals> <plugin>
<goal>check-file-header</goal> <groupId>org.apache.maven.plugins</groupId>
</goals> <artifactId>maven-javadoc-plugin</artifactId>
</execution> <configuration>
</executions> <source>${maven.build.sourceVersion}</source>
<dependencies> </configuration>
<dependency> </plugin>
<groupId>org.alfresco</groupId> <plugin>
<artifactId>alfresco-license-headers</artifactId> <groupId>org.codehaus.mojo</groupId>
<version>1.0</version> <artifactId>license-maven-plugin</artifactId>
</dependency> <version>1.13</version>
</dependencies> </plugin>
</plugin> </plugins>
</plugins> </pluginManagement>
<pluginManagement> </build>
<plugins>
<!-- Specify the source version to get around a "feature" in JDK 11.0.2 currently used by travis--> <profiles>
<plugin> <!-- Tweaks required to make the build work in Eclipse -->
<groupId>org.apache.maven.plugins</groupId> <profile>
<artifactId>maven-javadoc-plugin</artifactId> <id>m2e</id>
<version>${dependency.maven-jar-plugin.version}</version> <dependencies>
<configuration> <dependency>
<source>${maven.build.sourceVersion}</source> <groupId>commons-logging</groupId>
</configuration> <artifactId>commons-logging</artifactId>
</plugin> <!-- This is needed for Maven tomcat run -->
<!-- Ensure consistent maven-release-plugin version--> <scope>runtime</scope>
<plugin> </dependency>
<artifactId>maven-release-plugin</artifactId> <dependency>
<version>2.5.3</version> <groupId>mysql</groupId>
</plugin> <artifactId>mysql-connector-java</artifactId>
<plugin> </dependency>
<groupId>org.codehaus.mojo</groupId> </dependencies>
<artifactId>license-maven-plugin</artifactId> </profile>
<version>1.13</version> </profiles>
</plugin> </project>
</plugins>
</pluginManagement>
</build>
<profiles>
<!-- Tweaks required to make the build work in Eclipse -->
<profile>
<id>m2e</id>
<dependencies>
<dependency>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
<!-- This is needed for Maven tomcat run -->
<scope>runtime</scope>
</dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
</dependency>
</dependencies>
</profile>
</profiles>
</project>

1519
pom.xml

File diff suppressed because it is too large Load Diff

View File

@@ -7,26 +7,8 @@
<parent> <parent>
<groupId>org.alfresco</groupId> <groupId>org.alfresco</groupId>
<artifactId>alfresco-community-repo</artifactId> <artifactId>alfresco-community-repo</artifactId>
<version>8.300-SNAPSHOT</version> <version>8.300-TEST1-SNAPSHOT</version>
</parent> </parent>
<scm>
<connection>scm:git:https://github.com/Alfresco/alfresco-remote-api.git</connection>
<developerConnection>scm:git:https://github.com/Alfresco/alfresco-remote-api.git</developerConnection>
<url>https://github.com/Alfresco/alfresco-remote-api</url>
<tag>HEAD</tag>
</scm>
<distributionManagement>
<repository>
<id>alfresco-public</id>
<url>https://artifacts.alfresco.com/nexus/content/repositories/releases</url>
</repository>
<snapshotRepository>
<id>alfresco-public</id>
<url>https://artifacts.alfresco.com/nexus/content/repositories/snapshots</url>
</snapshotRepository>
</distributionManagement>
<properties> <properties>
<licenseName>community</licenseName> <licenseName>community</licenseName>

File diff suppressed because it is too large Load Diff

9
scripts/travis/build.sh Normal file
View File

@@ -0,0 +1,9 @@
#!/usr/bin/env bash
set -ev
pushd "$(dirname "${BASH_SOURCE[0]}")/../../"
PROFILES="$([ "${TRAVIS_BUILD_STAGE_NAME,,}" = "release" ] && echo "-Pinternal" || echo "-PcommunityDocker" )"
mvn -B -V install -DskipTests -Dmaven.javadoc.skip=true "${PROFILES}"

View File

@@ -0,0 +1,96 @@
#!/usr/bin/env bash
function isPullRequestBuild() {
test "${TRAVIS_PULL_REQUEST}" != "false"
}
function isBranchBuild() {
test "${TRAVIS_PULL_REQUEST}" = "false"
}
function cloneRepo() {
local REPO="${1}"
local TAG_OR_BRANCH="${2}"
# clone the repository branch/tag
pushd "$(dirname "${BASH_SOURCE[0]}")/../../../" >/dev/null
rm -rf "$(basename "${REPO%.git}")"
git clone -b "${TAG_OR_BRANCH}" --depth=1 "https://${GIT_USERNAME}:${GIT_PASSWORD}@${REPO}"
popd >/dev/null
}
function retrievePomParentVersion() {
pushd "$(dirname "${BASH_SOURCE[0]}")/../../" >/dev/null
sed -n '/<parent>/,/<\/parent>/p' pom.xml \
| sed -n '/<version>/,/<\/version>/p' \
| tr -d '\n' \
| grep -oP '(?<=<version>).*(?=</version>)' \
| xargs
popd >/dev/null
}
function retrievePomProperty() {
local KEY="${1}"
pushd "$(dirname "${BASH_SOURCE[0]}")/../../" >/dev/null
sed -n '/<properties>/,/<\/properties>/p' pom.xml \
| sed -n "/<${KEY}>/,/<\/${KEY}>/p" \
| tr -d '\n' \
| grep -oP "(?<=<${KEY}>).*(?=</${KEY}>)" \
| xargs
popd >/dev/null
}
function evaluatePomProperty() {
local KEY="${1}"
pushd "$(dirname "${BASH_SOURCE[0]}")/../../" >/dev/null
mvn -B -q help:evaluate -Dexpression="${KEY}" -DforceStdout
popd >/dev/null
}
function remoteBranchExists() {
local REMOTE_REPO="${1}"
local BRANCH="${2}"
git ls-remote --exit-code --heads "https://${GIT_USERNAME}:${GIT_PASSWORD}@${REMOTE_REPO}" "${BRANCH}"
}
function pullUpstreamTag() {
local UPSTREAM_REPO="${1}"
local TAG="${2}"
cloneRepo "${UPSTREAM_REPO}" "${TAG}"
}
function pullAndBuildSameBranchOnUpstream() {
local UPSTREAM_REPO="${1}"
local EXTRA_BUILD_ARGUMENTS="${2}"
local SOURCE_BRANCH="$(isBranchBuild && echo "${TRAVIS_BRANCH}" || echo "${TRAVIS_PULL_REQUEST_BRANCH}")"
if ! remoteBranchExists "${UPSTREAM_REPO}" "${SOURCE_BRANCH}" ; then
printf "Branch \"%s\" not found on the %s repository\n" "${SOURCE_BRANCH}" "${UPSTREAM_REPO}"
exit 1
fi
cloneRepo "${UPSTREAM_REPO}" "${SOURCE_BRANCH}"
pushd "$(dirname "${BASH_SOURCE[0]}")/../../../"
cd "$(basename "${UPSTREAM_REPO%.git}")"
mvn -B -V -q clean install -DskipTests -Dmaven.javadoc.skip=true ${EXTRA_BUILD_ARGUMENTS}
mvn -B -V install -DskipTests -f packaging/tests/pom.xml
popd
}

View File

@@ -0,0 +1,19 @@
#!/usr/bin/env bash
set -ev
rm -rf "${HOME}/.m2/repository/org/alfresco/acs-community-packaging"
rm -rf "${HOME}/.m2/repository/org/alfresco/alfresco-community-repo"
rm -rf "${HOME}/.m2/repository/org/alfresco/alfresco-community-repo-*"
rm -rf "${HOME}/.m2/repository/org/alfresco/alfresco-core"
rm -rf "${HOME}/.m2/repository/org/alfresco/alfresco-data-model"
rm -rf "${HOME}/.m2/repository/org/alfresco/alfresco-enterprise-remote-api"
rm -rf "${HOME}/.m2/repository/org/alfresco/alfresco-enterprise-repo-*"
rm -rf "${HOME}/.m2/repository/org/alfresco/alfresco-enterprise-repository"
rm -rf "${HOME}/.m2/repository/org/alfresco/alfresco-remote-api"
rm -rf "${HOME}/.m2/repository/org/alfresco/alfresco-repository"
rm -rf "${HOME}/.m2/repository/org/alfresco/content-services"
rm -rf "${HOME}/.m2/repository/org/alfresco/content-services*"
rm -rf "${HOME}/.m2/repository/org/alfresco/content-services-community"
rm -rf "${HOME}/.m2/repository/org/alfresco/tas/alfresco-community-repo-*-test"
rm -rf "${HOME}/.m2/repository/org/alfresco/tas/alfresco-enterprise-repo-*-test"

18
scripts/travis/init.sh Normal file
View File

@@ -0,0 +1,18 @@
#!/usr/bin/env bash
set -ev
pushd "$(dirname "${BASH_SOURCE[0]}")/../../"
# Maven Setup
mkdir -p "${HOME}/.m2" && cp -f .travis.settings.xml "${HOME}/.m2/settings.xml"
find "${HOME}/.m2/repository/" -type d -name "*-SNAPSHOT*" | xargs -r -l rm -rf
# Docker Logins
echo "${QUAY_PASSWORD}" | docker login -u="${QUAY_USERNAME}" --password-stdin quay.io
# Enable experimental docker features (for the image squash option)
echo '{"experimental":true}' | sudo tee /etc/docker/daemon.json
sudo service docker restart
# not helpful in this script
# export HOST_IP=$(hostname -I | cut -f1 -d' ')

17
scripts/travis/maven_release.sh Executable file
View File

@@ -0,0 +1,17 @@
#!/usr/bin/env bash
set -ev
# Use full history for release
git checkout -B "${TRAVIS_BRANCH}"
# Add email to link commits to user
git config user.email "${GIT_EMAIL}"
# Run the release plugin - with "[skip ci]" in the release commit message
mvn -B \
-Prelease,fullBuild,all-tas-tests \
"-Darguments=-Prelease,fullBuild,all-tas-tests -DskipTests -Dbuild-number=${TRAVIS_BUILD_NUMBER}" \
release:clean release:prepare release:perform \
-DscmCommentPrefix="[maven-release-plugin][skip ci] " \
-Dusername="${GIT_USERNAME}" \
-Dpassword="${GIT_PASSWORD}"

View File

@@ -0,0 +1,48 @@
#!/usr/bin/env bash
set -ev
USER=${1}
REPO=${2}
BRANCH=${3}
if [ "${TRAVIS_PULL_REQUEST}" != "false" ]; then
echo "Downstream projects shouldn't be triggered from PR builds"
exit 1
fi
if ! git ls-remote --exit-code --heads "https://${GIT_USERNAME}:${GIT_PASSWORD}@github.com/${USER}/${REPO}.git" "${BRANCH}" ; then
echo "Branch \"${BRANCH}\" not found on the downstream repository ${USER}/${REPO}. Exiting..."
exit 0
fi
URL="https://api.travis-ci.com/repo/${USER}%2F${REPO}/requests"
BODY="{
\"request\": {
\"branch\":\"${BRANCH}\"
}}"
printf "Travis API call:\n URL: %s\n Body: %s\n\n" "${URL}" "${BODY}"
curl -s -X POST \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "Travis-API-Version: 3" \
-H "Authorization: token ${TRAVIS_ACCESS_TOKEN_TEMP}" \
-d "${BODY}" \
"${URL}" \
| tee /tmp/travis-request-output.txt
cat /tmp/travis-request-output.txt
if grep -q '"@type": "error"' /tmp/travis-request-output.txt; then
echo "Error when triggering build..."
exit 2
fi
if grep -q 'access denied' /tmp/travis-request-output.txt; then
echo "Access denied when triggering build..."
exit 3
fi
exit 0

View File

@@ -0,0 +1,38 @@
#!/usr/bin/env bash
set -ev
#
# Check that the version to be released does not already have a docker tag.
#
POM_VERSION=$(mvn -B -q help:evaluate -Dexpression=project.version -DforceStdout)
printf "POM version: %s\n" "${POM_VERSION}"
IMAGE_TAG="${POM_VERSION%-SNAPSHOT}"
# get the image name from the pom file
ALFRESCO_DOCKER_IMAGE="$(mvn -B -q help:evaluate -f ./packaging/docker-alfresco/pom.xml -Dexpression=image.name -DforceStdout)"
DOCKER_IMAGE_FULL_NAME="${ALFRESCO_DOCKER_IMAGE}:${IMAGE_TAG}"
function docker_image_exists() {
local IMAGE_FULL_NAME="${1}"; shift
local WAIT_TIME="${1:-5}"
local SEARCH_TERM='Pulling|is up to date|not found'
echo "Looking to see if ${IMAGE_FULL_NAME} already exists..."
local RESULT=$( (timeout --preserve-status "${WAIT_TIME}" docker 2>&1 pull "${IMAGE_FULL_NAME}" &) | grep -v 'Pulling repository' | grep -E -o "${SEARCH_TERM}")
test "${RESULT}" || { echo "Timed out too soon. Try using a wait_time greater than ${WAIT_TIME}..."; return 1 ;}
if echo "${RESULT}" | grep -vq 'not found'; then
true
else
false
fi
}
if docker_image_exists "${DOCKER_IMAGE_FULL_NAME}" ; then
echo "Tag ${RELEASE_VERSION} already pushed, release process will interrupt."
exit 1
else
echo "The ${RELEASE_VERSION} tag was not found"
fi

View File

@@ -1,26 +0,0 @@
#!/usr/bin/env bash
USER=${1}
REPO=${2}
BRANCH=${3}
body="{
\"request\": {
\"branch\":\"${BRANCH}\"
}}"
curl -s -X POST \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-H "Travis-API-Version: 3" \
-H "Authorization: token ${TRAVIS_ACCESS_TOKEN}" \
-d "${body}" \
https://api.travis-ci.com/repo/${USER}%2F${REPO}/requests \
| tee /tmp/travis-request-output.txt
if grep -q '"@type": "error"' /tmp/travis-request-output.txt; then
exit 1
fi
if grep -q 'access denied' /tmp/travis-request-output.txt; then
exit 1
fi