fixed activiti archetype
This commit is contained in:
parent
df89b65373
commit
d80c6b9400
@ -1,31 +1,31 @@
|
|||||||
package ${package};
|
package ${package};
|
||||||
|
|
||||||
import org.activiti.engine.delegate.DelegateExecution;
|
import org.activiti.engine.delegate.DelegateExecution;
|
||||||
import org.activiti.engine.delegate.ExecutionListener;
|
import org.activiti.engine.delegate.ExecutionListener;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
import org.springframework.stereotype.Component;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This class is an example of how you can implement an Activiti Execution Listener.
|
* This class is an example of how you can implement an Activiti Execution Listener.
|
||||||
* You can reference it in your BPMN with:
|
* You can reference it in your BPMN with:
|
||||||
* <activiti:executionListener delegateExpression="${exampleExecutionListener}" event="start" />
|
* <activiti:executionListener delegateExpression="${exampleExecutionListener}" event="start" />
|
||||||
* <activiti:executionListener expression="${exampleExecutionListener.exampleMethod('example parameter')}" event="end" />
|
* <activiti:executionListener expression="${exampleExecutionListener.exampleMethod('example parameter')}" event="end" />
|
||||||
*/
|
*/
|
||||||
@Component("exampleExecutionListener")
|
@Component("exampleExecutionListener")
|
||||||
public class ExampleExecutionListener implements ExecutionListener {
|
public class ExampleExecutionListener implements ExecutionListener {
|
||||||
|
|
||||||
private final Logger logger = LoggerFactory.getLogger(this.getClass());
|
private final Logger logger = LoggerFactory.getLogger(this.getClass());
|
||||||
|
|
||||||
public void notify(DelegateExecution execution) throws Exception {
|
public void notify(DelegateExecution execution) throws Exception {
|
||||||
if (this.logger.isTraceEnabled())
|
if (this.logger.isTraceEnabled())
|
||||||
this.logger.trace("execute('" + execution.getId() + "')");
|
this.logger.trace("execute('" + execution.getId() + "')");
|
||||||
|
|
||||||
// TODO do some stuff
|
// TODO do some stuff
|
||||||
}
|
}
|
||||||
|
|
||||||
public void exampleMethod(String param) throws Exception {
|
public void exampleMethod(String param) throws Exception {
|
||||||
// another example
|
// another example
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,31 +1,31 @@
|
|||||||
package ${package};
|
package ${package};
|
||||||
|
|
||||||
import org.activiti.engine.delegate.DelegateExecution;
|
import org.activiti.engine.delegate.DelegateExecution;
|
||||||
import org.activiti.engine.delegate.JavaDelegate;
|
import org.activiti.engine.delegate.JavaDelegate;
|
||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
import org.springframework.stereotype.Component;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This class is an example of how you can implement an Activiti Service Task.
|
* This class is an example of how you can implement an Activiti Service Task.
|
||||||
* You can reference it in your BPMN with:
|
* You can reference it in your BPMN with:
|
||||||
* <serviceTask id="serviceTask" activiti:delegateExpression="${exampleServiceTask}" />
|
* <serviceTask id="serviceTask" activiti:delegateExpression="${exampleServiceTask}" />
|
||||||
* <serviceTask id="serviceTask" activiti:expression="${exampleServiceTask.exampleMethod('example parameter')}" />
|
* <serviceTask id="serviceTask" activiti:expression="${exampleServiceTask.exampleMethod('example parameter')}" />
|
||||||
*/
|
*/
|
||||||
@Component("exampleServiceTask")
|
@Component("exampleServiceTask")
|
||||||
public class ExampleServiceTask implements JavaDelegate {
|
public class ExampleServiceTask implements JavaDelegate {
|
||||||
|
|
||||||
private final Logger logger = LoggerFactory.getLogger(this.getClass());
|
private final Logger logger = LoggerFactory.getLogger(this.getClass());
|
||||||
|
|
||||||
public void execute(DelegateExecution execution) throws Exception {
|
public void execute(DelegateExecution execution) throws Exception {
|
||||||
if (this.logger.isTraceEnabled())
|
if (this.logger.isTraceEnabled())
|
||||||
this.logger.trace("execute('" + execution.getId() + "')");
|
this.logger.trace("execute('" + execution.getId() + "')");
|
||||||
|
|
||||||
// TODO do some stuff
|
// TODO do some stuff
|
||||||
}
|
}
|
||||||
|
|
||||||
public void exampleMethod(String param) throws Exception {
|
public void exampleMethod(String param) throws Exception {
|
||||||
// another example
|
// another example
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
package com.activiti.extension.conf;
|
package com.activiti.extension.conf;
|
||||||
|
|
||||||
import org.springframework.context.annotation.ComponentScan;
|
import org.springframework.context.annotation.ComponentScan;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
|
|
||||||
@Configuration
|
@Configuration
|
||||||
@ComponentScan(basePackages = {"${package}"})
|
@ComponentScan(basePackages = {"${package}"})
|
||||||
public class ${shortname}SpringComponentScanner {
|
public class ${shortname}SpringComponentScanner {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,46 +1,46 @@
|
|||||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
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">
|
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>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
<groupId>${groupId}</groupId>
|
<groupId>${groupId}</groupId>
|
||||||
<artifactId>${artifactId}</artifactId>
|
<artifactId>${artifactId}</artifactId>
|
||||||
<version>${version}</version>
|
<version>${version}</version>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
<name>${shortname}</name>
|
<name>${shortname}</name>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
<maven.release.source>11</maven.release.source>
|
<maven.release.source>11</maven.release.source>
|
||||||
<alfresco.sdk.version>5.0.0</alfresco.sdk.version>
|
<alfresco.sdk.version>5.0.0</alfresco.sdk.version>
|
||||||
|
|
||||||
<!-- for RAD environment -->
|
<!-- for RAD environment -->
|
||||||
<edition>community</edition>
|
<edition>community</edition>
|
||||||
<alfresco.platform.version>6.2.0-ga</alfresco.platform.version>
|
<alfresco.platform.version>6.2.0-ga</alfresco.platform.version>
|
||||||
|
|
||||||
<!-- for Docker deployment -->
|
<!-- for Docker deployment -->
|
||||||
<docker.image.registry>${dockerRegistryHost}</docker.image.registry>
|
<docker.image.registry>${dockerRegistryHost}</docker.image.registry>
|
||||||
<docker.image.name>${dockerImagePrefix}/${project.artifactId}</docker.image.name>
|
<docker.image.name>${dockerImagePrefix}/${project.artifactId}</docker.image.name>
|
||||||
<docker.image.tag>${project.version}</docker.image.tag>
|
<docker.image.tag>${project.version}</docker.image.tag>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<!-- Optional; use for REST API access -->
|
<!-- Optional; use for REST API access -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.alfresco</groupId>
|
<groupId>org.alfresco</groupId>
|
||||||
<artifactId>alfresco-java-rest-api-spring-boot-starter</artifactId>
|
<artifactId>alfresco-java-rest-api-spring-boot-starter</artifactId>
|
||||||
<version>${alfresco.sdk.version}</version>
|
<version>${alfresco.sdk.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<!-- Optional; use for Event API access -->
|
<!-- Optional; use for Event API access -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.alfresco</groupId>
|
<groupId>org.alfresco</groupId>
|
||||||
<artifactId>alfresco-java-event-api-spring-boot-starter</artifactId>
|
<artifactId>alfresco-java-event-api-spring-boot-starter</artifactId>
|
||||||
<version>${alfresco.sdk.version}</version>
|
<version>${alfresco.sdk.version}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
<build>
|
<build>
|
||||||
<plugins>
|
<plugins>
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>io.repaint.maven</groupId>
|
<groupId>io.repaint.maven</groupId>
|
||||||
@ -49,31 +49,31 @@
|
|||||||
<extensions>true</extensions>
|
<extensions>true</extensions>
|
||||||
<configuration>
|
<configuration>
|
||||||
<tiles>
|
<tiles>
|
||||||
<!-- Documentation: https://bitbucket.org/inteligr8/ootbee-beedk/src/stable/beedk-acs-platform-artifact-rad-tile -->
|
<!-- Documentation: https://bitbucket.org/inteligr8/ootbee-beedk/src/stable/beedk-acs-platform-artifact-rad-tile -->
|
||||||
<tile>com.inteligr8.ootbee:beedk-acs-platform-artifact-rad-tile:${beedkVersion}</tile>
|
<tile>com.inteligr8.ootbee:beedk-acs-platform-artifact-rad-tile:${beedkVersion}</tile>
|
||||||
<!-- Documentation: https://bitbucket.org/inteligr8/ootbee-beedk/src/stable/beedk-springboot-docker-tile -->
|
<!-- Documentation: https://bitbucket.org/inteligr8/ootbee-beedk/src/stable/beedk-springboot-docker-tile -->
|
||||||
<tile>com.inteligr8.ootbee:beedk-springboot-docker-tile:${beedkVersion}</tile>
|
<tile>com.inteligr8.ootbee:beedk-springboot-docker-tile:${beedkVersion}</tile>
|
||||||
</tiles>
|
</tiles>
|
||||||
</configuration>
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
|
|
||||||
<repositories>
|
<repositories>
|
||||||
<repository>
|
<repository>
|
||||||
<id>inteligr8-releases</id>
|
<id>inteligr8-releases</id>
|
||||||
<url>http://repos.inteligr8.com/nexus/repository/inteligr8-public</url>
|
<url>http://repos.inteligr8.com/nexus/repository/inteligr8-public</url>
|
||||||
</repository>
|
</repository>
|
||||||
<repository>
|
<repository>
|
||||||
<id>alfresco-public</id>
|
<id>alfresco-public</id>
|
||||||
<url>https://artifacts.alfresco.com/nexus/content/groups/public</url>
|
<url>https://artifacts.alfresco.com/nexus/content/groups/public</url>
|
||||||
</repository>
|
</repository>
|
||||||
</repositories>
|
</repositories>
|
||||||
|
|
||||||
<pluginRepositories>
|
<pluginRepositories>
|
||||||
<pluginRepository>
|
<pluginRepository>
|
||||||
<id>inteligr8-releases</id>
|
<id>inteligr8-releases</id>
|
||||||
<url>http://repos.inteligr8.com/nexus/repository/inteligr8-public</url>
|
<url>http://repos.inteligr8.com/nexus/repository/inteligr8-public</url>
|
||||||
</pluginRepository>
|
</pluginRepository>
|
||||||
</pluginRepositories>
|
</pluginRepositories>
|
||||||
</project>
|
</project>
|
@ -1,26 +1,26 @@
|
|||||||
|
|
||||||
FROM docker.inteligr8.com/inteligr8/ubuntu-jdk:20.04-11
|
FROM docker.inteligr8.com/inteligr8/ubuntu-jdk:20.04-11
|
||||||
|
|
||||||
# Set default user information
|
# Set default user information
|
||||||
ARG JAR_FILE=target/${env.project_artifactId}-${env.project_version}.jar
|
ARG JAR_FILE=target/${env.project_artifactId}-${env.project_version}.jar
|
||||||
ARG APPGROUPNAME=alfresco
|
ARG APPGROUPNAME=alfresco
|
||||||
ARG APPGROUPID=1000
|
ARG APPGROUPID=1000
|
||||||
ARG APPUSERNAME=atengine
|
ARG APPUSERNAME=atengine
|
||||||
ARG APPUSERID=33001
|
ARG APPUSERID=33001
|
||||||
|
|
||||||
ENV JAVA_OPTS="-Xmx128m"
|
ENV JAVA_OPTS="-Xmx128m"
|
||||||
ENV JAR_PATH=/usr/local/bin/${env.project_artifactId}-${env.project_version}.jar
|
ENV JAR_PATH=/usr/local/bin/${env.project_artifactId}-${env.project_version}.jar
|
||||||
|
|
||||||
COPY ${JAR_FILE} ${JAR_PATH}
|
COPY ${JAR_FILE} ${JAR_PATH}
|
||||||
|
|
||||||
# Install your engine's dependencies here
|
# Install your engine's dependencies here
|
||||||
#RUN apt update && \
|
#RUN apt update && \
|
||||||
# apt -y install {dependency names in APT repository}
|
# apt -y install {dependency names in APT repository}
|
||||||
|
|
||||||
RUN groupadd -g ${APPGROUPID} ${APPGROUPNAME} && \
|
RUN groupadd -g ${APPGROUPID} ${APPGROUPNAME} && \
|
||||||
useradd -u ${APPUSERID} -G ${APPGROUPNAME} ${APPUSERNAME} && \
|
useradd -u ${APPUSERID} -G ${APPGROUPNAME} ${APPUSERNAME} && \
|
||||||
chown ${APPUSERNAME}:${APPGROUPNAME} ${JAR_PATH}
|
chown ${APPUSERNAME}:${APPGROUPNAME} ${JAR_PATH}
|
||||||
|
|
||||||
USER ${APPUSERNAME}
|
USER ${APPUSERNAME}
|
||||||
|
|
||||||
ENTRYPOINT java ${JAVA_OPTS} -jar ${JAR_PATH}
|
ENTRYPOINT java ${JAVA_OPTS} -jar ${JAR_PATH}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user