Compare commits

...
16 Commits
99 changed files with 1312 additions and 856 deletions
+1 -1
View File
@@ -83,7 +83,7 @@ The following tiles (side-loaded components) are useful to users of the BeeDK.
If your project includes RAD tiles, you can start the application with the following command.
```sh
mvn -Drad process-classes
mvn -Drad process-test-classes
```
To stop RAD and remove the Docker containers, you will need to do it through Docker commands. This will differ between operating systems. The Maven Archetypes provides scripts to assist with these operations called `rad.sh` or `rad.ps1`.
@@ -42,7 +42,7 @@
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>2.40</version>
<version>2.45</version>
<extensions>true</extensions>
<configuration>
<!-- This assures the parent properties override defaults in the tiles -->
@@ -35,7 +35,7 @@
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>2.40</version>
<version>2.45</version>
<extensions>true</extensions>
<configuration>
<!-- This assures the parent properties override defaults in the tiles -->
@@ -12,14 +12,15 @@
<name>${shortname} ACS All-in-one Parent Project</name>
<properties>
<alfresco.sdk.version>4.8.0</alfresco.sdk.version>
<alfresco.sdk.version>4.15.0</alfresco.sdk.version>
<edition>community</edition>
<alfresco.platform.version>7.4.2</alfresco.platform.version>
<alfresco.share.version>22.17</alfresco.share.version>
<alfresco.platform.version>26.1.0</alfresco.platform.version>
<alfresco.share.version>26.1.0</alfresco.share.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>8</maven.compiler.source>
<maven.compiler.target>8</maven.compiler.target>
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
<maven.compiler.release>11</maven.compiler.release>
</properties>
<modules>
@@ -44,7 +44,7 @@
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>2.40</version>
<version>2.45</version>
<extensions>true</extensions>
<configuration>
<!-- This assures the parent properties override defaults in the tiles -->
@@ -35,7 +35,7 @@
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>2.40</version>
<version>2.45</version>
<extensions>true</extensions>
<configuration>
<!-- This assures the parent properties override defaults in the tiles -->
@@ -16,9 +16,8 @@
<name>${shortname} Alfresco T-Engine A</name>
<properties>
<ats.version>2.3.6</ats.version>
<spring-boot.version>2.3.5.RELEASE</spring-boot.version>
<activemq.version>5.15.8</activemq.version>
<ats.version>5.2.5</ats.version>
<spring-boot.version>3.5.7</spring-boot.version>
<docker.image.registry>${dockerRegistryHost}</docker.image.registry>
<docker.image.name>${dockerImagePrefix}/${project.artifactId}</docker.image.name>
@@ -53,7 +52,7 @@
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>2.40</version>
<version>2.45</version>
<extensions>true</extensions>
<configuration>
<!-- This assures the parent properties override defaults in the tiles -->
+8 -8
View File
@@ -55,14 +55,14 @@ The following properties are intended to be exposed by inheriting Public API Mav
### Plugin Versions
| Maven Property |
| ---------------------------------- |
| `maven-jar-plugin.version` |
| `build-helper-plugin.version` |
| `download-plugin.version` |
| `regex-plugin.version` |
| `conditional-plugin.version` |
| `amp-plugin.version` |
| Maven Property |
| ----------------------------------- |
| `maven-jar-plugin.version` |
| `build-helper-maven-plugin.version` |
| `download-maven-plugin.version` |
| `regex-maven-plugin.version` |
| `conditional-maven-plugin.version` |
| `amp-maven-plugin.version` |
## Results
+75 -86
View File
@@ -33,7 +33,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>${build-helper-plugin.version}</version>
<version>${build-helper-maven-plugin.version}</version>
<executions>
<execution>
<id>module-snapshot-timestamp</id>
@@ -45,41 +45,6 @@
<pattern>yyyyMMddHHmmss</pattern>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.inteligr8</groupId>
<artifactId>regex-maven-plugin</artifactId>
<version>${regex-plugin.version}</version>
<executions>
<execution>
<id>acs-module-version</id>
<phase>initialize</phase>
<goals><goal>replace-text</goal></goals>
<configuration>
<text>${project.version}</text>
<newProperty>module.version</newProperty>
<regexes>
<!-- turn -SNAPSHOT into ATIMESTAMP -->
<regex>
<pattern>^(.*)-SNAPSHOT$</pattern>
<replacement>$1-A${module.timestamp}</replacement>
</regex>
<!-- all others are just a copy -->
<regex>
<pattern>^(.*)$</pattern>
<replacement>$1</replacement>
</regex>
</regexes>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>${build-helper-plugin.version}</version>
<executions>
<execution>
<id>add-acs-module-resources</id>
<phase>generate-resources</phase>
@@ -133,11 +98,75 @@
</resources>
</configuration>
</execution>
<!-- This execution enables/disables the AMP file during the install phases -->
<execution>
<id>attach-amp</id>
<phase>post-integration-test</phase>
<goals>
<goal>attach-artifact</goal>
</goals>
<configuration>
<artifacts>
<artifact>
<type>amp</type>
<file>${project.build.directory}/${project.artifactId}-${project.version}.amp</file>
</artifact>
</artifacts>
<skipAttach>${beedk.noAmp}</skipAttach>
</configuration>
</execution>
<!-- This execution enables/disables the AMP file during the deploy phases -->
<execution>
<id>attach-amp-classifier</id>
<phase>post-integration-test</phase>
<goals>
<goal>attach-artifact</goal>
</goals>
<configuration>
<artifacts>
<artifact>
<type>amp</type>
<classifier>${alfresco.module.classifier}</classifier>
<file>${project.build.directory}/${project.artifactId}-${project.version}-${alfresco.module.classifier}.amp</file>
</artifact>
</artifacts>
<skipAttach>${beedk.noAmpClassifier}</skipAttach>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.inteligr8</groupId>
<artifactId>regex-maven-plugin</artifactId>
<version>${regex-maven-plugin.version}</version>
<executions>
<execution>
<id>acs-module-version</id>
<phase>initialize</phase>
<goals><goal>replace-text</goal></goals>
<configuration>
<text>${project.version}</text>
<newProperty>module.version</newProperty>
<regexes>
<!-- turn -SNAPSHOT into ATIMESTAMP -->
<regex>
<pattern>^(.*)-SNAPSHOT$</pattern>
<replacement>$1-A${module.timestamp}</replacement>
</regex>
<!-- all others are just a copy -->
<regex>
<pattern>^(.*)$</pattern>
<replacement>$1</replacement>
</regex>
</regexes>
</configuration>
</execution>
</executions>
</plugin>
<!-- This plugin prevents binary file formats from being corrupted due to filtering -->
<plugin>
<artifactId>maven-resources-plugin</artifactId>
<version>${maven-resources-plugin.version}</version>
<configuration>
<encoding>UTF-8</encoding>
<nonFilteredFileExtensions>
@@ -262,7 +291,7 @@
<plugin>
<groupId>com.inteligr8.alfresco</groupId>
<artifactId>amp-maven-plugin</artifactId>
<version>${amp-plugin.version}</version>
<version>${amp-maven-plugin.version}</version>
<executions>
<execution>
<id>build-amp-file</id>
@@ -281,7 +310,7 @@
<plugin>
<groupId>com.inteligr8</groupId>
<artifactId>conditional-maven-plugin</artifactId>
<version>${conditional-plugin.version}</version>
<version>${conditional-maven-plugin.version}</version>
<executions>
<execution>
<id>check-amp-file</id>
@@ -311,47 +340,6 @@
</execution>
</executions>
</plugin>
<!-- This plugin enables/disables the AMP file during the install/deploy phases -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>${build-helper-plugin.version}</version>
<executions>
<execution>
<id>attach-amp</id>
<phase>post-integration-test</phase>
<goals>
<goal>attach-artifact</goal>
</goals>
<configuration>
<artifacts>
<artifact>
<type>amp</type>
<file>${project.build.directory}/${project.artifactId}-${project.version}.amp</file>
</artifact>
</artifacts>
<skipAttach>${beedk.noAmp}</skipAttach>
</configuration>
</execution>
<execution>
<id>attach-amp-classifier</id>
<phase>post-integration-test</phase>
<goals>
<goal>attach-artifact</goal>
</goals>
<configuration>
<artifacts>
<artifact>
<type>amp</type>
<classifier>${alfresco.module.classifier}</classifier>
<file>${project.build.directory}/${project.artifactId}-${project.version}-${alfresco.module.classifier}.amp</file>
</artifact>
</artifacts>
<skipAttach>${beedk.noAmpClassifier}</skipAttach>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
@@ -369,7 +357,7 @@
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>${download-plugin.version}</version>
<version>${download-maven-plugin.version}</version>
<executions>
<execution>
<id>download-module-props</id>
@@ -405,12 +393,13 @@
<alfresco.module.path>alfresco/module/${alfresco.module.pathname}</alfresco.module.path>
<!-- versions -->
<build-helper-plugin.version>3.6.1</build-helper-plugin.version>
<maven-jar-plugin.version>3.4.2</maven-jar-plugin.version>
<download-plugin.version>1.13.0</download-plugin.version>
<regex-plugin.version>1.0.7</regex-plugin.version>
<conditional-plugin.version>1.0.2</conditional-plugin.version>
<amp-plugin.version>1.1.5</amp-plugin.version>
<maven-resources-plugin.version>@maven-resources-plugin.version@</maven-resources-plugin.version>
<maven-jar-plugin.version>@maven-jar-plugin.version@</maven-jar-plugin.version>
<build-helper-maven-plugin.version>@build-helper-maven-plugin.version@</build-helper-maven-plugin.version>
<download-maven-plugin.version>@download-maven-plugin.version@</download-maven-plugin.version>
<regex-maven-plugin.version>@regex-maven-plugin.version@</regex-maven-plugin.version>
<conditional-maven-plugin.version>@conditional-maven-plugin.version@</conditional-maven-plugin.version>
<amp-maven-plugin.version>1.1.5</amp-maven-plugin.version>
</properties>
</profile>
</profiles>
+1 -1
View File
@@ -110,7 +110,7 @@
<!-- versions -->
<postgres.jdbc.version>42.2.18</postgres.jdbc.version>
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
<!-- configuring beedk-acs-platform-it-tile -->
<beedk.deploy.platform.warFile>${project.build.warDirectory}/${alfresco.platform.war.artifactId}-${alfresco.platform.war.version}.war</beedk.deploy.platform.warFile>
@@ -115,7 +115,7 @@
<!-- versions -->
<postgres.jdbc.version>42.2.18</postgres.jdbc.version>
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
<!-- configuring beedk-acs-platform-rad-tile -->
<beedk.deploy.platform.warFile>${project.build.warDirectory}/${alfresco.platform.war.artifactId}-${alfresco.platform.war.version}.war</beedk.deploy.platform.warFile>
+7 -1
View File
@@ -72,7 +72,7 @@ The following properties are only intended to be defined by BeeDK components.
| `beedk.deploy.acs-search.enabled` | | false | **Do not** set explicitly; just include the [`beedk-acs-search-it-tile`](/inteligr8/ootbee-beedk/src/branch/stable/beedk-acs-search-it-tile) tile **AFTER** this tile. |
| `beedk.deploy.alts.enabled` | | false | **Do not** set explicitly; just include the [`beedk-acs-lts-it-tile`](/inteligr8/ootbee-beedk/src/branch/stable/beedk-acs-lts-it-tile) tile **AFTER** this tile. |
| `beedk.deploy.ats.enabled` | | false | **Do not** set explicitly; just include the [`beedk-ats-it-tile`](/inteligr8/ootbee-beedk/src/branch/stable/beedk-ats-it-tile) tile **AFTER** this tile. |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-docker). |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-image). |
### Other APIs
@@ -80,6 +80,12 @@ Additional less important configurations are inherited from the following Maven
* [`beedk-run-tile`](/inteligr8/ootbee-beedk/src/branch/stable/beedk-run-tile)
### Plugin Versions
| Maven Property |
| ---------------------------------- |
| `fs-plugin.version` |
## Results
The ACS Platform, database, and MQ components will be started and stopped during the `pre-integration-test` and `post-integration-test` Maven phases, respectively.
+36 -3
View File
@@ -19,7 +19,36 @@
xsi:schemaLocation="http://tiles.bluetrainsoftware.com/maven/tiles/1.1.0 https://git.inteligr8.com/inteligr8/maven-tiles/raw/xsd/src/main/resources/maven-tiles.xsd">
<build>
<testResources>
<testResource>
<directory>${java.cacerts.directory}</directory>
<filtering>false</filtering>
<targetPath>${project.build.directory}/cacerts</targetPath>
</testResource>
</testResources>
<plugins>
<plugin>
<groupId>com.inteligr8</groupId>
<artifactId>fs-maven-plugin</artifactId>
<version>${fs-plugin.version}</version>
<executions>
<!-- creates missing directories used in volumes, which is required for podman -->
<execution>
<id>mkdirs-docker-volumes</id>
<phase>pre-integration-test</phase>
<goals><goal>mkdir</goal></goals>
<configuration>
<paths>
<path>${beedk.deploy.platform.classesDirectory}</path>
<path>${beedk.deploy.platform.testClassesDirectory}</path>
<path>${beedk.deploy.platform.extDirectory}</path>
<path>${beedk.deploy.platform.dataDirectory}</path>
<path>${project.build.directory}/cacerts</path>
</paths>
</configuration>
</execution>
</executions>
</plugin>
<!-- Using Docker to host the web application -->
<plugin>
<groupId>io.fabric8</groupId>
@@ -131,6 +160,7 @@
<volumes>
<bind>
<volume>${acs.license.directory}:/usr/local/tomcat/shared/classes/alfresco/extension/license:ro</volume>
<volume>${project.build.directory}/cacerts:/usr/local/share/ca-certificates:ro</volume>
<volume>${beedk.deploy.platform.warFile}:/var/lib/tomcat/webapps/alfresco.war:ro</volume>
<volume>${beedk.deploy.platform.classesDirectory}:/var/lib/tomcat/dev/classes:ro</volume>
<volume>${beedk.deploy.platform.testClassesDirectory}:/var/lib/tomcat/dev/classes-extra1:ro</volume>
@@ -206,6 +236,7 @@
<volumes>
<bind>
<volume>${acs.license.directory}:/usr/local/tomcat/shared/classes/alfresco/extension/license:ro</volume>
<volume>${project.build.directory}/cacerts:/usr/local/share/ca-certificates:ro</volume>
<volume>${beedk.deploy.platform.warFile}:/var/lib/tomcat/webapps/alfresco.war:ro</volume>
<volume>${beedk.deploy.platform.classesDirectory}:/var/lib/tomcat/dev/classes:ro</volume>
<volume>${beedk.deploy.platform.extDirectory}:/var/lib/tomcat/dev/lib:ro</volume>
@@ -354,6 +385,7 @@
<acs-platform.memory>1g</acs-platform.memory>
<alfresco.license.directory>${user.home}/alfresco/license</alfresco.license.directory>
<acs.license.directory>${alfresco.license.directory}/acs</acs.license.directory>
<java.cacerts.directory>src/test/cacerts</java.cacerts.directory>
<!-- ports -->
<acs-postgres.port>5432</acs-postgres.port>
@@ -362,9 +394,10 @@
<acs-platform-ha.port>8081</acs-platform-ha.port>
<!-- versions -->
<acs-postgres.version>12</acs-postgres.version>
<acs-activemq.version>5.18.4</acs-activemq.version>
<tomcat-rad.version>9-2.1</tomcat-rad.version>
<acs-postgres.version>15</acs-postgres.version>
<acs-activemq.version>6.1.8</acs-activemq.version>
<tomcat-rad.version>2.3-tomcat11</tomcat-rad.version>
<fs-plugin.version>1.0.0</fs-plugin.version>
</properties>
</profile>
</profiles>
@@ -12,11 +12,12 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>8</maven.compiler.source>
<maven.compiler.target>8</maven.compiler.target>
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
<maven.compiler.release>11</maven.compiler.release>
<alfresco.sdk.version>4.8.0</alfresco.sdk.version>
<alfresco.platform.version>7.4.2</alfresco.platform.version>
<alfresco.sdk.version>4.15.0</alfresco.sdk.version>
<alfresco.platform.version>26.1.0</alfresco.platform.version>
</properties>
<dependencyManagement>
@@ -46,7 +47,7 @@
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>2.40</version>
<version>2.45</version>
<extensions>true</extensions>
<configuration>
<tiles>
+4 -4
View File
@@ -59,10 +59,10 @@ Additional less important configurations are inherited from the following Maven
### Plugin Versions
| Maven Property |
| ---------------------------------- |
| `maven-resources-plugin.version` |
| `build-helper-plugin.version` |
| Maven Property |
| ----------------------------------- |
| `maven-resources-plugin.version` |
| `build-helper-maven-plugin.version` |
## Results
+3 -3
View File
@@ -23,7 +23,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>${build-helper-plugin.version}</version>
<version>${build-helper-maven-plugin.version}</version>
<executions>
<execution>
<id>add-acs-platform-module-resources</id>
@@ -82,8 +82,8 @@
<alfresco.ext.package>alfresco.extension</alfresco.ext.package>
<!-- versions -->
<build-helper-plugin.version>3.6.1</build-helper-plugin.version>
<maven-resources-plugin.version>3.4.0</maven-resources-plugin.version>
<build-helper-maven-plugin.version>@build-helper-maven-plugin.version@</build-helper-maven-plugin.version>
<maven-resources-plugin.version>@maven-resources-plugin.version@</maven-resources-plugin.version>
</properties>
</profile>
</profiles>
+2 -1
View File
@@ -60,7 +60,7 @@ The following properties are intended to be exposed by inheriting Public API Mav
| `acs-platform.timeout` | | 120000 | The time to wait for the startup to complete, in milliseconds. |
| `alfresco.license.directory` | | `${user.home}/alfresco/license` | The base path to search for Alfresco licenses. |
| `acs.license.directory` | | `${alfresco.license.directory}/acs` | The base path to search for an ACS license. |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-docker). |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-image). |
| `acs-postgres.version` | | *not important* | The version of PostgreSQL to use in the integration testing infrastructure. |
| `acs-activemq.version` | | *not important* | The version of Alfresco ActiveMQ to use in the integration testing infrastructure. |
| `acs-api-explorer.war.groupId` | | `org.alfresco` | The API Explorer WAR Maven Group ID. |
@@ -98,6 +98,7 @@ Additional less important configurations are inherited from the following Maven
| Maven Property |
| ---------------------------------- |
| `maven-dependency-plugin.version` |
| `fs-plugin.version` |
## Results
+41 -6
View File
@@ -27,6 +27,13 @@
</property>
</activation>
<build>
<testResources>
<testResource>
<directory>${java.cacerts.directory}</directory>
<filtering>false</filtering>
<targetPath>${project.build.directory}/cacerts</targetPath>
</testResource>
</testResources>
<plugins>
<!-- This plugin downloads ancillary WARs -->
<plugin>
@@ -69,6 +76,31 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.inteligr8</groupId>
<artifactId>fs-maven-plugin</artifactId>
<version>${fs-plugin.version}</version>
<executions>
<!-- creates missing directories used in volumes, which is required for podman -->
<execution>
<id>mkdirs-docker-volumes</id>
<phase>process-test-classes</phase>
<goals><goal>mkdir</goal></goals>
<configuration>
<paths>
<path>${beedk.deploy.platform.classesDirectory}</path>
<path>${beedk.deploy.platform.modClassesDirectory}</path>
<path>${beedk.deploy.platform.extClassesDirectory}</path>
<path>${beedk.deploy.platform.testClassesDirectory}</path>
<path>${beedk.deploy.platform.extDirectory}</path>
<path>${beedk.deploy.platform.webDirectory}</path>
<path>${beedk.deploy.platform.dataDirectory}</path>
<path>${project.build.directory}/cacerts</path>
</paths>
</configuration>
</execution>
</executions>
</plugin>
<!-- Using Docker to host the web application -->
<plugin>
<groupId>io.fabric8</groupId>
@@ -178,6 +210,7 @@
<volumes>
<bind>
<volume>${acs.license.directory}:/usr/local/tomcat/shared/classes/alfresco/extension/license:ro</volume>
<volume>${project.build.directory}/cacerts:/usr/local/share/ca-certificates:ro</volume>
<volume>${beedk.deploy.platform.warFile}:/var/lib/tomcat/webapps/alfresco.war:ro</volume>
<volume>${beedk.deploy.api-explorer.warFile}:/var/lib/tomcat/webapps/api-explorer.war:ro</volume>
<volume>${beedk.deploy.aos.warFile}:/var/lib/tomcat/webapps/_vti_bin.war:ro</volume>
@@ -296,6 +329,7 @@
<beedk.deploy.aos.warFile>${beedk.deploy.platform.warDirectory}/alfresco-vti-bin-${acs-aos.war.version}.war</beedk.deploy.aos.warFile>
<alfresco.license.directory>${user.home}/alfresco/license</alfresco.license.directory>
<acs.license.directory>${alfresco.license.directory}/acs</acs.license.directory>
<java.cacerts.directory>src/test/cacerts</java.cacerts.directory>
<!-- ports -->
<acs-postgres.port>5432</acs-postgres.port>
@@ -304,12 +338,13 @@
<acs-platform.debugger.port>8000</acs-platform.debugger.port>
<!-- versions -->
<acs-api-explorer.version>7.4.0</acs-api-explorer.version> <!-- TODO use and parse alfresco.platform.version -->
<acs-aos.war.version>1.3.2.1</acs-aos.war.version>
<acs-postgres.version>12</acs-postgres.version>
<acs-activemq.version>5.18.4</acs-activemq.version>
<tomcat-rad.version>9-2.1</tomcat-rad.version>
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<acs-api-explorer.version>26.1.0</acs-api-explorer.version> <!-- TODO use and parse alfresco.platform.version -->
<acs-aos.war.version>3.4.1</acs-aos.war.version>
<acs-postgres.version>15</acs-postgres.version>
<acs-activemq.version>6.1.8</acs-activemq.version>
<tomcat-rad.version>2.3-tomcat11</tomcat-rad.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
<fs-plugin.version>1.0.0</fs-plugin.version>
</properties>
</profile>
</profiles>
+1 -1
View File
@@ -100,7 +100,7 @@
<!-- versions -->
<postgres.jdbc.version>42.2.18</postgres.jdbc.version>
<alfresco.platform.war.version>${alfresco.platform.version}</alfresco.platform.war.version>
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
<!-- configuring beedk-acs-platform-it-tile -->
<beedk.deploy.platform.warFile>${project.build.warFile}</beedk.deploy.platform.warFile>
+1 -1
View File
@@ -104,7 +104,7 @@
<!-- versions -->
<postgres.jdbc.version>42.2.18</postgres.jdbc.version>
<alfresco.platform.war.version>${alfresco.platform.version}</alfresco.platform.war.version>
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
<!-- configuring beedk-acs-platform-rad-tile -->
<beedk.deploy.platform.warFile>${project.build.warFile}</beedk.deploy.platform.warFile>
@@ -32,7 +32,7 @@
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>${download-plugin.version}</version>
<version>${download-maven-plugin.version}</version>
<executions>
<!-- TODO eventually replace these with the archetype versions -->
<execution>
@@ -82,7 +82,7 @@
</activation>
<properties>
<!-- versions -->
<download-plugin.version>1.13.0</download-plugin.version>
<download-maven-plugin.version>@download-maven-plugin.version@</download-maven-plugin.version>
</properties>
</profile>
</profiles>
+2 -2
View File
@@ -99,8 +99,8 @@
<alfresco.war.version>${alfresco.platform.war.version}</alfresco.war.version>
<!-- versions -->
<maven-war-plugin.version>3.5.1</maven-war-plugin.version>
<maven-install-plugin.version>3.1.4</maven-install-plugin.version>
<maven-war-plugin.version>@maven-war-plugin.version@</maven-war-plugin.version>
<maven-install-plugin.version>@maven-install-plugin.version@</maven-install-plugin.version>
</properties>
</profile>
</profiles>
+1 -1
View File
@@ -74,7 +74,7 @@
<beedk.deploy.share.extDirectory>${project.build.directory}/ext/share</beedk.deploy.share.extDirectory>
<!-- versions -->
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
</properties>
</profile>
</profiles>
@@ -12,12 +12,13 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>8</maven.compiler.source>
<maven.compiler.target>8</maven.compiler.target>
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
<maven.compiler.release>11</maven.compiler.release>
<alfresco.sdk.version>4.8.0</alfresco.sdk.version>
<alfresco.platform.version>7.4.2</alfresco.platform.version>
<alfresco.share.version>22.17</alfresco.share.version>
<alfresco.sdk.version>4.15.0</alfresco.sdk.version>
<alfresco.platform.version>26.1.0</alfresco.platform.version>
<alfresco.share.version>26.1.0</alfresco.share.version>
</properties>
<dependencyManagement>
@@ -49,7 +50,7 @@
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>2.40</version>
<version>2.45</version>
<extensions>true</extensions>
<configuration>
<tiles>
+4 -4
View File
@@ -58,10 +58,10 @@ Additional less important configurations are inherited from the following Maven
### Plugin Versions
| Maven Property |
| ---------------------------------- |
| `maven-resources-plugin.version` |
| `build-helper-plugin.version` |
| Maven Property |
| ----------------------------------- |
| `maven-resources-plugin.version` |
| `build-helper-maven-plugin.version` |
## Results
+3 -3
View File
@@ -23,7 +23,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>${build-helper-plugin.version}</version>
<version>${build-helper-maven-plugin.version}</version>
<executions>
<execution>
<id>add-acs-share-module-resources</id>
@@ -101,8 +101,8 @@
<alfresco.ext.package>alfresco.web-extension</alfresco.ext.package>
<!-- versions -->
<build-helper-plugin.version>3.6.1</build-helper-plugin.version>
<maven-resources-plugin.version>3.4.0</maven-resources-plugin.version>
<build-helper-maven-plugin.version>@build-helper-maven-plugin.version@</build-helper-maven-plugin.version>
<maven-resources-plugin.version>@maven-resources-plugin.version@</maven-resources-plugin.version>
</properties>
</profile>
</profiles>
+3 -2
View File
@@ -56,7 +56,7 @@ The following properties are intended to be exposed by inheriting Public API Mav
| `acs-share.debugger.port` | | 8100 | The port to expose on `localhost` for the developer; not for other applications or users. |
| `acs-share.tomcat.opts` | | | Additional `CATALINA_OPTS` to add to the Apache Tomcat startup.<br/>*May be overridden by any POM parent or Maven Tile.* |
| `acs-share.timeout` | | 30000 | The time to wait for the startup to complete, in milliseconds. |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-docker). |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-image). |
### Private API
@@ -81,7 +81,8 @@ Additional less important configurations are inherited from the following Maven
| Maven Property |
| ---------------------------------- |
| `download-plugin.version` |
| `download-maven-plugin.version` |
| `fs-plugin.version` |
## Results
+28 -3
View File
@@ -32,7 +32,7 @@
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>${download-plugin.version}</version>
<version>${download-maven-plugin.version}</version>
<executions>
<execution>
<id>download-share-config</id>
@@ -73,6 +73,30 @@
</replacements>
</configuration>
</plugin>
<plugin>
<groupId>com.inteligr8</groupId>
<artifactId>fs-maven-plugin</artifactId>
<version>${fs-plugin.version}</version>
<executions>
<!-- creates missing directories used in volumes, which is required for podman -->
<execution>
<id>mkdirs-docker-volumes</id>
<phase>process-test-classes</phase>
<goals><goal>mkdir</goal></goals>
<configuration>
<paths>
<path>${beedk.deploy.share.classesDirectory}</path>
<path>${beedk.deploy.share.modClassesDirectory}</path>
<path>${beedk.deploy.share.extClassesDirectory}</path>
<path>${beedk.deploy.share.testClassesDirectory}</path>
<path>${project.build.directory}/runtime-classes</path>
<path>${beedk.deploy.share.extDirectory}</path>
<path>${beedk.deploy.share.webDirectory}</path>
</paths>
</configuration>
</execution>
</executions>
</plugin>
<!-- Using Docker to host the web application -->
<plugin>
<groupId>io.fabric8</groupId>
@@ -173,8 +197,9 @@
<acs-share.debugger.port>8100</acs-share.debugger.port>
<!-- versions -->
<tomcat-rad.version>9-2.1</tomcat-rad.version>
<download-plugin.version>1.13.0</download-plugin.version>
<tomcat-rad.version>2.3-tomcat11</tomcat-rad.version>
<download-maven-plugin.version>@download-maven-plugin.version@</download-maven-plugin.version>
<fs-plugin.version>1.0.0</fs-plugin.version>
<!-- configuring beedk-acs-webapp-artifact-tile -->
<alfresco.war.artifactId>share</alfresco.war.artifactId>
+2 -2
View File
@@ -55,7 +55,7 @@ The following properties are intended to be exposed by inheriting Public API Mav
| `acs-platform.url` | | *See Below* | The URL of the backend ACS Platform to be used. |
| `acs-share.port` | | 8180 | The port to expose on `localhost` for scripts to use during integration testing to verify the state of the application; not for a developer or user. |
| `acs-share.timeout` | | 45000 | The time to wait for the startup to complete, in milliseconds. |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-docker). |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-image). |
* The `alfresco.share.version` is used to default the `alfresco.war.version`. It is expected to be used by other Maven Tiles, so it is here for convenience. You must specify either property for this tile to function.
* The `acs-platform.url` will default to the appropriate value when using the `beedk-acs-platform-*-it-tile` tiles. This should be overridden if you are not using those tiles and are instead using some other ACS Platform instance.
@@ -72,7 +72,7 @@ Additional less important configurations are inherited from the following Maven
| Maven Property |
| ---------------------------------- |
| `maven-dependency-plugin.version` |
| `download-plugin.version` |
| `download-maven-plugin.version` |
## Results
+4 -4
View File
@@ -42,7 +42,7 @@
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>${download-plugin.version}</version>
<version>${download-maven-plugin.version}</version>
<executions>
<execution>
<id>download-share-config</id>
@@ -168,9 +168,9 @@
<acs-share.port>8180</acs-share.port>
<!-- versions -->
<tomcat-rad.version>9-2.1</tomcat-rad.version>
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<download-plugin.version>1.13.0</download-plugin.version>
<tomcat-rad.version>2.3-tomcat11</tomcat-rad.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
<download-maven-plugin.version>@download-maven-plugin.version@</download-maven-plugin.version>
<!-- configuring beedk-acs-webapp-artifact-tile -->
<alfresco.war.artifactId>share</alfresco.war.artifactId>
+1 -1
View File
@@ -71,7 +71,7 @@
<alfresco.war.version>${alfresco.share.version}</alfresco.war.version>
<!-- versions -->
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
</properties>
</profile>
</profiles>
+2 -2
View File
@@ -32,7 +32,7 @@
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>${download-plugin.version}</version>
<version>${download-maven-plugin.version}</version>
<executions>
<!-- TODO eventually replace these with the archetype versions -->
<execution>
@@ -82,7 +82,7 @@
</activation>
<properties>
<!-- versions -->
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
</properties>
</profile>
</profiles>
+2 -2
View File
@@ -69,8 +69,8 @@
<alfresco.war.version>${alfresco.share.version}</alfresco.war.version>
<!-- versions -->
<maven-war-plugin.version>3.5.1</maven-war-plugin.version>
<maven-install-plugin.version>3.1.4</maven-install-plugin.version>
<maven-war-plugin.version>@maven-war-plugin.version@</maven-war-plugin.version>
<maven-install-plugin.version>@maven-install-plugin.version@</maven-install-plugin.version>
</properties>
</profile>
</profiles>
@@ -74,7 +74,7 @@
<project.build.ampDirectory>${project.build.directory}/amps</project.build.ampDirectory>
<!-- versions -->
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
</properties>
</profile>
</profiles>
+1 -1
View File
@@ -78,7 +78,7 @@
<beedk.download.war.phase>pre-integration-test</beedk.download.war.phase>
<!-- versions -->
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
</properties>
</profile>
</profiles>
+1 -1
View File
@@ -86,7 +86,7 @@
<project.build.ampDirectory>${project.build.directory}/amps</project.build.ampDirectory>
<!-- versions -->
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
</properties>
</profile>
</profiles>
+1 -1
View File
@@ -68,7 +68,7 @@
<project.build.warFile>${project.build.warDirectory}/${alfresco.war.artifactId}-${alfresco.war.version}.war</project.build.warFile>
<!-- versions -->
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
</properties>
</profile>
</profiles>
+3 -3
View File
@@ -25,7 +25,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>${build-helper-plugin.version}</version>
<version>${build-helper-maven-plugin.version}</version>
<executions>
<execution>
<id>copy-and-filter-docker-resources</id>
@@ -117,8 +117,8 @@
<maven.deploy.skip>${beedk.deploy.dockerImageOnly}</maven.deploy.skip>
<!-- versions -->
<build-helper-plugin.version>3.6.1</build-helper-plugin.version>
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<build-helper-maven-plugin.version>@build-helper-maven-plugin.version@</build-helper-maven-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
</properties>
</profile>
</profiles>
@@ -6,15 +6,6 @@
<requiredProperty key="shortname">
<validationRegex>[A-Za-z0-9]+</validationRegex>
</requiredProperty>
<requiredProperty key="dockerRegistryHost">
<defaultValue>quay.io</defaultValue>
</requiredProperty>
<requiredProperty key="dockerImagePrefix">
<defaultValue>local</defaultValue>
</requiredProperty>
<requiredProperty key="beedkVersion">
<defaultValue>[1.0.0,2.0.0)</defaultValue>
</requiredProperty>
</requiredProperties>
<fileSets>
<fileSet filtered="true" packaged="true">
@@ -1,5 +1,5 @@
# Maven
/target
target/
pom.xml.versionsBackup
# Eclipse
@@ -12,26 +12,43 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>8</maven.compiler.source>
<maven.compiler.target>8</maven.compiler.target>
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
<maven.compiler.release>11</maven.compiler.release>
<activiti.version>7.11.0</activiti.version>
<spring.version>5.3.29</spring.version>
<!-- This extension will work with all versions of Activiti, as long as the integration point method signatures remain the same. -->
<!-- These versions were the latest at the time this archetype was last updated. -->
<activiti.version>8.8.0</activiti.version>
<spring.version>6.2.14</spring.version>
<!-- The following are only used for RAD and integration testing -->
<!--
<tomcat-rad.version>2.3-tomcat11</tomcat-rad.version>
<aps.war.version>26.1.0</aps.war.version>
<aps.tomcat.opts>-Dproperty-to-set=value</aps.tomcat.opts>
-->
</properties>
<dependencies>
<dependency>
<groupId>org.activiti</groupId>
<artifactId>activiti-engine</artifactId>
<version>${activiti.version}</version>
<scope>provided</scope>
</dependency>
<!-- Activiti provided libraries -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-context</artifactId>
<version>${spring.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.activiti</groupId>
<artifactId>activiti-engine</artifactId>
<version>${activiti.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>jakarta.annotation</groupId>
<artifactId>jakarta.annotation-api</artifactId>
<version>3.0.0</version>
<scope>provided</scope>
</dependency>
</dependencies>
<build>
@@ -39,38 +56,39 @@
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>2.40</version>
<version>2.45</version>
<extensions>true</extensions>
<configuration>
<tiles>
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-aps-ext-rad-tile -->
<tile>com.inteligr8.ootbee:beedk-aps-ext-rad-tile:1.1-SNAPSHOT</tile>
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-activiti-ext-tile -->
<tile>com.inteligr8.ootbee:beedk-activiti-ext-tile:${beedkVersion}</tile>
</tiles>
</configuration>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>rad</id>
<id>wsl</id>
<activation>
<property>
<name>rad</name>
</property>
<os>
<family>windows</family>
</os>
</activation>
<properties>
<aps.version>2.4.6</aps.version>
<!-- add properties here -->
<aps.tomcat.opts>-Dproperty-to-set=value</aps.tomcat.opts>
<!-- Using WSL is slower than native containers -->
<!-- Adjust this timeout for slow computers, VPN, or other slow or high latency scenarios -->
<aps.timeout>120000</aps.timeout>
</properties>
</profile>
</profiles>
<repositories>
<repository>
<id>alfresco-public</id>
<url>https://artifacts.alfresco.com/nexus/content/groups/public</url>
</repository>
<!-- Used by the Activiti dependencies -->
<repository>
<id>activiti-public-releases</id>
<url>https://artifacts.alfresco.com/nexus/repository/activiti-releases</url>
</repository>
</repositories>
</project>
@@ -1,69 +1,71 @@
$script:MAVEN_CMD="mvn"
$script:CONTAINERD_CMD="docker"
function discoverArtifactId {
$script:ARTIFACT_ID=(mvn -q -Dexpression=project"."artifactId -DforceStdout help:evaluate)
$script:ARTIFACT_ID=(Invoke-Expression "${MAVEN_CMD} -q -Dexpression=project"."artifactId -DforceStdout help:evaluate")
}
function rebuild {
echo "Rebuilding project ..."
mvn process-test-classes
Invoke-Expression "${MAVEN_CMD} process-test-classes"
}
function start_ {
echo "Rebuilding project and starting Docker containers to support rapid application development ..."
mvn -Drad process-test-classes
function start_containers {
echo "Rebuilding project and starting containers to support rapid application development ..."
Invoke-Expression "${MAVEN_CMD} -Drad process-test-classes"
}
function start_log {
echo "Rebuilding project and starting Docker containers to support rapid application development ..."
mvn -Drad "-Ddocker.showLogs" process-test-classes
function start_containers_verbose {
echo "Rebuilding project and starting containers to support rapid application development ..."
Invoke-Expression "${MAVEN_CMD} -Drad -Ddocker'.'showLogs process-test-classes"
}
function stop_ {
function stop_containers {
discoverArtifactId
echo "Stopping Docker containers that supported rapid application development ..."
docker container ls --filter name="^/${ARTIFACT_ID}"
Invoke-Expression "${CONTAINERD_CMD} container ls --filter name=${ARTIFACT_ID}-*"
echo "Stopping containers ..."
docker container stop (docker container ls -q --filter name="^/${ARTIFACT_ID}")
Invoke-Expression "${CONTAINERD_CMD} container stop (Invoke-Expression '${CONTAINERD_CMD} container ls -q --filter name=${ARTIFACT_ID}-*')"
echo "Removing containers ..."
docker container rm (docker container ls -aq --filter name="^/${ARTIFACT_ID}")
Invoke-Expression "${CONTAINERD_CMD} container rm (Invoke-Expression '${CONTAINERD_CMD} container ls -aq --filter name=${ARTIFACT_ID}-*')"
}
function tail_logs {
function tail_container {
param (
$container
)
discoverArtifactId
docker container logs -f (docker container ls -q --filter name="^/${ARTIFACT_ID}-${container}$")
Invoke-Expression "${CONTAINERD_CMD} container logs -f (Invoke-Expression '${CONTAINERD_CMD} container ls -q --filter name=${ARTIFACT_ID}-${container}')"
}
function list {
function list_containers {
discoverArtifactId
docker container ls --filter name="^/${ARTIFACT_ID}"
Invoke-Expression "${CONTAINERD_CMD} container ls --filter name=${ARTIFACT_ID}-*"
}
switch ($args[0]) {
"start" {
start_
start_containers
}
"start_log" {
start_log
start_containers_verbose
}
"stop" {
stop_
stop_containers
}
"restart" {
stop_
start_
stop_containers
start_containers
}
"rebuild" {
rebuild
}
"tail" {
tail_logs $args[1]
tail_container $args[1]
}
"containers" {
list
list_containers
}
default {
echo "Usage: .\rad.ps1 [ start | start_log | stop | restart | rebuild | tail {container} | containers ]"
@@ -1,66 +1,69 @@
#!/bin/sh
MAVEN_CMD=mvn
CONTAINERD_CMD=docker
discoverArtifactId() {
local ARTIFACT_ID=`mvn -q -Dexpression=project.artifactId -DforceStdout help:evaluate`
local ARTIFACT_ID=`${MAVEN_CMD} -q -Dexpression=project.artifactId -DforceStdout help:evaluate`
}
rebuild() {
echo "Rebuilding project ..."
mvn process-test-classes
${MAVEN_CMD} process-test-classes
}
start() {
echo "Rebuilding project and starting Docker containers to support rapid application development ..."
mvn -Drad process-test-classes
start_containers() {
echo "Rebuilding project and starting containers to support rapid application development ..."
${MAVEN_CMD} -Drad process-test-classes
}
start_log() {
echo "Rebuilding project and starting Docker containers to support rapid application development ..."
mvn -Drad -Ddocker.showLogs process-test-classes
start_containers_verbose() {
echo "Rebuilding project and starting containers to support rapid application development ..."
${MAVEN_CMD} -Drad -Ddocker.showLogs process-test-classes
}
stop() {
stop_containers() {
discoverArtifactId
echo "Stopping Docker containers that supported rapid application development ..."
docker container ls --filter name="^/${ARTIFACT_ID}"
${CONTAINERD_CMD} container ls --filter name=${ARTIFACT_ID}-*
echo "Stopping containers ..."
docker container stop `docker container ls -q --filter name="^/${ARTIFACT_ID}"`
${CONTAINERD_CMD} container stop `${CONTAINERD_CMD} container ls -q --filter name=${ARTIFACT_ID}-*`
echo "Removing containers ..."
docker container rm `docker container ls -aq --filter name="^/${ARTIFACT_ID}"`
${CONTAINERD_CMD} container rm `${CONTAINERD_CMD} container ls -aq --filter name=${ARTIFACT_ID}-*`
}
tail_logs() {
tail_container() {
discoverArtifactId
docker container logs -f `docker container ls -q --filter name="^/${ARTIFACT_ID}-$1$"`
${CONTAINERD_CMD} container logs -f `${CONTAINERD_CMD} container ls -q --filter name=${ARTIFACT_ID}-$1`
}
list() {
list_containers() {
discoverArtifactId
docker container ls --filter name="^/${ARTIFACT_ID}"
${CONTAINERD_CMD} container ls --filter name=${ARTIFACT_ID}-*
}
case "$1" in
start)
start
start_containers
;;
start_log)
start_log
start_containers_verbose
;;
stop)
stop
stop_containers
;;
restart)
stop
start
stop_containers
start_containers
;;
rebuild)
rebuild
;;
tail)
tail_logs $2
tail_container $2
;;
containers)
list
list_containers
;;
*)
echo "Usage: ./rad.sh [ start | start_log | stop | restart | rebuild | tail {container} | containers ]"
@@ -0,0 +1,38 @@
/*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <https://www.gnu.org/licenses/>.
*/
package ${package};
import org.activiti.engine.delegate.event.ActivitiEvent;
import org.activiti.engine.delegate.event.ActivitiEventListener;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;
/**
* This class is an example of how you can implement an Activiti Event Listener.
*/
@Component
public class ExampleEventListener implements ActivitiEventListener {
private static final Logger LOGGER = LoggerFactory.getLogger(ExampleEventListener.class);
@Override
public void onEvent(ActivitiEvent event) {
LOGGER.trace("onEvent({})", event.getType());
// TODO do some stuff
}
}
@@ -24,21 +24,21 @@ import org.springframework.stereotype.Component;
* This class is an example of how you can implement an Activiti Execution Listener.
* You can reference it in your BPMN with:
* <activiti:executionListener delegateExpression="${exampleExecutionListener}" event="start" />
* <activiti:executionListener expression="${exampleExecutionListener.exampleMethod('example parameter')}" event="end" />
* <activiti:executionListener expression="${exampleExecutionListener.exampleMethod(execution, 'example parameter')}" event="end" />
*/
@Component("exampleExecutionListener")
public class ExampleExecutionListener implements ExecutionListener {
private final Logger logger = LoggerFactory.getLogger(this.getClass());
public void notify(DelegateExecution execution) throws Exception {
if (this.logger.isTraceEnabled())
this.logger.trace("execute('" + execution.getId() + "')");
private static final Logger LOGGER = LoggerFactory.getLogger(ExampleExecutionListener.class);
@Override
public void notify(DelegateExecution execution) {
LOGGER.trace("execute({})", execution.getId());
// TODO do some stuff
}
public void exampleMethod(String param) throws Exception {
public void exampleMethod(DelegateExecution execution, String param) {
// another example
}
@@ -0,0 +1,41 @@
/*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <https://www.gnu.org/licenses/>.
*/
package ${package};
import org.activiti.engine.delegate.DelegateExecution;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;
/**
* This class is an example of how you can implement an Activiti script object.
* A scripting object can be used in any expression or Script Task.
*
* You can reference it in your BPMN expression with:
* ${exampleObject.exampleMethod('example parameter')}
*
* You can reference it in your Script Task with:
* exampleObject.exampleMethod('example parameter');
*/
@Component("exampleObject")
public class ExampleServiceTask {
private static final Logger LOGGER = LoggerFactory.getLogger(this.getClass());
public void exampleMethod(String param) throws Exception {
// another example
}
}
@@ -24,21 +24,21 @@ import org.springframework.stereotype.Component;
* This class is an example of how you can implement an Activiti Service Task.
* You can reference it in your BPMN with:
* <serviceTask id="serviceTask" activiti:delegateExpression="${exampleServiceTask}" />
* <serviceTask id="serviceTask" activiti:expression="${exampleServiceTask.exampleMethod('example parameter')}" />
* <serviceTask id="serviceTask" activiti:expression="${exampleServiceTask.exampleMethod(execution, 'example parameter')}" />
*/
@Component("exampleServiceTask")
public class ExampleServiceTask implements JavaDelegate {
private final Logger logger = LoggerFactory.getLogger(this.getClass());
private static final Logger LOGGER = LoggerFactory.getLogger(ExampleServiceTask.class);
@Override
public void execute(DelegateExecution execution) throws Exception {
if (this.logger.isTraceEnabled())
this.logger.trace("execute('" + execution.getId() + "')");
LOGGER.trace("execute({})", execution.getId());
// TODO do some stuff
}
public void exampleMethod(String param) throws Exception {
public void exampleMethod(DelegateExecution execution, String param) throws Exception {
// another example
}
@@ -0,0 +1,45 @@
/*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <https://www.gnu.org/licenses/>.
*/
package ${package};
import org.activiti.engine.delegate.DelegateTask;
import org.activiti.engine.delegate.TaskListener;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;
/**
* This class is an example of how you can implement an Activiti Task Listener.
* You can reference it in your BPMN with:
* <activiti:taskListener delegateExpression="${exampleTaskListener}" event="start" />
* <activiti:taskListener expression="${exampleTaskListener.exampleMethod(task, 'example parameter')}" event="end" />
*/
@Component("exampleTaskListener")
public class ExampleTaskListener implements TaskListener {
private static final Logger LOGGER = LoggerFactory.getLogger(ExampleTaskListener.class);
@Override
public void notify(DelegateTask task) {
LOGGER.trace("execute({})", task.getId());
// TODO do some stuff
}
public void exampleMethod(DelegateTask task, String param) {
// another example
}
}
@@ -16,9 +16,18 @@ package com.activiti.extension.conf;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.FullyQualifiedAnnotationBeanNameGenerator;
/**
* A means for injecting packages to scan for the Spring context.
*/
@Configuration
@ComponentScan(basePackages = {"${package}"})
@ComponentScan(
basePackages = {
"${package}"
},
nameGenerator = FullyQualifiedAnnotationBeanNameGenerator.class
)
public class ${shortname}SpringComponentScanner {
}
@@ -1,9 +1,9 @@
# Maven
/target
pom.xml.versionsBackup
# Eclipse
.settings
.project
.classpath
.settings
# Maven
pom.xml.versionsBackup
target
+62
View File
@@ -0,0 +1,62 @@
# BeeDK Activiti Extension Maven Tile
This is a component within the proposed [BeeDK](/inteligr8/ootbee-beedk). It is considered to be part of the **Public API** of the BeeDK.
## Purpose
This project creates a [Maven Tile](https://github.com/repaint-io/maven-tiles) that assists with the building of any Activiti extension.
## Usage
To use this plugin, just reference it with the Maven Tiles plugin as shown in the following snippet. Do not forget the `extensions` element in the *plugin* configuration.
```xml
<project ...>
...
<build>
...
<plugins>
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>[2.0,3.0)</version>
<extensions>true</extensions>
<configuration>
<tiles>
...
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-activiti-ext-tile -->
<tile>com.inteligr8.ootbee:beedk-activiti-ext-tile:[1.0.0,2.0.0)</tile>
</tiles>
</configuration>
</plugin>
...
</plugins>
...
</build>
...
</project>
```
## Configuration
In your Maven project, set the following properties to define the behavior of this Maven Tile. Unless otherwise stated, they can only be overridden in the project POM or other Maven Tiles loaded earlier than this Maven Tile.
### Public API
The following properties are intended to be exposed by inheriting Public API Maven Tiles.
| Maven Property | Required | Default | Description |
| ---------------------------- |:--------:| --------------- | ----------- |
| `activiti.shaded.classifier` | | `bundle` | |
| `activiti.apidoc.name` | | *project name* | |
| `activiti.apidoc.title` | | Activiti API Documentation | |
### Plugin Versions
| Maven Property |
| ---------------------------------- |
| `activiti-api-doclet.version` |
| `maven-clean-plugin.version` |
| `maven-javadoc-plugin.version` |
| `maven-shade-plugin.version` |
| `flatten-maven-plugin.version` |
@@ -4,8 +4,8 @@
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>beedk-springboot-api-archetype</artifactId>
<packaging>maven-archetype</packaging>
<artifactId>beedk-activiti-ext-tile</artifactId>
<packaging>tile</packaging>
<parent>
<groupId>com.inteligr8.ootbee</groupId>
@@ -14,7 +14,7 @@
<relativePath>..</relativePath>
</parent>
<name>Order of the Bee Development Kit: Project Scaffolding for a Spring Boot application using ACS/API remote APIs</name>
<name>Order of the Bee Development Kit: Activiti Extension</name>
<url>https://git.inteligr8.com/inteligr8/ootbee-beedk</url>
<licenses>
@@ -45,12 +45,11 @@
</developers>
<build>
<extensions>
<extension>
<groupId>org.apache.maven.archetype</groupId>
<artifactId>archetype-packaging</artifactId>
<version>${archetype-packaging.version}</version>
</extension>
</extensions>
<plugins>
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
</project>
+140
View File
@@ -0,0 +1,140 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <https://www.gnu.org/licenses/>.
*
-->
<project xmlns="http://tiles.bluetrainsoftware.com/maven/tiles/1.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://tiles.bluetrainsoftware.com/maven/tiles/1.1.0 https://git.inteligr8.com/inteligr8/maven-tiles/raw/xsd/src/main/resources/maven-tiles.xsd">
<profiles>
<profile>
<id>default-props</id>
<activation>
<property>
<name>!some-prop-that-never-exists</name>
</property>
</activation>
<properties>
<!-- functional -->
<activiti.shaded.classifier>bundle</activiti.shaded.classifier>
<activiti.apidoc.name>@project.name@</activiti.apidoc.name>
<activiti.apidoc.title>Activiti API Documentation</activiti.apidoc.title>
<!-- versioning -->
<activiti-api-doclet.version>1.1.1</activiti-api-doclet.version>
<maven-clean-plugin.version>@maven-clean-plugin.version@</maven-clean-plugin.version>
<maven-javadoc-plugin.version>@maven-javadoc-plugin.version@</maven-javadoc-plugin.version>
<maven-shade-plugin.version>@maven-shade-plugin.version@</maven-shade-plugin.version>
<flatten-maven-plugin.version>@flatten-maven-plugin.version@</flatten-maven-plugin.version>
</properties>
</profile>
<profile>
<id>apidoc</id>
<build>
<plugins>
<plugin>
<artifactId>maven-clean-plugin</artifactId>
<version>${maven-clean-plugin.version}</version>
<configuration>
<filesets>
<fileset>
<directory>${basedir}/apidocs</directory>
</fileset>
</filesets>
</configuration>
</plugin>
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
<version>${maven-javadoc-plugin.version}</version>
<executions>
<execution>
<id>generate-doclet</id>
<phase>generate-resources</phase>
<goals>
<goal>javadoc</goal>
</goals>
<configuration>
<sourceFileIncludes>**/*.java</sourceFileIncludes>
<doclet>com.inteligr8.activiti.doclet.ActivitiDoclet</doclet>
<docletArtifact>
<groupId>com.inteligr8.activiti</groupId>
<artifactId>activiti-api-doclet</artifactId>
<version>${activiti-api-doclet.version}</version>
</docletArtifact>
<useStandardDocletOptions>false</useStandardDocletOptions>
<outputDirectory>${basedir}</outputDirectory>
<additionalOptions>
<additionalOption>--apiName '${activiti.apidoc.name}'</additionalOption>
<additionalOption>--title '${activiti.apidoc.title}'</additionalOption>
</additionalOptions>
<!-- this is required in JDKs before v23 -->
<disableNoFonts>true</disableNoFonts>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>bundle</id>
<build>
<plugins>
<!-- This allows other depending projects to not bundle duplicate libraries -->
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>flatten-maven-plugin</artifactId>
<version>${flatten-maven-plugin.version}</version>
<executions>
<execution>
<id>flatten-pom</id>
<phase>process-resources</phase>
</execution>
</executions>
</plugin>
<!-- this is the bundling -->
<plugin>
<artifactId>maven-shade-plugin</artifactId>
<version>${maven-shade-plugin.version}</version>
<executions>
<execution>
<id>shade-deps</id>
<phase>package</phase>
<goals><goal>shade</goal></goals>
<configuration>
<shadedArtifactAttached>true</shadedArtifactAttached>
<shadedClassifierName>${activiti.shaded.classifier}</shadedClassifierName>
<!-- This allows other depending projects to not bundle duplicate libraries -->
<createDependencyReducedPom>false</createDependencyReducedPom>
<transformers>
<transformer implementation="org.apache.maven.plugins.shade.resource.ApacheLicenseResourceTransformer" />
<transformer implementation="org.apache.maven.plugins.shade.resource.ApacheNoticeResourceTransformer">
<addHeader>false</addHeader>
</transformer>
<transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer" />
</transformers>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
</profiles>
</project>
+1 -1
View File
@@ -61,4 +61,4 @@ This tile will result in the definition of the following Maven properties during
| Maven Property |
| ---------------------------------- |
| `maven-dependency-plugin.version` |
| `regex-plugin.version` |
| `regex-maven-plugin.version` |
+3 -3
View File
@@ -71,7 +71,7 @@
<plugin>
<groupId>com.inteligr8</groupId>
<artifactId>regex-maven-plugin</artifactId>
<version>${regex-plugin.version}</version>
<version>${regex-maven-plugin.version}</version>
<executions>
<execution>
<id>string-2-boolean-1</id>
@@ -140,8 +140,8 @@
</activation>
<properties>
<!-- versions -->
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<regex-plugin.version>1.0.7</regex-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
<regex-maven-plugin.version>@regex-maven-plugin.version@</regex-maven-plugin.version>
</properties>
</profile>
</profiles>
@@ -6,15 +6,6 @@
<requiredProperty key="shortname">
<validationRegex>[A-Za-z0-9]+</validationRegex>
</requiredProperty>
<requiredProperty key="dockerRegistryHost">
<defaultValue>quay.io</defaultValue>
</requiredProperty>
<requiredProperty key="dockerImagePrefix">
<defaultValue>local</defaultValue>
</requiredProperty>
<requiredProperty key="beedkVersion">
<defaultValue>[1.0.0,2.0.0)</defaultValue>
</requiredProperty>
</requiredProperties>
<fileSets>
<fileSet filtered="true" packaged="true">
@@ -1,5 +1,5 @@
# Maven
/target
target/
pom.xml.versionsBackup
# Eclipse
@@ -16,7 +16,21 @@
<maven.compiler.target>11</maven.compiler.target>
<maven.compiler.release>11</maven.compiler.release>
<aps.version>2.4.6</aps.version>
<!-- This extension will work with all versions of APS, as long as the integration point method signatures remain the same. -->
<aps.version>26.1.0</aps.version>
<!-- The following are only used for RAD and integration testing -->
<!--
See the following for options:
- https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-aps-ext-rad-tile
- https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-aps-ext-it-tile
-->
<!--
<tomcat-rad.version>2.3-tomcat11</tomcat-rad.version>
<aps.war.version>26.1.0</aps.war.version>
<aps.tomcat.opts>-Dproperty-to-set=value</aps.tomcat.opts>
-->
</properties>
<dependencies>
@@ -27,6 +41,7 @@
<classifier>classes</classifier>
<scope>provided</scope>
<exclusions>
<!-- these are in another repository and typically unnecessary -->
<exclusion>
<groupId>com.activiti</groupId>
<artifactId>aspose-transformation</artifactId>
@@ -44,40 +59,43 @@
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>2.40</version>
<version>2.45</version>
<extensions>true</extensions>
<configuration>
<tiles>
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-aps-ext-rad-tile -->
<tile>com.inteligr8.ootbee:beedk-aps-ext-rad-tile:1.1-SNAPSHOT</tile>
<tile>com.inteligr8.ootbee:beedk-aps-ext-rad-tile:${beedkVersion}</tile>
</tiles>
</configuration>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>rad</id>
<id>wsl</id>
<activation>
<property>
<name>rad</name>
</property>
<os>
<family>windows</family>
</os>
</activation>
<properties>
<!-- add properties here -->
<aps.tomcat.opts>-Dproperty-to-set=value</aps.tomcat.opts>
<!-- Using WSL is slower than native containers -->
<!-- Adjust this timeout for slow computers, VPN, or other slow or high latency scenarios -->
<aps.timeout>120000</aps.timeout>
</properties>
</profile>
</profiles>
<repositories>
<repository>
<id>alfresco-public</id>
<url>https://artifacts.alfresco.com/nexus/content/groups/public</url>
</repository>
<!-- Used by the Activiti dependencies -->
<repository>
<id>activiti-releases</id>
<id>activiti-public-releases</id>
<url>https://artifacts.alfresco.com/nexus/repository/activiti-releases</url>
</repository>
<!-- Used when performing optional RAD and integration testing -->
<repository>
<id>activiti-enterprise-releases</id>
<url>https://artifacts.alfresco.com/nexus/content/repositories/activiti-enterprise-releases</url>
</repository>
</repositories>
@@ -1,69 +1,71 @@
$script:MAVEN_CMD="mvn"
$script:CONTAINERD_CMD="docker"
function discoverArtifactId {
$script:ARTIFACT_ID=(mvn -q -Dexpression=project"."artifactId -DforceStdout help:evaluate)
$script:ARTIFACT_ID=(Invoke-Expression "${MAVEN_CMD} -q -Dexpression=project"."artifactId -DforceStdout help:evaluate")
}
function rebuild {
echo "Rebuilding project ..."
mvn process-test-classes
Invoke-Expression "${MAVEN_CMD} process-test-classes"
}
function start_ {
echo "Rebuilding project and starting Docker containers to support rapid application development ..."
mvn -Drad process-test-classes
function start_containers {
echo "Rebuilding project and starting containers to support rapid application development ..."
Invoke-Expression "${MAVEN_CMD} -Drad process-test-classes"
}
function start_log {
echo "Rebuilding project and starting Docker containers to support rapid application development ..."
mvn -Drad "-Ddocker.showLogs" process-test-classes
function start_containers_verbose {
echo "Rebuilding project and starting containers to support rapid application development ..."
Invoke-Expression "${MAVEN_CMD} -Drad -Ddocker'.'showLogs process-test-classes"
}
function stop_ {
function stop_containers {
discoverArtifactId
echo "Stopping Docker containers that supported rapid application development ..."
docker container ls --filter name="^/${ARTIFACT_ID}"
Invoke-Expression "${CONTAINERD_CMD} container ls --filter name=${ARTIFACT_ID}-*"
echo "Stopping containers ..."
docker container stop (docker container ls -q --filter name="^/${ARTIFACT_ID}")
Invoke-Expression "${CONTAINERD_CMD} container stop (Invoke-Expression '${CONTAINERD_CMD} container ls -q --filter name=${ARTIFACT_ID}-*')"
echo "Removing containers ..."
docker container rm (docker container ls -aq --filter name="^/${ARTIFACT_ID}")
Invoke-Expression "${CONTAINERD_CMD} container rm (Invoke-Expression '${CONTAINERD_CMD} container ls -aq --filter name=${ARTIFACT_ID}-*')"
}
function tail_logs {
function tail_container {
param (
$container
)
discoverArtifactId
docker container logs -f (docker container ls -q --filter name="^/${ARTIFACT_ID}-${container}$")
Invoke-Expression "${CONTAINERD_CMD} container logs -f (Invoke-Expression '${CONTAINERD_CMD} container ls -q --filter name=${ARTIFACT_ID}-${container}')"
}
function list {
function list_containers {
discoverArtifactId
docker container ls --filter name="^/${ARTIFACT_ID}"
Invoke-Expression "${CONTAINERD_CMD} container ls --filter name=${ARTIFACT_ID}-*"
}
switch ($args[0]) {
"start" {
start_
start_containers
}
"start_log" {
start_log
start_containers_verbose
}
"stop" {
stop_
stop_containers
}
"restart" {
stop_
start_
stop_containers
start_containers
}
"rebuild" {
rebuild
}
"tail" {
tail_logs $args[1]
tail_container $args[1]
}
"containers" {
list
list_containers
}
default {
echo "Usage: .\rad.ps1 [ start | start_log | stop | restart | rebuild | tail {container} | containers ]"
@@ -1,66 +1,69 @@
#!/bin/sh
MAVEN_CMD=mvn
CONTAINERD_CMD=docker
discoverArtifactId() {
local ARTIFACT_ID=`mvn -q -Dexpression=project.artifactId -DforceStdout help:evaluate`
local ARTIFACT_ID=`${MAVEN_CMD} -q -Dexpression=project.artifactId -DforceStdout help:evaluate`
}
rebuild() {
echo "Rebuilding project ..."
mvn process-test-classes
${MAVEN_CMD} process-test-classes
}
start() {
echo "Rebuilding project and starting Docker containers to support rapid application development ..."
mvn -Drad process-test-classes
start_containers() {
echo "Rebuilding project and starting containers to support rapid application development ..."
${MAVEN_CMD} -Drad process-test-classes
}
start_log() {
echo "Rebuilding project and starting Docker containers to support rapid application development ..."
mvn -Drad -Ddocker.showLogs process-test-classes
start_containers_verbose() {
echo "Rebuilding project and starting containers to support rapid application development ..."
${MAVEN_CMD} -Drad -Ddocker.showLogs process-test-classes
}
stop() {
stop_containers() {
discoverArtifactId
echo "Stopping Docker containers that supported rapid application development ..."
docker container ls --filter name="^/${ARTIFACT_ID}"
${CONTAINERD_CMD} container ls --filter name=${ARTIFACT_ID}-*
echo "Stopping containers ..."
docker container stop `docker container ls -q --filter name="^/${ARTIFACT_ID}"`
${CONTAINERD_CMD} container stop `${CONTAINERD_CMD} container ls -q --filter name=${ARTIFACT_ID}-*`
echo "Removing containers ..."
docker container rm `docker container ls -aq --filter name="^/${ARTIFACT_ID}"`
${CONTAINERD_CMD} container rm `${CONTAINERD_CMD} container ls -aq --filter name=${ARTIFACT_ID}-*`
}
tail_logs() {
tail_container() {
discoverArtifactId
docker container logs -f `docker container ls -q --filter name="^/${ARTIFACT_ID}-$1$"`
${CONTAINERD_CMD} container logs -f `${CONTAINERD_CMD} container ls -q --filter name=${ARTIFACT_ID}-$1`
}
list() {
list_containers() {
discoverArtifactId
docker container ls --filter name="^/${ARTIFACT_ID}"
${CONTAINERD_CMD} container ls --filter name=${ARTIFACT_ID}-*
}
case "$1" in
start)
start
start_containers
;;
start_log)
start_log
start_containers_verbose
;;
stop)
stop
stop_containers
;;
restart)
stop
start
stop_containers
start_containers
;;
rebuild)
rebuild
;;
tail)
tail_logs $2
tail_container $2
;;
containers)
list
list_containers
;;
*)
echo "Usage: ./rad.sh [ start | start_log | stop | restart | rebuild | tail {container} | containers ]"
@@ -1,5 +1,8 @@
package ${package};
/**
* An interface to bootstrap APS resources.
*/
public interface Bootstrappable {
void onBootstrap();
@@ -10,10 +10,16 @@ import org.springframework.stereotype.Component;
import com.activiti.api.boot.BootstrapConfigurer;
/**
* This service is an example. The functionality provided by this example
* service is implemented in the `multiext-activiti-app-ext` extension.
*
* @link https://git.inteligr8.com/inteligr8/multiext-activiti-app-ext
*/
@Component
public class BootstrappingService implements BootstrapConfigurer {
private final Logger logger = LoggerFactory.getLogger(this.getClass());
private static final Logger LOGGER = LoggerFactory.getLogger(BootstrappingService.class);
@Autowired(required = false)
private List<Bootstrappable> bootstrappables;
@@ -22,7 +28,7 @@ public class BootstrappingService implements BootstrapConfigurer {
public void applicationContextInitialized(ApplicationContext applicationContext) {
if (this.bootstrappables != null) {
for (Bootstrappable bootstrappable : this.bootstrappables) {
this.logger.debug("Bootstrapping: " + bootstrappable.getClass());
LOGGER.debug("Bootstrapping: " + bootstrappable.getClass());
bootstrappable.onBootstrap();
}
}
@@ -0,0 +1,38 @@
/*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <https://www.gnu.org/licenses/>.
*/
package ${package};
import org.activiti.engine.delegate.event.ActivitiEvent;
import org.activiti.engine.delegate.event.ActivitiEventListener;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;
/**
* This class is an example of how you can implement an Activiti Event Listener.
*/
@Component
public class ExampleEventListener implements ActivitiEventListener {
private static final Logger LOGGER = LoggerFactory.getLogger(ExampleEventListener.class);
@Override
public void onEvent(ActivitiEvent event) {
LOGGER.trace("onEvent({})", event.getType());
// TODO do some stuff
}
}
@@ -24,21 +24,21 @@ import org.springframework.stereotype.Component;
* This class is an example of how you can implement an Activiti Execution Listener.
* You can reference it in your BPMN with:
* <activiti:executionListener delegateExpression="${exampleExecutionListener}" event="start" />
* <activiti:executionListener expression="${exampleExecutionListener.exampleMethod('example parameter')}" event="end" />
* <activiti:executionListener expression="${exampleExecutionListener.exampleMethod(execution, 'example parameter')}" event="end" />
*/
@Component("exampleExecutionListener")
public class ExampleExecutionListener implements ExecutionListener {
private final Logger logger = LoggerFactory.getLogger(this.getClass());
public void notify(DelegateExecution execution) throws Exception {
if (this.logger.isTraceEnabled())
this.logger.trace("execute('" + execution.getId() + "')");
private static final Logger LOGGER = LoggerFactory.getLogger(ExampleExecutionListener.class);
@Override
public void notify(DelegateExecution execution) {
LOGGER.trace("execute({})", execution.getId());
// TODO do some stuff
}
public void exampleMethod(String param) throws Exception {
public void exampleMethod(DelegateExecution execution, String param) {
// another example
}
@@ -10,7 +10,7 @@ import org.springframework.stereotype.Component;
@Component
public class ExampleExtension implements Bootstrappable {
private final Logger logger = LoggerFactory.getLogger(this.getClass());
private static final Logger LOGGER = LoggerFactory.getLogger(ExampleExtension.class);
@Autowired
private ProcessEngine services;
@@ -23,11 +23,11 @@ public class ExampleExtension implements Bootstrappable {
@Override
public void onBootstrap() {
this.logger.trace("onBootstrap()");
LOGGER.trace("onBootstrap()");
// TODO do some stuff
this.logger.info("Model Share Extension initialized");
LOGGER.info("Model Share Extension initialized");
}
}
@@ -0,0 +1,41 @@
/*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <https://www.gnu.org/licenses/>.
*/
package ${package};
import org.activiti.engine.delegate.DelegateExecution;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;
/**
* This class is an example of how you can implement an Activiti script object.
* A scripting object can be used in any expression or Script Task.
*
* You can reference it in your BPMN expression with:
* ${exampleObject.exampleMethod('example parameter')}
*
* You can reference it in your Script Task with:
* exampleObject.exampleMethod('example parameter');
*/
@Component("exampleObject")
public class ExampleServiceTask {
private static final Logger LOGGER = LoggerFactory.getLogger(this.getClass());
public void exampleMethod(String param) throws Exception {
// another example
}
}
@@ -24,21 +24,21 @@ import org.springframework.stereotype.Component;
* This class is an example of how you can implement an Activiti Service Task.
* You can reference it in your BPMN with:
* <serviceTask id="serviceTask" activiti:delegateExpression="${exampleServiceTask}" />
* <serviceTask id="serviceTask" activiti:expression="${exampleServiceTask.exampleMethod('example parameter')}" />
* <serviceTask id="serviceTask" activiti:expression="${exampleServiceTask.exampleMethod(execution, 'example parameter')}" />
*/
@Component("exampleServiceTask")
public class ExampleServiceTask implements JavaDelegate {
private final Logger logger = LoggerFactory.getLogger(this.getClass());
private static final Logger LOGGER = LoggerFactory.getLogger(ExampleServiceTask.class);
@Override
public void execute(DelegateExecution execution) throws Exception {
if (this.logger.isTraceEnabled())
this.logger.trace("execute('" + execution.getId() + "')");
LOGGER.trace("execute({})", execution.getId());
// TODO do some stuff
}
public void exampleMethod(String param) throws Exception {
public void exampleMethod(DelegateExecution execution, String param) throws Exception {
// another example
}
@@ -0,0 +1,45 @@
/*
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <https://www.gnu.org/licenses/>.
*/
package ${package};
import org.activiti.engine.delegate.DelegateTask;
import org.activiti.engine.delegate.TaskListener;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.stereotype.Component;
/**
* This class is an example of how you can implement an Activiti Task Listener.
* You can reference it in your BPMN with:
* <activiti:taskListener delegateExpression="${exampleTaskListener}" event="start" />
* <activiti:taskListener expression="${exampleTaskListener.exampleMethod(task, 'example parameter')}" event="end" />
*/
@Component("exampleTaskListener")
public class ExampleTaskListener implements TaskListener {
private static final Logger LOGGER = LoggerFactory.getLogger(ExampleTaskListener.class);
@Override
public void notify(DelegateTask task) {
LOGGER.trace("execute({})", task.getId());
// TODO do some stuff
}
public void exampleMethod(DelegateTask task, String param) {
// another example
}
}
@@ -16,9 +16,18 @@ package com.activiti.extension.conf;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.FullyQualifiedAnnotationBeanNameGenerator;
/**
* A means for injecting packages to scan for the Spring context.
*/
@Configuration
@ComponentScan(basePackages = {"${package}"})
@ComponentScan(
basePackages = {
"${package}"
},
nameGenerator = FullyQualifiedAnnotationBeanNameGenerator.class
)
public class ${shortname}SpringComponentScanner {
}
+2 -2
View File
@@ -57,7 +57,7 @@ The following properties are intended to be exposed by inheriting Public API Mav
| `aps.timeout` | | 120000 | The time to wait for the startup to complete, in milliseconds. |
| `alfresco.license.directory` | | `${user.home}/alfresco/license` | The base path to search for Alfresco licenses. |
| `aps.license.directory` | | `${alfresco.license.directory}/aps` | The base path to search for an APS license. |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-docker). |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-image). |
| `aps-postgres.version` | | *not important* | The version of PostgreSQL to use in the integration testing infrastructure. |
### Private API
@@ -71,7 +71,6 @@ The following properties are only intended to be defined by BeeDK components.
| `beedk.deploy.aps.testClassesDirectory` | | | An additional test classpath directory to sideload into the web application. |
| `beedk.deploy.aps.extDirectory` | | | An additional directory of JARs to sideload into the web application. |
| `beedk.deploy.aps.warDirectory` | | `${project.build.warDirectory}` | A build directory for WAR files. |
| `beedk.deploy.aps.dataDirectory` | | `${project.build.directory}/alf_data` | The temporary binary storage location for ACS. |
### Other APIs
@@ -84,6 +83,7 @@ Additional less important configurations are inherited from the following Maven
| Maven Property |
| ---------------------------------- |
| `maven-dependency-plugin.version` |
| `fs-plugin.version` |
## Results
+62 -4
View File
@@ -21,22 +21,49 @@
<build>
<testResources>
<!-- need to split certain test resources to load before webapp -->
<!-- these will load before the WAR, are accessible earlier, and could be shadowed by it -->
<testResource>
<directory>src/test/resources</directory>
<filtering>true</filtering>
<excludes>
<exclude>activiti/**/*</exclude>
<exclude>**/*.properties</exclude>
<exclude>**/README*</exclude>
</excludes>
</testResource>
<testResource>
<directory>src/it/resources</directory>
<filtering>true</filtering>
<excludes>
<exclude>activiti/**/*</exclude>
<exclude>**/*.properties</exclude>
<exclude>**/README*</exclude>
</excludes>
</testResource>
<!-- these will load after the WAR and could shadow it -->
<testResource>
<directory>src/test/resources</directory>
<filtering>true</filtering>
<includes>
<include>activiti/**/*</include>
<include>**/*.properties</include>
</includes>
<targetPath>${project.build.directory}/rt-test-resources</targetPath>
</testResource>
<testResource>
<directory>src/it/resources</directory>
<filtering>true</filtering>
<includes>
<include>activiti/**/*</include>
<include>**/*.properties</include>
</includes>
<targetPath>${project.build.directory}/rt-test-resources</targetPath>
</testResource>
<testResource>
<directory>${java.cacerts.directory}</directory>
<filtering>false</filtering>
<targetPath>${project.build.directory}/cacerts</targetPath>
</testResource>
</testResources>
<plugins>
<!-- This plugin downloads the parameterized WAR -->
@@ -74,6 +101,26 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.inteligr8</groupId>
<artifactId>fs-maven-plugin</artifactId>
<version>${fs-plugin.version}</version>
<executions>
<!-- creates missing directories used in volumes, which is required for podman -->
<execution>
<id>mkdirs-docker-volumes</id>
<phase>pre-integration-test</phase>
<goals><goal>mkdir</goal></goals>
<configuration>
<paths>
<path>${project.build.directory}/rt-resources</path>
<path>${project.build.directory}/rt-test-resources</path>
<path>${project.build.directory}/cacerts</path>
</paths>
</configuration>
</execution>
</executions>
</plugin>
<!-- Using Docker to host the web application -->
<plugin>
<groupId>io.fabric8</groupId>
@@ -148,10 +195,16 @@
<bind>
<volume>${aps.license.directory}:/root/.activiti/enterprise-license:ro</volume>
<volume>${project.build.warFile}:/var/lib/tomcat/webapps/activiti-app.war:ro</volume>
<volume>${project.build.directory}/cacerts:/usr/local/share/ca-certificates:ro</volume>
<!-- include runtime-only resources -->
<volume>${project.build.directory}/rt-resources:/var/lib/tomcat/dev/classes:ro</volume>
<volume>${beedk.deploy.aps.classesDirectory}:/var/lib/tomcat/dev/post-rsrc:ro</volume>
<volume>${project.build.directory}/rt-test-resources:/var/lib/tomcat/dev/classes-extra1:ro</volume>
<!-- get transform.lic into the classpath -->
<volume>${aps.license.directory}:/var/lib/tomcat/dev/classes-extra2:ro</volume>
<!-- include classes post-rsrc to shadow WAR -->
<volume>${beedk.deploy.aps.classesDirectory}:/var/lib/tomcat/dev/post-rsrc:ro</volume>
<volume>${beedk.deploy.aps.testClassesDirectory}:/var/lib/tomcat/dev/post-rsrc-extra1:ro</volume>
<!-- include compile/runtime scope dependencies -->
<volume>${beedk.deploy.aps.extDirectory}:/var/lib/tomcat/dev/lib:ro</volume>
</bind>
</volumes>
@@ -225,6 +278,8 @@
<aps.debugger.enabled>true</aps.debugger.enabled>
<alfresco.license.directory>${user.home}/alfresco/license</alfresco.license.directory>
<aps.license.directory>${alfresco.license.directory}/aps</aps.license.directory>
<java.cacerts.directory>src/test/cacerts</java.cacerts.directory>
<maven.test.additionalClasspath>${project.build.directory}/rt-resources,${project.build.directory}/rt-test-resources</maven.test.additionalClasspath>
<!-- ports -->
<aps-postgres.port>5433</aps-postgres.port>
@@ -233,9 +288,10 @@
<!-- versions -->
<aps-postgres.version>15</aps-postgres.version>
<aps.version>25.1.1</aps.version>
<tomcat-rad.version>10-2.2</tomcat-rad.version>
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<aps.version>26.1.0</aps.version>
<tomcat-rad.version>2.3-tomcat11</tomcat-rad.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
<fs-plugin.version>1.0.0</fs-plugin.version>
<!-- results -->
<project.build.warFile>${project.build.warDirectory}/${aps.war.artifactId}-${aps.war.version}.war</project.build.warFile>
@@ -244,6 +300,8 @@
</profiles>
<tiles>
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-aps-ext-tile -->
<tile>@project.groupId@:beedk-aps-ext-tile:@project.version@</tile>
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-run-tile -->
<tile>@project.groupId@:beedk-run-tile:@project.version@</tile>
</tiles>
+2 -2
View File
@@ -61,7 +61,7 @@ The following properties are intended to be exposed by inheriting Public API Mav
| `aps.timeout` | | 120000 | The time to wait for the startup to complete, in milliseconds. |
| `alfresco.license.directory` | | `${user.home}/alfresco/license` | The base path to search for Alfresco licenses. |
| `aps.license.directory` | | `${alfresco.license.directory}/aps` | The base path to search for an APS license. |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-docker). |
| `tomcat-rad.version` | | *not important* | The version of the [Apache Tomcat Rapid Application Development Docker container](/inteligr8/tomcat-rad-image). |
| `aps-postgres.version` | | *not important* | The version of PostgreSQL to use in the integration testing infrastructure. |
### Private API
@@ -75,7 +75,6 @@ The following properties are only intended to be defined by BeeDK components.
| `beedk.deploy.aps.testClassesDirectory` | | | An additional test classpath directory to sideload into the web application. |
| `beedk.deploy.aps.extDirectory` | | | An additional directory of JARs to sideload into the web application. |
| `beedk.deploy.aps.warDirectory` | | `${project.build.warDirectory}` | A build directory for WAR files. |
| `beedk.deploy.aps.dataDirectory` | | `${project.build.directory}/alf_data` | The temporary binary storage location for ACS. |
### Other APIs
@@ -88,6 +87,7 @@ Additional less important configurations are inherited from the following Maven
| Maven Property |
| ---------------------------------- |
| `maven-dependency-plugin.version` |
| `fs-plugin.version` |
## Results
+61 -4
View File
@@ -29,22 +29,49 @@
<build>
<testResources>
<!-- need to split certain test resources to load before webapp -->
<!-- these will load before the WAR, are accessible earlier, and could be shadowed by it -->
<testResource>
<directory>src/test/resources</directory>
<filtering>true</filtering>
<excludes>
<exclude>activiti/**/*</exclude>
<exclude>**/*.properties</exclude>
<exclude>**/README*</exclude>
</excludes>
</testResource>
<testResource>
<directory>src/it/resources</directory>
<filtering>true</filtering>
<excludes>
<exclude>activiti/**/*</exclude>
<exclude>**/*.properties</exclude>
<exclude>**/README*</exclude>
</excludes>
</testResource>
<!-- these will load after the WAR and could shadow it -->
<testResource>
<directory>src/test/resources</directory>
<filtering>true</filtering>
<includes>
<include>activiti/**/*</include>
<include>**/*.properties</include>
</includes>
<targetPath>${project.build.directory}/rt-test-resources</targetPath>
</testResource>
<testResource>
<directory>src/it/resources</directory>
<filtering>true</filtering>
<includes>
<include>activiti/**/*</include>
<include>**/*.properties</include>
</includes>
<targetPath>${project.build.directory}/rt-test-resources</targetPath>
</testResource>
<testResource>
<directory>${java.cacerts.directory}</directory>
<filtering>false</filtering>
<targetPath>${project.build.directory}/cacerts</targetPath>
</testResource>
</testResources>
<plugins>
<!-- This plugin downloads the parameterized WAR -->
@@ -82,6 +109,26 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>com.inteligr8</groupId>
<artifactId>fs-maven-plugin</artifactId>
<version>${fs-plugin.version}</version>
<executions>
<!-- creates missing directories used in volumes, which is required for podman -->
<execution>
<id>mkdirs-docker-volumes</id>
<phase>process-test-classes</phase>
<goals><goal>mkdir</goal></goals>
<configuration>
<paths>
<path>${project.build.directory}/rt-resources</path>
<path>${project.build.directory}/rt-test-resources</path>
<path>${project.build.directory}/cacerts</path>
</paths>
</configuration>
</execution>
</executions>
</plugin>
<!-- Using Docker to host the web application -->
<plugin>
<groupId>io.fabric8</groupId>
@@ -153,10 +200,16 @@
<bind>
<volume>${aps.license.directory}:/root/.activiti/enterprise-license:ro</volume>
<volume>${project.build.warFile}:/var/lib/tomcat/webapps/activiti-app.war:ro</volume>
<volume>${project.build.directory}/cacerts:/usr/local/share/ca-certificates:ro</volume>
<!-- include runtime-only resources -->
<volume>${project.build.directory}/rt-resources:/var/lib/tomcat/dev/classes:ro</volume>
<volume>${beedk.deploy.aps.classesDirectory}:/var/lib/tomcat/dev/post-rsrc:ro</volume>
<volume>${project.build.directory}/rt-test-resources:/var/lib/tomcat/dev/classes-extra1:ro</volume>
<!-- get transform.lic into the classpath -->
<volume>${aps.license.directory}:/var/lib/tomcat/dev/classes-extra2:ro</volume>
<!-- include classes post-rsrc to shadow WAR -->
<volume>${beedk.deploy.aps.classesDirectory}:/var/lib/tomcat/dev/post-rsrc:ro</volume>
<volume>${beedk.deploy.aps.testClassesDirectory}:/var/lib/tomcat/dev/post-rsrc-extra1:ro</volume>
<!-- include compile/runtime scope dependencies -->
<volume>${beedk.deploy.aps.extDirectory}:/var/lib/tomcat/dev/lib:ro</volume>
</bind>
</volumes>
@@ -213,6 +266,7 @@
<aps.debugger.enabled>true</aps.debugger.enabled>
<alfresco.license.directory>${user.home}/alfresco/license</alfresco.license.directory>
<aps.license.directory>${alfresco.license.directory}/aps</aps.license.directory>
<java.cacerts.directory>src/test/cacerts</java.cacerts.directory>
<!-- ports -->
<aps-postgres.port>5433</aps-postgres.port>
@@ -221,9 +275,10 @@
<!-- versions -->
<aps-postgres.version>15</aps-postgres.version>
<aps.version>25.1.1</aps.version>
<tomcat-rad.version>10-2.2</tomcat-rad.version>
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<aps.version>26.1.0</aps.version>
<tomcat-rad.version>2.3-tomcat11</tomcat-rad.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
<fs-plugin.version>1.0.0</fs-plugin.version>
<!-- results -->
<project.build.warFile>${project.build.warDirectory}/${aps.war.artifactId}-${aps.war.version}.war</project.build.warFile>
@@ -232,6 +287,8 @@
</profiles>
<tiles>
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-aps-ext-tile -->
<tile>@project.groupId@:beedk-aps-ext-tile:@project.version@</tile>
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-run-tile -->
<tile>@project.groupId@:beedk-run-tile:@project.version@</tile>
</tiles>
@@ -1,9 +1,9 @@
# Maven
/target
pom.xml.versionsBackup
# Eclipse
.settings
.project
.classpath
.settings
# Maven
pom.xml.versionsBackup
target
+48
View File
@@ -0,0 +1,48 @@
# BeeDK APS Extension Maven Tile
This is a component within the proposed [BeeDK](/inteligr8/ootbee-beedk). It is considered to be part of the **Public API** of the BeeDK.
## Purpose
This project creates a [Maven Tile](https://github.com/repaint-io/maven-tiles) that assists with the building of any APS extension.
## Usage
To use this plugin, just reference it with the Maven Tiles plugin as shown in the following snippet. Do not forget the `extensions` element in the *plugin* configuration.
```xml
<project ...>
...
<build>
...
<plugins>
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>[2.0,3.0)</version>
<extensions>true</extensions>
<configuration>
<tiles>
...
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-aps-ext-tile -->
<tile>com.inteligr8.ootbee:beedk-aps-ext-tile:[1.0.0,2.0.0)</tile>
</tiles>
</configuration>
</plugin>
...
</plugins>
...
</build>
...
</project>
```
## Configuration
In your Maven project, set the following properties to define the behavior of this Maven Tile. Unless otherwise stated, they can only be overridden in the project POM or other Maven Tiles loaded earlier than this Maven Tile.
### Other APIs
Additional less important configurations are inherited from the following Maven Tiles.
* [`beedk-activiti-ext-tile`](/inteligr8/ootbee-beedk/src/branch/stable/beedk-activiti-ext-tile)
+55
View File
@@ -0,0 +1,55 @@
<?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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<artifactId>beedk-aps-ext-tile</artifactId>
<packaging>tile</packaging>
<parent>
<groupId>com.inteligr8.ootbee</groupId>
<artifactId>beedk-parent</artifactId>
<version>1.1-SNAPSHOT</version>
<relativePath>..</relativePath>
</parent>
<name>Order of the Bee Development Kit: APS Extension</name>
<url>https://git.inteligr8.com/inteligr8/ootbee-beedk</url>
<licenses>
<license>
<name>GNU GENERAL PUBLIC LICENSE, Version 3, 29 June 2007</name>
<url>https://www.gnu.org/licenses/lgpl-3.0.txt</url>
</license>
</licenses>
<scm>
<connection>scm:git:https://git.inteligr8.com/inteligr8/ootbee-beedk.git</connection>
<developerConnection>scm:git:git@git.inteligr8.com:inteligr8/ootbee-beedk.git</developerConnection>
<url>https://git.inteligr8.com/inteligr8/ootbee-beedk</url>
</scm>
<organization>
<name>Order of the Bee</name>
<url>https://orderofthebee.net</url>
</organization>
<developers>
<developer>
<id>brian.long</id>
<name>Brian Long</name>
<email>brian@inteligr8.com</email>
<organization>Inteligr8</organization>
<organizationUrl>https://www.inteligr8.com</organizationUrl>
<url>https://twitter.com/brianmlong</url>
</developer>
</developers>
<build>
<plugins>
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
</project>
+26
View File
@@ -0,0 +1,26 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or (at your
* option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along
* with this program. If not, see <https://www.gnu.org/licenses/>.
*
-->
<project xmlns="http://tiles.bluetrainsoftware.com/maven/tiles/1.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://tiles.bluetrainsoftware.com/maven/tiles/1.1.0 https://git.inteligr8.com/inteligr8/maven-tiles/raw/xsd/src/main/resources/maven-tiles.xsd">
<tiles>
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-activiti-ext-tile -->
<tile>@project.groupId@:beedk-activiti-ext-tile:@project.version@</tile>
</tiles>
</project>
@@ -13,13 +13,14 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>8</maven.compiler.source>
<maven.compiler.target>8</maven.compiler.target>
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
<maven.compiler.release>11</maven.compiler.release>
<ats.version>2.3.6</ats.version>
<spring-boot.version>2.3.5.RELEASE</spring-boot.version>
<ats.version>5.2.5</ats.version>
<spring-boot.version>3.5.7</spring-boot.version>
<ate.app.className>${package}.Applicatoin</ate.app.className>
<ate.app.className>${package}.Application</ate.app.className>
<docker.image.registry>${dockerRegistryHost}</docker.image.registry>
<docker.image.name>${dockerImagePrefix}/${project.artifactId}</docker.image.name>
<docker.image.tag>${project.version}</docker.image.tag>
@@ -53,7 +54,7 @@
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>2.40</version>
<version>2.45</version>
<extensions>true</extensions>
<configuration>
<tiles>
+1 -1
View File
@@ -62,7 +62,7 @@ The following properties are intended to be exposed by inheriting Public API Mav
| Maven Property |
| ---------------------------------- |
| `download-plugin.version` |
| `download-maven-plugin.version` |
## Results
+2 -2
View File
@@ -32,7 +32,7 @@
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>${download-plugin.version}</version>
<version>${download-maven-plugin.version}</version>
<executions>
<!-- TODO eventually replace these with the archetype versions -->
<execution>
@@ -64,7 +64,7 @@
<ate.docker.image.tag>${docker.image.tag}</ate.docker.image.tag>
<!-- versions -->
<download-plugin.version>1.13.0</download-plugin.version>
<download-maven-plugin.version>@download-maven-plugin.version@</download-maven-plugin.version>
</properties>
</profile>
</profiles>
+1 -1
View File
@@ -123,7 +123,7 @@
<!-- versions -->
<java-dcevm-hotswap.version>11.0.11-1.4.1</java-dcevm-hotswap.version>
<maven-dependency-plugin.version>3.9.0</maven-dependency-plugin.version>
<maven-dependency-plugin.version>@maven-dependency-plugin.version@</maven-dependency-plugin.version>
</properties>
</profile>
</profiles>
-1
View File
@@ -46,7 +46,6 @@
<properties>
<alfresco.transform-base.version>2.3.6</alfresco.transform-base.version>
<spring-boot.version>2.3.5.RELEASE</spring-boot.version>
</properties>
<dependencies>
+7 -7
View File
@@ -46,16 +46,16 @@ In your Maven project, set the following properties to define the behavior of th
The following properties are intended to be exposed by inheriting Public API Maven Tiles.
| Maven Property | Required | Default | Description |
| --------------------- |:--------:| ------- | ----------- |
| `spring-boot.version` | | 2.4.3 | For a list of versions and more details, see the [Spring Boot Project](https://spring.io/projects/spring-boot).<br/>You could use a different Spring Boot version for building your application. This one is only for repackaging it with all dependencies. |
| Maven Property | Required | Default | Description |
| --------------------- |:--------:| --------------- | ----------- |
| `spring-boot.version` | | *not important* | For a list of versions and more details, see the [Spring Boot Project](https://spring.io/projects/spring-boot).<br/>You could use a different Spring Boot version for building your application. This one is only for repackaging it with all dependencies. |
### Plugin Versions
| Maven Property |
| ---------------------------------- |
| `build-helper-plugin.version` |
| `download-plugin.version` |
| Maven Property |
| ----------------------------------- |
| `build-helper-maven-plugin.version` |
| `download-maven-plugin.version` |
## Results
+5 -5
View File
@@ -23,7 +23,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>${build-helper-plugin.version}</version>
<version>${build-helper-maven-plugin.version}</version>
<executions>
<execution>
<id>filter-default-resources</id>
@@ -88,7 +88,7 @@
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>${download-plugin.version}</version>
<version>${download-maven-plugin.version}</version>
<executions>
<!-- TODO eventually replace these with the archetype versions -->
<!-- TODO also create Java source; including placing in package -->
@@ -139,9 +139,9 @@
</activation>
<properties>
<!-- versions -->
<spring-boot.version>2.4.3</spring-boot.version>
<build-helper-plugin.version>3.6.1</build-helper-plugin.version>
<download-plugin.version>1.13.0</download-plugin.version>
<spring-boot.version>@spring-boot.version@</spring-boot.version>
<build-helper-maven-plugin.version>@build-helper-maven-plugin.version@</build-helper-maven-plugin.version>
<download-maven-plugin.version>1.13.0</download-maven-plugin.version>
</properties>
</profile>
</profiles>
+1 -1
View File
@@ -43,7 +43,7 @@
</activation>
<properties>
<!-- versions -->
<fabric8-docker-maven-plugin.version>0.46.0</fabric8-docker-maven-plugin.version>
<fabric8-docker-maven-plugin.version>0.48.0</fabric8-docker-maven-plugin.version>
</properties>
</profile>
</profiles>
@@ -1,40 +0,0 @@
<archetype-descriptor name="${project.artifactId}"
xmlns="https://maven.apache.org/plugins/maven-archetype-plugin/archetype-descriptor/1.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="https://maven.apache.org/plugins/maven-archetype-plugin/archetype-descriptor/1.1.0 https://maven.apache.org/xsd/archetype-descriptor-1.1.0.xsd">
<requiredProperties>
<requiredProperty key="shortname">
<validationRegex>[A-Za-z0-9]+</validationRegex>
</requiredProperty>
<requiredProperty key="dockerRegistryHost">
<defaultValue>quay.io</defaultValue>
</requiredProperty>
<requiredProperty key="dockerImagePrefix">
<defaultValue>local</defaultValue>
</requiredProperty>
<requiredProperty key="beedkVersion">
<defaultValue>[1.0.0,2.0.0)</defaultValue>
</requiredProperty>
</requiredProperties>
<fileSets>
<fileSet filtered="true" packaged="true">
<directory>src/main/java</directory>
<includes>
<include>**/*</include>
</includes>
</fileSet>
<fileSet filtered="true" packaged="true">
<directory>src/test/java</directory>
<includes>
<include>**/*</include>
</includes>
</fileSet>
<fileSet filtered="true">
<directory>src</directory>
<excludes>
<exclude>main/java/**/*</exclude>
<exclude>test/java/**/*</exclude>
</excludes>
</fileSet>
</fileSets>
</archetype-descriptor>
@@ -1,68 +0,0 @@
<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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>${groupId}</groupId>
<artifactId>${artifactId}</artifactId>
<version>${version}</version>
<packaging>jar</packaging>
<name>${shortname}</name>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.release.source>11</maven.release.source>
<alfresco.restapi.version>5.0.0</alfresco.restapi.version>
<!-- for RAD environment -->
<edition>community</edition>
<alfresco.platform.version>7.4.2</alfresco.platform.version>
<!-- for Docker deployment -->
<docker.image.registry>${dockerRegistryHost}</docker.image.registry>
<docker.image.name>${dockerImagePrefix}/${project.artifactId}</docker.image.name>
<docker.image.tag>${project.version}</docker.image.tag>
</properties>
<dependencies>
<!-- Optional; use for REST API access -->
<dependency>
<groupId>org.alfresco</groupId>
<artifactId>alfresco-java-rest-api-spring-boot-starter</artifactId>
<version>${alfresco.restapi.version}</version>
</dependency>
<!-- Optional; use for Event API access -->
<dependency>
<groupId>org.alfresco</groupId>
<artifactId>alfresco-java-event-api-spring-boot-starter</artifactId>
<version>${alfresco.restapi.version}</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>io.repaint.maven</groupId>
<artifactId>tiles-maven-plugin</artifactId>
<version>2.40</version>
<extensions>true</extensions>
<configuration>
<tiles>
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-acs-platform-artifact-rad-tile -->
<tile>com.inteligr8.ootbee:beedk-acs-platform-artifact-rad-tile:${beedkVersion}</tile>
<!-- Documentation: https://git.inteligr8.com/inteligr8/ootbee-beedk/src/branch/stable/beedk-springboot-docker-tile -->
<tile>com.inteligr8.ootbee:beedk-springboot-docker-tile:${beedkVersion}</tile>
</tiles>
</configuration>
</plugin>
</plugins>
</build>
<repositories>
<repository>
<id>alfresco-public</id>
<url>https://artifacts.alfresco.com/nexus/content/groups/public</url>
</repository>
</repositories>
</project>
@@ -1,26 +0,0 @@
FROM docker.inteligr8.com/inteligr8/ubuntu-jdk:20.04-11
# Set default user information
ARG JAR_FILE=target/${env.project_artifactId}-${env.project_version}.jar
ARG APPGROUPNAME=alfresco
ARG APPGROUPID=1000
ARG APPUSERNAME=atengine
ARG APPUSERID=33001
ENV JAVA_OPTS="-Xmx128m"
ENV JAR_PATH=/usr/local/bin/${env.project_artifactId}-${env.project_version}.jar
COPY ${JAR_FILE} ${JAR_PATH}
# Install your engine's dependencies here
#RUN apt update && \
# apt -y install {dependency names in APT repository}
RUN groupadd -g ${APPGROUPID} ${APPGROUPNAME} && \
useradd -u ${APPUSERID} -G ${APPGROUPNAME} ${APPUSERNAME} && \
chown ${APPUSERNAME}:${APPGROUPNAME} ${JAR_PATH}
USER ${APPUSERNAME}
ENTRYPOINT java ${JAVA_OPTS} -jar ${JAR_PATH}
@@ -1,67 +0,0 @@
/*
* #%L
* Alfresco Transform Core
* %%
* Copyright (C) 2005 - 2020 Alfresco Software Limited
* %%
* This file is part of the Alfresco software.
* -
* If the software was purchased under a paid Alfresco license, the terms of
* the paid license agreement will prevail. Otherwise, the software is
* provided under the following open source license terms:
* -
* Alfresco is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
* -
* Alfresco is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
* -
* You should have received a copy of the GNU Lesser General Public License
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
* #L%
*/
package ${package};
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.actuate.autoconfigure.metrics.MeterRegistryCustomizer;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
import org.springframework.boot.context.event.ApplicationReadyEvent;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ImportResource;
import org.springframework.context.event.EventListener;
import io.micrometer.core.instrument.MeterRegistry;
@SpringBootApplication
@EnableAutoConfiguration(exclude = { DataSourceAutoConfiguration.class })
@ImportResource({"classpath*:application-context.xml"})
public class Application {
private final Logger logger = LoggerFactory.getLogger(Application.class);
@Value("${container.name}")
private String containerName;
@Bean
public MeterRegistryCustomizer<MeterRegistry> metricsCommonTags() {
return registry -> registry.config().commonTags("containerName", this.containerName);
}
public static void main(String[] args) {
SpringApplication.run(Application.class, args);
}
@EventListener(ApplicationReadyEvent.class)
public void startup() {
this.logger.info("Starting application components... Done");
}
}
@@ -1,8 +0,0 @@
<?xml version='1.0' encoding='UTF-8'?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
<bean autowire-candidate="true" class="org.springframework.web.client.RestTemplate" />
</beans>
@@ -1,5 +0,0 @@
#set( $dollar = '$' )
logging:
level:
${groupId}: ${dollar}{LOG_LEVEL:info}
@@ -1,174 +0,0 @@
/*
* #%L
* Alfresco Transform Core
* %%
* Copyright (C) 2005 - 2019 Alfresco Software Limited
* %%
* This file is part of the Alfresco software.
* -
* If the software was purchased under a paid Alfresco license, the terms of
* the paid license agreement will prevail. Otherwise, the software is
* provided under the following open source license terms:
* -
* Alfresco is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
* -
* Alfresco is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
* -
* You should have received a copy of the GNU Lesser General Public License
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
* #L%
*/
package ${groupId};
import java.util.HashSet;
import java.util.Set;
import javax.annotation.PostConstruct;
import org.jsoup.Jsoup;
import org.jsoup.nodes.Document;
import org.jsoup.nodes.Element;
import org.jsoup.select.Elements;
import org.junit.Assert;
import org.junit.Test;
import org.junit.Ignore;
import org.junit.runner.RunWith;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.context.SpringBootTest.WebEnvironment;
import org.springframework.boot.test.web.client.TestRestTemplate;
import org.springframework.boot.web.server.LocalServerPort;
import org.springframework.core.io.ClassPathResource;
import org.springframework.http.HttpEntity;
import org.springframework.http.HttpHeaders;
import org.springframework.http.MediaType;
import org.springframework.http.ResponseEntity;
import org.springframework.test.context.junit4.SpringRunner;
import org.springframework.util.LinkedMultiValueMap;
import org.springframework.web.client.HttpStatusCodeException;
@RunWith(SpringRunner.class)
@SpringBootTest(webEnvironment = WebEnvironment.RANDOM_PORT)
public class HttpRequestIT {
private final Logger logger = LoggerFactory.getLogger(HttpRequestIT.class);
@LocalServerPort
private int port;
@Autowired
private TestRestTemplate restTemplate;
protected String baseUrl;
@PostConstruct
public void init() {
this.baseUrl = "http://localhost:" + this.port;
}
@Test
public void testRootPath() {
String result = this.restTemplate.getForObject(this.baseUrl, String.class);
if (this.logger.isDebugEnabled())
this.logger.debug("testRootPath(): result: " + result);
Assert.assertNotNull("A result from the HTTP GET was expected", result);
Document htmldoc = Jsoup.parse(result);
Assert.assertNotNull("An HTML compliant result was expected: " + result.substring(0, 50), htmldoc);
Elements elements = htmldoc.select("html body h2");
Assert.assertFalse("The HTML body is expected to have an h2 element: html: " + htmldoc.toString(), elements.isEmpty());
Assert.assertEquals("The HTML body is expected to have just one h2 element", 1, elements.size());
Assert.assertEquals("The HTML body header is not what was expected", "${shortname} Test Transformation", elements.html());
elements = htmldoc.select("html input");
Set<String> inputs = new HashSet<String>();
for (Element element : elements)
inputs.add(element.attr("name"));
Assert.assertTrue("The HTML is expected to have a form input for 'file': " + inputs.toString(), inputs.contains("file"));
Assert.assertTrue("The HTML is expected to have a form input for 'targetExtension': " + inputs.toString(), inputs.contains("targetExtension"));
}
@Test
public void testLogPath() {
String result = this.restTemplate.getForObject(this.baseUrl + "/log", String.class);
if (this.logger.isDebugEnabled())
this.logger.debug("testLogPath(): result: " + result);
Assert.assertNotNull("A result from the HTTP GET was expected", result);
Document htmldoc = Jsoup.parse(result);
Assert.assertNotNull("An HTML compliant result was expected: " + result.substring(0, 50), htmldoc);
Elements elements = htmldoc.select("html body div h2");
Assert.assertFalse("The HTML is expected to have an html/body/div/h2 element: html: " + htmldoc.select("html").toString(), elements.isEmpty());
Assert.assertEquals("The HTML is expected to have just one html/body/div/h2 element", 1, elements.size());
Assert.assertEquals("The HTML body header is not what was expected", "${shortname} Log Entries", elements.html());
}
@Test
public void testNoPath() {
try {
ResponseEntity<String> response = this.restTemplate.getForEntity(this.baseUrl + "/doesnotexist", String.class);
Assert.assertEquals("An unexpected path must return a 404 error", 404, response.getStatusCodeValue());
} catch (HttpStatusCodeException hsce) {
Assert.assertEquals("An unexpected path must return a 404 error", 404, hsce.getRawStatusCode());
}
}
@Test
public void testServiceGet() {
try {
ResponseEntity<String> response = this.restTemplate.getForEntity(this.baseUrl + "/transform", String.class);
Assert.assertEquals("An unexpected path must return a 405 error", 405, response.getStatusCodeValue());
} catch (HttpStatusCodeException hsce) {
Assert.assertEquals("An unexpected path must return a 405 error", 405, hsce.getRawStatusCode());
}
}
@Test
public void testServiceNoFile() {
try {
ResponseEntity<String> response = this._testService(null, "trgt");
Assert.assertEquals("An unexpected path must return a 400 error", 400, response.getStatusCodeValue());
} catch (HttpStatusCodeException hsce) {
Assert.assertEquals("An unexpected path must return a 400 error", 400, hsce.getRawStatusCode());
}
}
@Test @Ignore
public void testServiceNoTargetExtension() {
try {
ResponseEntity<String> response = this._testService("quick.src", null);
Assert.assertEquals("An unexpected path must return a 400 error", 400, response.getStatusCodeValue());
} catch (HttpStatusCodeException hsce) {
Assert.assertEquals("An unexpected path must return a 400 error", 400, hsce.getRawStatusCode());
}
}
@Test @Ignore
public void testServiceQuick() {
this._testService("quick.src", "trgt");
}
protected ResponseEntity<String> _testService(String filename, String targetExtension) {
LinkedMultiValueMap<String, Object> parameters = new LinkedMultiValueMap<>();
if (filename != null)
parameters.add("file", new ClassPathResource(filename));
if (targetExtension != null)
parameters.add("targetExtension", targetExtension);
HttpHeaders headers = new HttpHeaders();
headers.setContentType(MediaType.MULTIPART_FORM_DATA);
HttpEntity<LinkedMultiValueMap<String, Object>> entity = new HttpEntity<>(parameters, headers);
return this.restTemplate.postForEntity(this.baseUrl + "/transform", entity, String.class);
}
}
@@ -1,22 +0,0 @@
package ${groupId};
import org.alfresco.transformer.AbstractTransformerController;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.autoconfigure.web.servlet.WebMvcTest;
import org.springframework.test.context.junit4.SpringRunner;
@RunWith(SpringRunner.class)
@WebMvcTest(controllers = TransformerController.class)
public class TransformerControllerTest {
@Autowired
protected AbstractTransformerController controller;
@Test @Ignore
public void test() {
}
}
@@ -1,14 +0,0 @@
queue:
#set( $dollar = '$' )
engineRequestQueue: ${dollar}{TRANSFORM_ENGINE_REQUEST_QUEUE:${groupId}.${shortname}.acs}
transform:
core:
config:
location: classpath:this_engine_config.json
${shortname}:
version: ${project.version}
logging:
level:
${groupId}: ${dollar}{LOG_LEVEL:trace}
+4 -4
View File
@@ -55,10 +55,10 @@ The following properties are intended to be exposed by inheriting Public API Mav
### Plugin Versions
| Maven Property |
| ---------------------------------- |
| `maven-resources-plugin.version` |
| `build-helper-plugin.version` |
| Maven Property |
| ----------------------------------- |
| `maven-resources-plugin.version` |
| `build-helper-maven-plugin.version` |
## Results
+3 -3
View File
@@ -25,7 +25,7 @@
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<version>${build-helper-plugin.version}</version>
<version>${build-helper-maven-plugin.version}</version>
<executions>
<execution>
<id>copy-and-filter-docker-resources</id>
@@ -147,8 +147,8 @@
<docker.image.tag>${project.version}</docker.image.tag>
<!-- versions -->
<build-helper-plugin.version>3.6.1</build-helper-plugin.version>
<maven-resources-plugin.version>3.4.0</maven-resources-plugin.version>
<build-helper-maven-plugin.version>@build-helper-maven-plugin.version@</build-helper-maven-plugin.version>
<maven-resources-plugin.version>@maven-resources-plugin.version@</maven-resources-plugin.version>
</properties>
</profile>
</profiles>
+1 -1
View File
@@ -57,7 +57,7 @@ The following properties are intended to be exposed by inheriting Public API Mav
| Maven Property |
| ---------------------------------- |
| `download-plugin.version` |
| `download-maven-plugin.version` |
## Results
+2 -2
View File
@@ -32,7 +32,7 @@
<plugin>
<groupId>com.googlecode.maven-download-plugin</groupId>
<artifactId>download-maven-plugin</artifactId>
<version>${download-plugin.version}</version>
<version>${download-maven-plugin.version}</version>
<executions>
<!-- TODO eventually replace these with the archetype versions -->
<execution>
@@ -60,7 +60,7 @@
</activation>
<properties>
<!-- versions -->
<download-plugin.version>1.13.0</download-plugin.version>
<download-maven-plugin.version>@download-maven-plugin.version@</download-maven-plugin.version>
</properties>
</profile>
</profiles>
+43 -3
View File
@@ -43,8 +43,46 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<tiles-maven-plugin.version>2.40</tiles-maven-plugin.version>
<archetype-packaging.version>3.1.1</archetype-packaging.version>
<!-- native plugin versions -->
<!-- see versions: https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-clean-plugin -->
<maven-clean-plugin.version>3.5.0</maven-clean-plugin.version>
<!-- see versions: https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-dependency-plugin -->
<maven-dependency-plugin.version>3.11.0</maven-dependency-plugin.version>
<!-- see versions: https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-resources-plugin -->
<maven-resources-plugin.version>3.5.0</maven-resources-plugin.version>
<!-- see versions: https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-jar-plugin -->
<maven-jar-plugin.version>3.5.1</maven-jar-plugin.version>
<!-- see versions: https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-war-plugin -->
<maven-war-plugin.version>3.5.1</maven-war-plugin.version>
<!-- see versions: https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-javadoc-plugin -->
<maven-javadoc-plugin.version>3.12.0</maven-javadoc-plugin.version>
<!-- see versions: https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-shade-plugin -->
<maven-shade-plugin.version>3.6.2</maven-shade-plugin.version>
<!-- see versions: https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-install-plugin -->
<maven-install-plugin.version>3.1.4</maven-install-plugin.version>
<!-- see versions: https://mvnrepository.com/artifact/org.apache.maven.archetype/archetype-packaging -->
<archetype-packaging.version>3.4.1</archetype-packaging.version>
<!-- other common plugin versions -->
<!-- see versions: https://mvnrepository.com/artifact/org.codehaus.mojo/build-helper-maven-plugin -->
<build-helper-maven-plugin.version>3.6.1</build-helper-maven-plugin.version>
<!-- see versions: https://mvnrepository.com/artifact/com.googlecode.maven-download-plugin/download-maven-plugin -->
<download-maven-plugin.version>1.13.0</download-maven-plugin.version>
<!-- inteligr8 plugins -->
<!-- see versions: https://mvnrepository.com/artifact/com.inteligr8/regex-maven-plugin -->
<regex-maven-plugin.version>1.0.7</regex-maven-plugin.version>
<!-- see versions: https://mvnrepository.com/artifact/com.inteligr8/conditional-maven-plugin -->
<conditional-maven-plugin.version>1.0.2</conditional-maven-plugin.version>
<!-- other uncommon plugins -->
<!-- see versions: https://mvnrepository.com/artifact/io.repaint.maven/tiles-maven-plugin -->
<tiles-maven-plugin.version>2.45</tiles-maven-plugin.version>
<!-- see versions: https://mvnrepository.com/artifact/org.codehaus.mojo/flatten-maven-plugin -->
<flatten-maven-plugin.version>1.8.0</flatten-maven-plugin.version>
<!-- other versions -->
<spring-boot.version>3.5.7</spring-boot.version>
</properties>
<build>
@@ -110,6 +148,9 @@
<module>beedk-acs-platform-webapp-tile</module>
<module>beedk-acs-share-webapp-tile</module>
<module>beedk-activiti-ext-tile</module>
<module>beedk-aps-ext-tile</module>
<module>beedk-ate-springboot</module>
<module>beedk-ate-springboot-test</module>
<module>beedk-ate-springboot-tile</module>
@@ -125,7 +166,6 @@
<module>beedk-acs-share-module-archetype</module>
<module>beedk-ate-archetype</module>
<module>beedk-acs-allinone-archetype</module>
<module>beedk-springboot-api-archetype</module>
<module>beedk-activiti-ext-archetype</module>
<module>beedk-aps-ext-archetype</module>
</modules>