Skip to main content

Detailed Installation for dedicated content rendition service

This document describes the steps required to run one or more dedicated 'content renditions nodes'. In this context, such a 'node' is a Flowable instance which is configured for a single purpose: generating document renditions and content transformations. By splitting off this heavy processing to dedicated servers, the impact on regular operations such as process or case executions is removed. This can be useful or needed when there are a lot of documents being used. For example, generating PDF renditions of large Word documents is known to be a resource-intensive operation.

We recommend to build a custom Spring Boot application using a subset of the Flowable dependencies.

The Work Prerequisites are also valid for the standalone content rendition nodes. The only difference is that for the nodes running only the content rendition generation no Elasticsearch is needed and a different CPU / Memory requirements might be needed. The CPU and Memory requirements are highly dependent on the amount and type of content that is being generated.

Disable content rendition generation

When using a dedicated content rendition service, the content rendition generation on the main Flowable Work application needs to be disabled, as it will be handled by the dedicated node(s). This can be done by setting the following property in your Flowable Work installation:

flowable.content.async-executor-activate=false

This property will make sure that content rendition jobs are created on the Flowable Work instances (since content items are created there), but the generation of the rendition content will not happen on those instances.

Step-by-Step Installation

In these sections we are going to explain how to create a dedicated service for content rendition.

Create Spring Boot Application

A custom application can be created using the Spring Boot Initializer. In there, you will need to pick the database you want to use and the JDBC starter dependency.

A minimum configuration can be done using this link (adapt the Spring Boot and Java version appropriately)

Use this for 3.13 or earlier
In the main application class (the class annotated with @SpringBootApplication), replace the @SpringBootApplication> with
@SpringBootApplication(exclude = {
PlatformLicenseAutoConfiguration.class,
SubFolderItemMigrationConfiguration.class,
PlatformContentEngineServicesAutoConfiguration.class,
})

Flowable Dependencies

We are going to add the Flowable Platform BOM to the dependency management section of the pom.xml:

 <dependencyManagement>
<dependencies>
<dependency>
<groupId>com.flowable</groupId>
<artifactId>flowable-platform-bom</artifactId>
<version>${com.flowable.platform.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>

Next we will add the following flowable dependency:

<dependency>
<groupId>com.flowable.platform</groupId>
<artifactId>flowable-spring-boot-starter-content</artifactId>
</dependency>
Use this for 3.13 or earlier

<dependency>
<groupId>com.flowable.platform</groupId>
<artifactId>flowable-platform-autoconfigure</artifactId>
</dependency>
<dependency>
<groupId>org.flowable</groupId>
<artifactId>flowable-job-spring-service</artifactId>
</dependency>
<dependency>
<groupId>com.flowable.core</groupId>
<artifactId>flowable-content-spring</artifactId>
</dependency>
<dependency>
<groupId>com.flowable.platform</groupId>
<artifactId>flowable-platform-rendition-converter</artifactId>
</dependency>

Custom Properties

Only relevant for 3.13 or earlier

In the application.properties set the following properties:

flowable.content.async.executor.timer-job-acquisition-enabled=false
flowable.custom-mybatis-x-m-l-mappers=org/flowable/job/service/db/mapping/entity/SuspendedJob.xml,org/flowable/job/service/db/mapping/entity/ExternalWorkerJob.xml,org/flowable/job/service/db/mapping/entity/TimerJob.xml

Database

The database properties need to be configured to point to the same database as your Flowable instance. See Flowable Database Configuration

Content storage

The configuration for the content storage should be the same as your Flowable instance, as the dedicated node needs to be able to read the content. For example, if you are using database storage in Flowable, you need to configure this dedicated service using the same properties. If you are using some custom content storage, you'll have to make sure that this service is also configured to use the same custom content storage. See Flowable Content Storage Configuration for more details.

Once all of this is configured you can start the application.

Async Executor Configuration

These settings allow to tweak the amount of threads available to the asynchronous generation of renditions.

flowable.content.async-executor.core-pool-size=16
flowable.content.async-executor.max-pool-size=16
flowable.content.async-executor.queue-capacity=2048
Use for 3.13 or earlier

In 3.13 or earlier the properties were not exposed and the same could be achieved by writing a custom engine configuration configurer. Currently, the configuration for the content async executor is not exposed through properties. These settings allow to tweak the amount of threads available to the asynchronous generation of renditions. If you need to increase it you'll need to write a custom engine configuration configurer:

@Bean
public EngineConfigurationConfigurer<SpringContentEngineConfiguration> customContentEngineConfigurer() {
return engineConfiguration -> {
engineConfiguration.setAsyncExecutorCorePoolSize(16);
engineConfiguration.setAsyncExecutorMaxPoolSize(16);
};
}

We advise using the same value for the core and max pool size. You can adjust the amount according to your own needs.

Disclaimer

The above sections describe the steps needed to run one or more dedicated nodes for handling the content rendition and have been tested with Flowable 3.14.x. For 3.13 see the relevant sections.

These steps can change in the future, or we can simplify things. This document will be updated in the future accordingly.