ACS-12413 : enable deferred pre-commit hooks and normalize repo (#1333)

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
Dhaval Patel
2026-08-12 09:49:11 +05:30
committed by GitHub
co-authored by Copilot Autofix powered by AI
parent eeabc8b858
commit 5b03dc315e
87 changed files with 622 additions and 540 deletions
+21
View File
@@ -0,0 +1,21 @@
# Normalize line endings: Git stores text as LF and checks out LF on every platform.
# Enforcing eol=lf keeps the working tree consistent and makes tools that honour
# git attributes (e.g. Spotless) emit LF, so the mixed-line-ending hook stays stable.
* text=auto eol=lf
# Windows batch files must stay CRLF.
*.bat text eol=crlf
*.cmd text eol=crlf
# Byte-exact test fixtures: never normalize (mirrors the pre-commit excludes).
**/src/test/resources/** -text
# Binary assets / test fixtures — never normalize or diff as text.
*.key binary
*.z binary
*.gz binary
*.jar binary
*.vsd binary
*.vdx binary
*.xbm binary
*.xpm binary
+2 -1
View File
@@ -38,9 +38,11 @@ and one per engine (e.g. `imagemagick`, `libreoffice`, `misc`, `pdf-renderer`, `
## Build & test
- Full local build with per-engine Docker images and integration setup:
```bash
mvn clean install -Plocal,docker-it-setup
```
- Base libraries only: `mvn clean install -Pbase`.
- A single engine locally, mirroring CI: `bash _ci/build.sh <buildProfile>` then
`bash _ci/test.sh <testProfile>` (see the matrix in `.github/workflows/ci.yml`).
@@ -69,4 +71,3 @@ A T-Engine is a Spring Boot app (`org.alfresco.transform.base.Application`):
- Root `pom.xml` for versions, profiles and module wiring.
- `README.md` for a high-level overview and artifact/Docker details.
- `docs/` for transform config, transformer selection, probes and the release process.
+1 -1
View File
@@ -26,4 +26,4 @@ jobs:
maven-args: -Dscopes=compile,runtime
maven-username: ${{ secrets.NEXUS_USERNAME }}
maven-password: ${{ secrets.NEXUS_PASSWORD }}
maven-settings-path: ".ci.settings.xml"
maven-settings-path: ".ci.settings.xml"
+46 -46
View File
@@ -1,46 +1,46 @@
*.class
# Eclipse
.classpath
.settings
.project
# Intellij
.idea/
*.iml
*.iws
# vscode
.vscode
# Mac
.DS_Store
# Maven
target
*.log
*.log.*
# Mobile Tools for Java (J2ME)
.mtj
.tmp/
# Package Files #
*.jar
!quick.jar
*.war
*.ear
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
hs_err_pid*
alf_data
/src/main/resources/alfresco-global.properties
/src/main/resources/alfresco/extension/custom-log4j.properties
libreoffice-dist-*-linux.gz
# Claude Code local artifacts
.claude
*.class
# Eclipse
.classpath
.settings
.project
# Intellij
.idea/
*.iml
*.iws
# vscode
.vscode
# Mac
.DS_Store
# Maven
target
*.log
*.log.*
# Mobile Tools for Java (J2ME)
.mtj
.tmp/
# Package Files #
*.jar
!quick.jar
*.war
*.ear
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
hs_err_pid*
alf_data
/src/main/resources/alfresco-global.properties
/src/main/resources/alfresco/extension/custom-log4j.properties
libreoffice-dist-*-linux.gz
# Claude Code local artifacts
.claude
+41
View File
@@ -0,0 +1,41 @@
# markdownlint configuration
# https://github.com/DavidAnson/markdownlint/blob/main/doc/Rules.md
#
# The mechanical rules (blank lines around headings/lists/fences, hard tabs, bare
# URLs, multiple blank lines, list marker style, …) are left enabled and auto-fixed
# via the `--fix` flag in .pre-commit-config.yaml. The rules below are disabled
# because they are stylistic choices that conflict with the existing docs and would
# require large prose/structure rewrites rather than mechanical fixes.
default: true
# MD013 line-length: docs intentionally use long prose/URLs; wrapping is a style choice.
MD013: false
# MD040 fenced-code-language: many existing code fences omit a language hint.
MD040: false
# MD041 first-line-heading: some docs start with badges/HTML rather than an H1.
MD041: false
# MD033 no-inline-html: docs use inline HTML (e.g. tables, anchors) where needed.
MD033: false
# MD024 no-duplicate-heading: repeated section names (e.g. "Example") are intentional.
MD024: false
# MD036 no-emphasis-as-heading: emphasised captions are used deliberately.
MD036: false
# MD001 heading-increment: some docs skip heading levels for layout reasons.
MD001: false
# MD046 code-block-style: docs mix indented and fenced code blocks.
MD046: false
# MD048 code-fence-style: docs mix tilde and backtick fences.
MD048: false
# MD055 table-pipe-style / MD060 table-column-style: existing wide tables use varied
# pipe spacing and leading-only pipes; enforcing a single style is pure churn.
MD055: false
MD060: false
+30 -13
View File
@@ -10,15 +10,25 @@ repos:
- id: check-json
- id: check-xml
- id: check-merge-conflict
# The mutating whitespace hooks (end-of-file-fixer, trailing-whitespace,
# mixed-line-ending, fix-byte-order-marker) are intentionally deferred:
# enabling them requires a one-off normalization of ~200 existing files.
# Add them in a dedicated cleanup change so this config stays green:
# - id: fix-byte-order-marker
# - id: mixed-line-ending
# args: ['--fix=lf']
# - id: end-of-file-fixer
# - id: trailing-whitespace
# The mutating whitespace hooks are scoped to exclude test-resource fixtures
# and binary assets: those files must stay byte-exact (metadata-extraction
# tests compare their exact content) and pre-commit can misdetect some binaries
# (e.g. *.key) as text. Line endings are additionally governed by .gitattributes.
- id: fix-byte-order-marker
exclude: &fixtures-and-binaries >-
(?x)^(
.*/src/test/resources/.*
|.*/licenses/3rd-party/.*
|engines/libreoffice/src/main/resources/templateProfileDir/.*
|.*\.(key|z|xbm|xpm|vdx|vsd|bin|gz|jar)
)$
- id: mixed-line-ending
args: ['--fix=lf']
exclude: *fixtures-and-binaries
- id: end-of-file-fixer
exclude: *fixtures-and-binaries
- id: trailing-whitespace
exclude: *fixtures-and-binaries
- repo: https://github.com/sirosen/check-jsonschema
rev: 0.37.1
@@ -27,10 +37,17 @@ repos:
- id: check-github-actions
- id: check-github-workflows
# markdownlint is intentionally omitted for now: the existing docs violate ~20
# default rules (line length, heading spacing, etc.). Enable it in a dedicated
# docs-normalization change (add a .markdownlint config + fix the docs) so the
# pre-commit CI gate stays green.
# markdownlint is configured via .markdownlint.yaml at the repo root, which relaxes
# rules that conflict with the existing docs style (line length, table pipe style,
# …). The --fix flag auto-corrects the mechanical issues (blank lines, bare URLs).
- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.47.0
hooks:
- id: markdownlint
args: ['--fix']
# Test-resource markdown files are fixtures (transform inputs) and must stay
# byte-exact, so they are excluded from linting/fixing.
exclude: '.*/src/test/resources/.*'
- repo: https://github.com/rhysd/actionlint
rev: v1.7.12
-1
View File
@@ -1,2 +1 @@
@.github/copilot-instructions.md
+7 -1
View File
@@ -1,25 +1,31 @@
### Contributing
Thanks for your interest in contributing to this project!
The following is a set of guidelines for contributing to this library. Most of them will make the life of the reviewer easier and therefore decrease the time required for the patch be included in the next version.
The project uses [pre-commit](https://pre-commit.com/) to format code (with [Spotless](https://github.com/diffplug/spotless)) and validate license headers. To install the pre-commit hooks then first install pre-commit and then run:
```shell
pre-commit install
```
When you make a commit then these hooks will run and check the modified files. If it makes changes then you can review them and then `git commit` again to accept the changes.
#### Code Quality
This project uses `spotless` that enforces `alfresco-formatter.xml` to ensure code quality.
The code style definition file is taken always form the `master` branch of `alfresco-community-repo`.
All downstream projects use this code style definition file as well.
To check code-style violations you can use:
```bash
mvn spotless:check
```
To reformat files you can use:
```bash
mvn spotless:apply
```
+17 -4
View File
@@ -1,4 +1,5 @@
## Alfresco Transform Core
[![Build Status](https://github.com/Alfresco/alfresco-transform-core/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/Alfresco/alfresco-transform-core/actions/workflows/ci.yml)
Contains the common transformer (T-Engine) code, plus a few implementations.
@@ -16,21 +17,23 @@ have moved. See the [alfresco-transform-model README](https://github.com/Alfresc
[README](https://github.com/Alfresco/alfresco-transform-core/blob/master/engines/base/README.md)
* `engines/<name>` - multiple T-Engines, which extend the `engines/base`; each one builds a SpringBoot jar
and a [Docker image](https://github.com/Alfresco/alfresco-transform-core#docker)
* `deprecated/alfresco-base-t-engine` - The original t-engine base, which may still be used,
* `deprecated/alfresco-transformer-base` - The original t-engine base, which may still be used,
but has been replaced by the simpler `engines/base`.
### Documentation
* `docs` - provides additional documentation.
* [ACS Packaging docs](https://github.com/Alfresco/acs-packaging/tree/master/docs) folder
* If you're interested in the Alfresco Transform Service (ATS) see https://docs.alfresco.com/transform/concepts/transformservice-overview.html
* If you're interested in the Alfresco Transform Service (ATS) see <https://docs.alfresco.com/transform/concepts/transformservice-overview.html>
### Building and testing
The project can be built by running the Maven command:
```bash
mvn clean install -Plocal,docker-it-setup
```
> The `local` Maven profile builds local Docker images for each T-Engine.
## Run in Docker
@@ -46,11 +49,11 @@ docker logs -f <t-engine-project-name>
Since a T-Engine is a Spring Boot application, it might be helpful to run it as such during development by executing
one of the following:
* `mvn spring-boot:run`
* `java -jar target/helloworld-t-engine-{version}.jar` in the project directory.
* Run or debug the application `org.alfresco.transform.base.Application` from within an IDE.
## Test page
The application will be accessible on port 8090 and the test page is: `http://localhost:8090/`.
@@ -59,9 +62,12 @@ The config is available on `http://localhost:8090/transform/config`.
### Artifacts
#### Maven
The artifacts can be obtained by:
* downloading from [Alfresco repository](https://artifacts.alfresco.com/nexus/content/groups/public)
* getting as Maven dependency by adding the dependency to your pom file:
```xml
<dependency>
<groupId>org.alfresco</groupId>
@@ -75,7 +81,9 @@ The artifacts can be obtained by:
<version>version</version>
</dependency>
```
and Alfresco Maven repository:
```xml
<repository>
<id>alfresco-maven-repo</id>
@@ -84,12 +92,15 @@ and Alfresco Maven repository:
```
#### Docker
The core T-Engine images are available on Docker Hub.
The core T-Engine images are available on Docker Hub.
Either as a single Core AIO (All-In-One) T-Engine:
* [alfresco/alfresco-transform-core-aio](https://hub.docker.com/r/alfresco/alfresco-transform-core-aio)
Or as a set of individual T-Engines:
* [alfresco/alfresco-imagemagick](https://hub.docker.com/r/alfresco/alfresco-imagemagick)
* [alfresco/alfresco-pdf-renderer](https://hub.docker.com/r/alfresco/alfresco-pdf-renderer)
* [alfresco/alfresco-libreoffice](https://hub.docker.com/r/alfresco/alfresco-libreoffice)
@@ -97,10 +108,12 @@ Or as a set of individual T-Engines:
* [alfresco/alfresco-transform-misc](https://hub.docker.com/r/alfresco/alfresco-transform-misc)
You can find examples of using Core AIO in the reference ACS Deployment for Docker Compose:
* [ACS Community](https://github.com/Alfresco/acs-deployment/blob/master/docker-compose/community-docker-compose.yml)
* [ACS Enterprise](https://github.com/Alfresco/acs-deployment/blob/master/docker-compose/docker-compose.yml)
You can find examples of using the individual T-Engines in the reference ACS Deployment for Helm / Kubernetes:
* [ACS Community](https://github.com/Alfresco/acs-deployment/blob/master/helm/alfresco-content-services/community_values.yaml)
* [ACS Enterprise](https://github.com/Alfresco/acs-deployment/blob/master/helm/alfresco-content-services/values.yaml)
+23 -21
View File
@@ -45,8 +45,8 @@ src/main/java/org/alfresco/transformer/Application.java
<tr><td><div style="text-align:right">abc:height</div></td><td><input type="text" name="height" value="" /></td></tr>
<tr><td><div style="text-align:right">timeout</div></td><td><input type="text" name="timeout" value="" /></td></tr>
<tr><td></td><td><input type="submit" value="Transform" /></td></tr>
</table>
</form>
</table>
</form>
</div>
<div>
<a href="/log">Log entries</a>
@@ -114,6 +114,7 @@ public class TransformerNameController extends TransformController
* *TransformerName*Executer.java - *JavaExecutor* and *CommandExecutor* sub classes need to extract values from
*transformOptions* and use them in a call to an external process or as parameters to a library call.
~~~
...
public class TransformerNameExecutor extends AbstractCommandExecutor
@@ -157,30 +158,32 @@ public class Application
~~~
Transform requests are handled by the *TransformController*, but are either:
* POST requests (a direct http request from a client) where the transform options are passed as parameters, the source is supplied as a multipart file and
* POST requests (a direct http request from a client) where the transform options are passed as parameters, the source is supplied as a multipart file and
the response is a file download.
* POST request (a request via a message queue) where the transform options are supplied as JSON and the response is also JSON.
* POST request (a request via a message queue) where the transform options are supplied as JSON and the response is also JSON.
The source and target content is read from a location accessible to both the client and the transfomer.
**Example JSON request body**
```javascript
var transformRequest = {
"requestId": "1",
"sourceReference": "2f9ed237-c734-4366-8c8b-6001819169a4",
"sourceMediaType": "application/pdf",
"sourceSize": 123456,
"sourceExtension": "pdf",
"targetMediaType": "text/plain",
"targetExtension": "txt",
"clientType": "ACS",
"clientData": "Yo No Soy Marinero, Soy Capitan, Soy Capitan!",
"schema": 1,
"transformRequestOptions": {
"targetMimetype": "text/plain",
"targetEncoding": "UTF-8",
"abc:width": "120",
"abc:height": "200"
}
"requestId": "1",
"sourceReference": "2f9ed237-c734-4366-8c8b-6001819169a4",
"sourceMediaType": "application/pdf",
"sourceSize": 123456,
"sourceExtension": "pdf",
"targetMediaType": "text/plain",
"targetExtension": "txt",
"clientType": "ACS",
"clientData": "Yo No Soy Marinero, Soy Capitan, Soy Capitan!",
"schema": 1,
"transformRequestOptions": {
"targetMimetype": "text/plain",
"targetEncoding": "UTF-8",
"abc:width": "120",
"abc:height": "200"
}
}
```
@@ -237,4 +240,3 @@ The build plan is available in [GitHub Actions CI](https://github.com/Alfresco/a
Please use [this guide](https://github.com/Alfresco/alfresco-repository/blob/master/CONTRIBUTING.md)
to make a contribution to the project.
@@ -61,7 +61,7 @@ import org.slf4j.LoggerFactory;
* Use the {@link #setProcessDirectory(String) processDirectory} property to change the default location from which the command executes. The process's environment can be configured using the {@link #setProcessProperties(Map) processProperties} property.
* <p>
* Commands may use placeholders, e.g.
*
*
* <pre>
* <code>
* find
@@ -69,27 +69,27 @@ import org.slf4j.LoggerFactory;
* ${filename}
* </code>
* </pre>
*
*
* The <b>filename</b> property will be substituted for any supplied value prior to each execution of the command. Currently, no checks are made to get or check the properties contained within the command string. It is up to the client code to dynamically extract the properties required if the required properties are not known up front.
* <p>
* Sometimes, a variable may contain several arguments. . In this case, the arguments need to be tokenized using a standard <tt>StringTokenizer</tt>. To force tokenization of a value, use:
*
*
* <pre>
* <code>
* SPLIT:${userArgs}
* </code>
* </pre>
*
*
* You should not use this just to split up arguments that are known to require tokenization up front. The <b>SPLIT:</b> directive works for the entire argument and will not do anything if it is not at the beginning of the argument. Do not use <b>SPLIT:</b> to break up arguments that are fixed, so avoid doing this:
*
*
* <pre>
* <code>
* SPLIT:ls -lih
* </code>
* </pre>
*
*
* Instead, break the command up explicitly:
*
*
* <pre>
* <code>
* ls
@@ -76,7 +76,7 @@ import org.slf4j.Logger;
* If a transform specifies that it can convert from {@code "<MIMETYPE>"} to {@code "alfresco-metadata-embed"}, it is indicating that it can embed metadata in {@code <MIMETYPE>}.
*
* The transform results in a new version of supplied source file that contains the metadata supplied in the transform options.
*
*
* @author Jesper Steen Møller
* @author Derek Hulley
* @author adavis
@@ -197,7 +197,7 @@ public abstract class AbstractMetadataExtractor
* Based on AbstractMappingMetadataExtracter#getDefaultMapping.
*
* This method provides a <i>mapping</i> of where to store the values extracted from the documents. The list of properties need <b>not</b> include all metadata values extracted from the document. This mapping should be defined in a file based on the class name: {@code "<classname>_metadata_extract.properties"}
*
*
* @return Returns a static mapping. It may not be null.
*/
private Map<String, Set<String>> buildExtractMapping()
@@ -250,7 +250,7 @@ public abstract class AbstractMetadataExtractor
* This method provides a <i>mapping</i> of model properties that should be embedded in the content. The list of properties need <b>not</b> include all properties. This mapping should be defined in a file based on the class name: {@code "<classname>_metadata_embed.properties"}
* <p>
* If no {@code "<classname>_metadata_embed.properties"} file is found, a reverse of the {@code "<classname>_metadata_extract.properties"} will be assumed. A last win approach will be used for handling duplicates.
*
*
* @return Returns a static mapping. It may not be null.
*/
private Map<String, Set<String>> buildEmbedMapping()
@@ -58,4 +58,3 @@ management:
container:
name: ${HOSTNAME:t-engine}
@@ -58,17 +58,17 @@ import org.springframework.http.ResponseEntity;
* <li>Provide expected json files (&lt;sourceFilename>"_metadata.json") as resources on the classpath.</li>
* <li>Override the method {@code testTransformation(TestFileInfo testFileInfo)} such that it calls the super method as a {@code @ParameterizedTest} for example:</li>
* </ul>
*
*
* <pre>
* &#64;ParameterizedTest
*
*
* &#64;MethodSource("engineTransformations")
*
*
* &#64;Override
* public void testTransformation(TestFileInfo testFileInfo)
*
* {
*
* {
* super.testTransformation(TestFileInfo testFileInfo)
* }
* </pre>
+5 -5
View File
@@ -1,12 +1,12 @@
# Transformer k8s liveness and readiness probes
>**Note:** The transform-specific liveness probes are currently disabled by default in the
Alfresco Docker Transformers **2.0.0-RC3** release. They can be enabled through the
>**Note:** The transform-specific liveness probes are currently disabled by default in the
Alfresco Docker Transformers **2.0.0-RC3** release. They can be enabled through the
"**livenessTransformEnabled**" environment variable.
>
> The T-Engine liveness probes will be reevaluated/changed/improved as part of the ATS-138 story.
>
> Without the transform-specific liveness probees, calls to the "/live" endpoint of the
> Without the transform-specific liveness probees, calls to the "/live" endpoint of the
T-Engines only check if the JVM is alive.
The transformer's liveness and readiness probes perform small test transformations to check that a pod has fully started up and that it is still healthy.
@@ -17,6 +17,7 @@ The liveness probe gathers the average time of 5 test transformation after start
Environment variables
### Configuration
The actions of the probes are controlled by environment variables
livenessPercent - The percentage slower the small test transform must be to indicate there is a problem. Generally
@@ -45,7 +46,6 @@ The rate and frequency of the probes are controlled by standard k8s fields. See
failureThreshold - set to 1 in the case of the liveness probe, so that any failure terminates the pod sright away.
In the case of readiness probe this is left as the default 3, to give the pod a chance to start.
## Helm chart use of these variables and fields
#### Values.yaml
@@ -112,4 +112,4 @@ data:
maxTransforms: "{{ .Values.imagemagick.livenessProbe.maxTransforms }}"
maxTransformSeconds: "{{ .Values.imagemagick.livenessProbe.maxTransformSeconds }}"
~~~
~~~
+24 -19
View File
@@ -1,9 +1,10 @@
# Build
The `alfresco-transform-core` project uses _GitHub Actions CI_. \
The `ci.yml` config file can be found in the `.github/workflows` directory of the project.
## Stages and Jobs
1. **Build**: Java build with unit and integration tests.
2. **Release**: Release with artifact deployment to Nexus, DockerHub and Quay.io.
@@ -14,49 +15,55 @@ The `ci.yml` config file can be found in the `.github/workflows` directory of th
> `maven-release-plugin`). The release and next development versions are provided explicitly
> (see the _Release process steps_ below), which avoids the SemVer auto-increment issue.
## Branches
GitHub Actions CI builds differ by branch:
* `master` / `SP/*` / `HF/*` branches:
- regular builds which include the _Build_ stage;
> On the `master` branch only the _Build_ stage updates the `latest` T-Engines images on
* regular builds which include the _Build_ stage;
> On the `master` branch only the _Build_ stage updates the `latest` T-Engines images on
> both Quay and DockerHub:
> - alfresco/alfresco-pdf-renderer
> - alfresco/alfresco-imagemagick
> - alfresco/alfresco-tika
> - alfresco/alfresco-libreoffice
> - alfresco/alfresco-transform-misc
> - alfresco/alfresco-transform-core-aio
- if the commit message contains the `[release]` tag, the builds will also
include the _Release_ stage;
> * alfresco/alfresco-pdf-renderer
> * alfresco/alfresco-imagemagick
> * alfresco/alfresco-tika
> * alfresco/alfresco-libreoffice
> * alfresco/alfresco-transform-misc
> * alfresco/alfresco-transform-core-aio
* if the commit message contains the `[release]` tag, the builds will also
include the _Release_ stage;
* `ATS-*` / `ACS-*` branches:
- regular builds which include only the _Build_ and _Tests_ stages;
* regular builds which include only the _Build_ and _Tests_ stages;
All other branches are ignored.
## Release process steps & info
Prerequisites:
- the `master` / `SP/*` / `HF/*` branch is green and it contains all the changes that should be
* the `master` / `SP/*` / `HF/*` branch is green and it contains all the changes that should be
included in the next release.
- the repository has the GitHub App configured for verified releases: the
* the repository has the GitHub App configured for verified releases: the
`GH_APP_ENGINEERING_CONTRIB_CLIENT_ID` variable and `GH_APP_ENGINEERING_CONTRIB_PRIVATE_KEY`
secret are available, and the App is installed with `contents: write` permission.
Steps:
1. Create a new branch with the name `ATS-###_release_version` from the `master` / `SP/*`/ `HF/*`
branch.
2. Set the release and next development versions in the `env` block of
`.github/workflows/ci.yml`:
```yaml
RELEASE_VERSION: "5.4.5-A.1" # the version of the release (git tag)
DEVELOPMENT_VERSION: "5.4.5-A.2-SNAPSHOT" # the version set in the POMs after the release
```
> The `maven-release-slim` action sets `RELEASE_VERSION` in every `pom.xml`, deploys the
> artifacts, creates the verified tag, then sets `DEVELOPMENT_VERSION` for the next iteration
> - all as verified commits.
> * all as verified commits.
3. Create a new commit with the `[release]` tag in its message. The version changes from step (2)
can be included in this same commit - e.g.
```bash
git commit -am "ATS-###: Release T-Core (T-Engines) 5.4.5-A.1 [release]"
```
@@ -70,5 +77,3 @@ Steps:
need to ensure that the _commit message_ contains the `[release]` tag (sub-string).
6. After the _Release_ stage completes, verify in GitHub that the release commits and the new tag
are marked as **Verified**.
+13 -8
View File
@@ -5,6 +5,7 @@ In order to configure an external property it needs to be set as ENV property.
The following externalized T-engines properties are available:
## Tika
| Property | Description | Default value |
|----------|------------------------------------------------------------------------------------------------------|---------------|
| SERVER_PORT | T-Engine Port. | 8090 |
@@ -13,13 +14,13 @@ The following externalized T-engines properties are available:
| ACTIVEMQ_USER | ActiveMQ User. | admin |
| ACTIVEMQ_PASSWORD | ActiveMQ Password. | admin |
| ACTIVEMQ_URL_PARAMS | ActiveMQ connection options. | ?jms.watchTopicAdvisories=false |
| FILE_STORE_URL | T-Engine Port. | http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file |
| FILE_STORE_URL | T-Engine Port. | <http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file> |
| TEST_ENDPOINT_ENABLED | Enable /Disable **/test** endpoint | false
| PDFBOX_NOTEXTRACTBOOKMARKS_DEFAULT | The default behaviour for notExtractBookmarksText when this request param is omitted from a request. | false |
| TRANSFORM_ENGINE_REQUEST_QUEUE | T-Engine queue used for receiving async requests. | org.alfresco.transform.engine.tika.acs |
## Pdf-renderer
| Property | Description | Default value |
|----------|-------------|---------------|
| SERVER_PORT | T-Engine Port | 8090 |
@@ -28,12 +29,13 @@ The following externalized T-engines properties are available:
| ACTIVEMQ_USER | ActiveMQ User. | admin |
| ACTIVEMQ_PASSWORD | ActiveMQ Password. | admin |
| ACTIVEMQ_URL_PARAMS | ActiveMQ connection options. | ?jms.watchTopicAdvisories=false |
| FILE_STORE_URL | T-Engine Port. | http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file |
| FILE_STORE_URL | T-Engine Port. | <http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file> |
| TEST_ENDPOINT_ENABLED | Enable /Disable **/test** endpoint | false
| TRANSFORM_ENGINE_REQUEST_QUEUE | T-Engine queue used for async requests. | org.alfresco.transform.engine.alfresco-pdf-renderer.acs |
| PDFRENDERER_EXE | Path to Pdf-renderer EXE. | /usr/bin/alfresco-pdf-renderer |
## Misc
| Property | Description | Default value |
|----------|-------------|---------------|
| SERVER_PORT | T-Engine Port | 8090 |
@@ -42,13 +44,14 @@ The following externalized T-engines properties are available:
| ACTIVEMQ_USER | ActiveMQ User. | admin |
| ACTIVEMQ_PASSWORD | ActiveMQ Password. | admin |
| ACTIVEMQ_URL_PARAMS | ActiveMQ connection options. | ?jms.watchTopicAdvisories=false |
| FILE_STORE_URL | T-Engine Port. | http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file |
| FILE_STORE_URL | T-Engine Port. | <http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file> |
| TEST_ENDPOINT_ENABLED | Enable /Disable **/test** endpoint | false
| TRANSFORM_ENGINE_REQUEST_QUEUE | T-Engine queue used for async requests. | org.alfresco.transform.engine.misc.acs |
| MISC_PDFBOX_DEFAULT_FONT | Default font used by PdfBox | NotoSans-Regular |
| MISC_HTML_COLLAPSE | Html Collasping Option for HTML to TXT transformation | true |
| MISC_HTML_COLLAPSE | Html Collasping Option for HTML to TXT transformation | true |
## Libreoffice
| Property | Description | Default value |
|----------|-------------|--------------------------------------------------------------------------|
| SERVER_PORT | T-Engine Port | 8090 |
@@ -57,7 +60,7 @@ The following externalized T-engines properties are available:
| ACTIVEMQ_USER | ActiveMQ User. | admin |
| ACTIVEMQ_PASSWORD | ActiveMQ Password. | admin |
| ACTIVEMQ_URL_PARAMS | ActiveMQ connection options. | ?jms.watchTopicAdvisories=false |
| FILE_STORE_URL | T-Engine Port. | http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file |
| FILE_STORE_URL | T-Engine Port. | <http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file> |
| TEST_ENDPOINT_ENABLED | Enable /Disable **/test** endpoint | false
| TRANSFORM_ENGINE_REQUEST_QUEUE | T-Engine queue used for async requests. | org.alfresco.transform.engine.libreoffice.acs |
| LIBREOFFICE_HOME | Path to LibreOffice_Home. | /opt/libreoffice7.2 |
@@ -68,6 +71,7 @@ The following externalized T-engines properties are available:
| LIBREOFFICE_IS_ENABLED | Enables Libreoffice executioner. | true |
## Imagemagick
| Property | Description | Default value |
|----------|-----------------------------------------------------------------------|---------------|
| SERVER_PORT | T-Engine Port | 8090 |
@@ -76,7 +80,7 @@ The following externalized T-engines properties are available:
| ACTIVEMQ_USER | ActiveMQ User. | admin |
| ACTIVEMQ_PASSWORD | ActiveMQ Password. | admin |
| ACTIVEMQ_URL_PARAMS | ActiveMQ connection options. | ?jms.watchTopicAdvisories=false |
| FILE_STORE_URL | T-Engine Port. | http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file |
| FILE_STORE_URL | T-Engine Port. | <http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file> |
| TEST_ENDPOINT_ENABLED | Enable /Disable **/test** endpoint | false
| TRANSFORM_ENGINE_REQUEST_QUEUE | T-Engine queue used for async requests. | org.alfresco.transform.engine.imagemagick.acs |
| IMAGEMAGICK_ROOT | Path to Imagemagick Root. | /usr/lib64/ImageMagick-7.0.10 |
@@ -87,6 +91,7 @@ The following externalized T-engines properties are available:
| IMAGEMAGICK_COMMAND_OPTIONS_ENABLED | If set to true, enables usage of deprecated commandOptions parameter. | |
## Core-aio
| Property | Description | Default value |
|----------|-------------|---------------|
| SERVER_PORT | T-Engine Port | 8090 |
@@ -95,7 +100,7 @@ The following externalized T-engines properties are available:
| ACTIVEMQ_USER | ActiveMQ User. | admin |
| ACTIVEMQ_PASSWORD | ActiveMQ Password. | admin |
| ACTIVEMQ_URL_PARAMS | ActiveMQ connection options. | ?jms.watchTopicAdvisories=false |
| FILE_STORE_URL | T-Engine Port. | http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file |
| FILE_STORE_URL | T-Engine Port. | <http://localhost:8099/alfresco/api/-default-/private/sfs/versions/1/file> |
| TEST_ENDPOINT_ENABLED | Enable /Disable **/test** endpoint | false
| PDFBOX_NOTEXTRACTBOOKMARKS_DEFAULT | The default behaviour for notExtractBookmarksText when this request param is omitted from a request. | false |
| TRANSFORM_ENGINE_REQUEST_QUEUE | T-Engine queue used for async requests. | org.alfresco.transform.engine.aio.acs |
+26 -21
View File
@@ -4,6 +4,7 @@ The T-Engine can be scaled both horizontally and vertically. For either approach
at its default value of `jms`. This setting enables the use of a JMS messaging with the ActiveMQ broker.
## Horizontal Scaling
T-Engine is intended to be run as a Docker image. Horizontal Scaling could be achieved through creating multiple Docker containers.
T-Engine relies on JMS queues, which provide built-in load balancing. This design allows you to safely run multiple instances
@@ -11,6 +12,7 @@ of the T-Engine service. Reliable messaging ensures that each message is deliver
messaging, while many consumers may listen on a queue, each message is consumed by only one instance.
### Example
```yaml
transform-core-aio:
image: quay.io/alfresco/alfresco-transform-core-aio:5.1.7
@@ -25,7 +27,9 @@ transform-core-aio:
```
### Scaling of individual T-Engines
There are options to use five separate T-Engines instead of one single `all-in-one` T-Engine. These options are:
1. LibreOffice
2. ImageMagick
3. PdfRenderer
@@ -35,6 +39,7 @@ There are options to use five separate T-Engines instead of one single `all-in-o
Horizontal Scaling could be achieved for these T-Engines as well - by creating multiple Docker containers for each of the T-Engines.
### Example
```yaml
libre-office:
image: quay.io/alfresco/alfresco-libreoffice:5.1.7
@@ -94,23 +99,29 @@ transform-misc:
### Limitations
- Alfresco Content Services (ACS) Repository can only be configured with a single T-Engine service URL.
- Alfresco Content Services (ACS) Repository can only be configured with a single T-Engine service URL.
```
localTransform.core-aio.url=http://transform-core-aio:8090/
```
- T-Router can only be configured with a single T-Engine service URL.
- T-Router can only be configured with a single T-Engine service URL.
```
CORE_AIO_URL: http://transform-core-aio:8090
```
- Search and Search Reindexing has a dependency on a single T-Engine service URL.
- Search and Search Reindexing has a dependency on a single T-Engine service URL.
```
ALFRESCO_ACCEPTED_CONTENT_MEDIA_TYPES_CACHE_BASE_URL: >-
http://transform-core-aio:8090/transform/config
```
- T-Engine depends on ActiveMQ and shared-file-store. When running multiple T-Engine instances (nodes),
- T-Engine depends on ActiveMQ and shared-file-store. When running multiple T-Engine instances (nodes),
same URL for ActiveMQ and shared file store must be provided to all of the T-Engine nodes.
- In Kubernetes environments, horizontal scaling is typically handled automatically via deployments and built-in load balancing.
- In Kubernetes environments, horizontal scaling is typically handled automatically via deployments and built-in load balancing.
In other environments, own load balancer is required in front of T-Engine to distribute requests.
## Vertical Scaling
@@ -119,36 +130,32 @@ Vertical scaling can be achieved through Docker, JVM, Spring Boot, or ActiveMQ c
- **`mem_limit` (Docker):**
Sets the maximum amount of memory the container can use. Increasing this allows the T-Engine to handle more concurrent processing
and larger workloads.
and larger workloads.
**Default:** Not set (unlimited, but typically limited by orchestrator or host).
- **`JAVA_OPTS` (JVM):**
- **`JAVA_OPTS` (JVM):**
Sets Java Virtual Machine options. It is recommended to set JVM memory using `-XX:MinRAMPercentage` and `-XX:MaxRAMPercentage`
in combination with the container's `mem_limit` parameter. This allows the JVM to dynamically adjust its heap size based on
the memory available to the container. This is important for handling more messages or larger payloads.
the memory available to the container. This is important for handling more messages or larger payloads.
**Default:** Not set (JVM uses its own default heap sizing).
- **`SPRING_ACTIVEMQ_POOL_MAXCONNECTIONS` (Spring Boot):**
- **`SPRING_ACTIVEMQ_POOL_MAXCONNECTIONS` (Spring Boot):**
Configures the maximum number of pooled connections to ActiveMQ. Increasing this value allows more simultaneous connections to
the message broker, which can improve throughput under heavy load.
the message broker, which can improve throughput under heavy load.
**Default:** 1 set by Spring Autoconfiguration, 20 set by base engine's application.yaml
- **`JMS_LISTENER_CONCURRENCY` (Spring Boot):**
- **`JMS_LISTENER_CONCURRENCY` (Spring Boot):**
The number of concurrent sessions/consumers to start for each listener. Can either be a simple number indicating the maximum
number (e.g. "5") or a range indicating the lower as well as the upper limit (e.g. "3-5"). Note that a specified minimum is
just a hint and might be ignored at runtime. Default is 1; keep concurrency limited to 1 in case of a topic listener or if queue
ordering is important; consider raising it for general queues. Raising the upper limit allows more messages to be processed in
parallel, increasing throughput.
parallel, increasing throughput.
**Default:** 1 set by Spring Autoconfiguration, 1-10 set by base engine's application.yaml
- **`ACTIVEMQ_URL_PARAMS` with `jms.prefetchPolicy.all` (Spring Boot/ActiveMQ):**
- **`ACTIVEMQ_URL_PARAMS` with `jms.prefetchPolicy.all` (Spring Boot/ActiveMQ):**
Overrides the default ActiveMQ connection options of broker URL by including prefetch policy settings.
It controls how many messages are prefetched from the queue by each consumer before processing. A higher prefetch value can
improve throughput but may increase memory usage. Note that raising this number might lead to starvation of concurrent consumers!
improve throughput but may increase memory usage. Note that raising this number might lead to starvation of concurrent consumers!
**Default:** `?jms.watchTopicAdvisories=false` (prefetch policy default is 1000 for queues)
**Note:** The T-Engines consumers should be considered as slow consumers. Processing each message can take a significant amount of time.
@@ -156,7 +163,6 @@ Vertical scaling can be achieved through Docker, JVM, Spring Boot, or ActiveMQ c
and consumers. The default prefetch size of 1000 messages should be decreased, otherwise a single consumer will fetch all the
messages, and it will lead to performance degradation.
### Comprehensive Example
Below is a single example that combines memory limits, JVM options, concurrency, and message prefetch settings for vertical scaling:
@@ -173,7 +179,7 @@ Below is a single example that combines memory limits, JVM options, concurrency,
FILE_STORE_URL: >-
http://shared-file-store:8099/alfresco/api/-default-/private/sfs/versions/1/file
ACTIVEMQ_URL_PARAMS: ?jms.watchTopicAdvisories=false&jms.prefetchPolicy.all=100 # Decreases the message prefetch
SPRING_ACTIVEMQ_POOL_MAXCONNECTIONS: 100 # Increases the ActiveMQ connection pool
SPRING_ACTIVEMQ_POOL_MAXCONNECTIONS: 100 # Increases the ActiveMQ connection pool
JMS_LISTENER_CONCURRENCY: 1-100 # Increases the JMS listener concurrency
ports:
- "8090:8090"
@@ -185,7 +191,6 @@ Below is a single example that combines memory limits, JVM options, concurrency,
The maximum memory assigned to the container should be carefully decided. It depends on the host machines RAM size, total
memory assigned/required to the other containers (if present) in the same host machine.
- **`JAVA_OPTS` (JVM):**
JVM maximum RAM percentage to 100% of `mem_limit` is not recommended, as this can cause the JVM to use all available
container memory, leaving no room for other processes and potentially leading to container restarts due to out-of-memory (OOM)
+6 -5
View File
@@ -8,6 +8,7 @@ t-config may reference elements from other components or modify elements
from earlier t-config.
Current configuration files are:
* [Pdf-Renderer T-Engine configuration](https://github.com/Alfresco/alfresco-transform-core/blob/master/engines/pdfrenderer/src/main/resources/pdfrenderer_engine_config.json).
* [ImageMagick T-Engine configuration](https://github.com/Alfresco/alfresco-transform-core/blob/master/engines/imagemagick/src/main/resources/imagemagick_engine_config.json).
* [Libreoffice T-Engine configuration](https://github.com/Alfresco/alfresco-transform-core/blob/master/engines/libreoffice/src/main/resources/libreoffice_engine_config.json).
@@ -83,7 +84,7 @@ of these.
The following example begins with the `helloWorld` Transformer, which takes a
text file containing a name and produces an HTML file with `Hello <name>`
message in the body. This is then transformed back into a text file. This
example contains just one pipeline transformer, but many may be defined
example contains just one pipeline transformer, but many may be defined
in the same file.
~~~json
@@ -115,7 +116,7 @@ in the same file.
it remains undefined after all t-config has been combined. Generally
it is better for a t-engine rather than the t-router to define pipeline
transformers as this limits the number of places that have to be changed.
Normally it is obvious which t-engine should contain the definition.
Normally it is obvious which t-engine should contain the definition.
* **supportedSourceAndTargetList** The supported source and target Media
Types, which refer to the Media Types this pipeline transformer can
transform from and to, additionally you can set the `priority` and the
@@ -155,12 +156,12 @@ that is slower but handles all cases.
references to transformer that have not been defined yet. Generally it
is better for the t-engine rather than the t-router to define failover
transformers as this limits the number of places that have to be changed.
Normally it is obvious which t-engine should contain the definition.
Normally it is obvious which t-engine should contain the definition.
* **supportedSourceAndTargetList** The supported source and target Media
Types, which refer to the Media Types this failover transformer can
transform from and to, additionally you can set the `priority` and the
`maxSourceSizeBytes`. Unlike pipelines, it must not be blank.
* **transformOptions** A list of references to options required by the
* **transformOptions** A list of references to options required by the
pipeline transformer.
## Overriding transforms
@@ -277,7 +278,7 @@ Being able to change the defaults is particularly useful once a T-Engine
has been developed as it allows a system administrator to handle
limitations that are only found later. The `system wide defaults` are
generally not used but are included for completeness. The following
example says that the `"Office"` transformer by default should only handle
example says that the `"Office"` transformer by default should only handle
zip files up to 18 Mb and by default the maximum size of a `.doc` file to be
transformed is 4 Mb. The third example defaults the priority, possibly
allowing another transformer that has specified a priority of say `50` to
+1 -1
View File
@@ -37,7 +37,7 @@ All lines start with a reference, which starts with the clients request
number (`163`, `164` if known) and then a nested pipeline or failover
structure. The first request extracts metadata and the second creates a
thumbnail rendition (called `doclib`). The second request is handled by a
pipeline called `officeToImageViaPdf` which uses `libreoffice` to transform
pipeline called `officeToImageViaPdf` which uses `libreoffice` to transform
to `pdf` and then another pipeline to convert to `png`. The last step
(`164.2.2`) in the process resizes the `png` using a number of transform
options.
+3 -4
View File
@@ -1,7 +1,7 @@
# Common base code for T-Engines
This project provides a common base for T-Engines and supersedes the
[original base](https://github.com/Alfresco/alfresco-transform-core/blob/master/deprecated/alfresco-transformer-base).
[original base](https://github.com/Alfresco/alfresco-transform-core/blob/master/deprecated/alfresco-transformer-base).
This project provides a base Spring Boot application (as a jar) to which transform
specific code may be added. It includes actions such as communication between
@@ -17,7 +17,7 @@ For more details on build a custom T-Engine and T-Config, please refer to the do
A T-Engine project which extends this base is expected to provide the following:
* An implementation of the [TransformEngine](https://github.com/Alfresco/alfresco-transform-core/blob/master/engines/base/src/main/java/org/alfresco/transform/base/TransformEngine.java)
interface to describe the T-Engine.
interface to describe the T-Engine.
* Implementations of the [CustomTransformer](engines/base/src/main/java/org/alfresco/transform/base/CustomTransformer.java)
interface with the actual transform code.
* An `application-default.yaml` file to define a unique name for the message queue to the T-Engine.
@@ -30,7 +30,6 @@ The `TransformEngine.getTransformConfig()` method typically reads a `json` file.
The names in the config should match the names returned by the `CustomTransformer`
implementations.
**Example TransformEngine**
The `TransformEngineName` is important if the config from multiple T-Engines is being
@@ -158,4 +157,4 @@ queue:
```text
Jane
```
```
@@ -46,7 +46,7 @@ public interface TransformManager
/**
* Allows a {@link CustomTransformer} to use a local source {@code File} rather than the supplied {@code InputStream}. The file will be deleted once the request is completed. To avoid creating extra files, if a File has already been created by the base t-engine, it is returned. If possible this method should be avoided as it is better not to leave content on disk.
*
*
* @throws IllegalStateException
* if this method has already been called.
*/
@@ -54,7 +54,7 @@ public interface TransformManager
/**
* Allows a {@link CustomTransformer} to use a local target {@code File} rather than the supplied {@code OutputStream}. The file will be deleted once the request is completed. To avoid creating extra files, if a File has already been created by the base t-engine, it is returned. If possible this method should be avoided as it is better not to leave content on disk.
*
*
* @throws IllegalStateException
* if this method has already been called. A call to {@link #respondWithFragment(Integer, boolean)} allows the method to be called again.
*/
@@ -62,7 +62,7 @@ public interface TransformManager
/**
* Allows a single transform request to have multiple transform responses. For example, images from a video at different time offsets or different pages of a document. Following a call to this method a transform response is made with the data sent to the current {@code OutputStream}. If this method has been called, there will not be another response when {@link CustomTransformer#transform(String, InputStream, String, OutputStream, Map, TransformManager)} returns and any data written to the final {@code OutputStream} will be ignored.
*
*
* @param index
* returned with the response, so that the fragment may be distinguished from other responses. Renditions use the index as an offset into elements. A {@code null} value indicates that there is no more output and any data sent to the current {@code outputStream} will be ignored.
* @param finished
@@ -57,7 +57,7 @@ import org.slf4j.LoggerFactory;
* Use the {@link #setProcessDirectory(String) processDirectory} property to change the default location from which the command executes. The process's environment can be configured using the {@link #setProcessProperties(Map) processProperties} property.
* <p>
* Commands may use placeholders, e.g.
*
*
* <pre>
* <code>
* find
@@ -65,27 +65,27 @@ import org.slf4j.LoggerFactory;
* ${filename}
* </code>
* </pre>
*
*
* The <b>filename</b> property will be substituted for any supplied value prior to each execution of the command. Currently, no checks are made to get or check the properties contained within the command string. It is up to the client code to dynamically extract the properties required if the required properties are not known up front.
* <p>
* Sometimes, a variable may contain several arguments. . In this case, the arguments need to be tokenized using a standard <tt>StringTokenizer</tt>. To force tokenization of a value, use:
*
*
* <pre>
* <code>
* SPLIT:${userArgs}
* </code>
* </pre>
*
*
* You should not use this just to split up arguments that are known to require tokenization up front. The <b>SPLIT:</b> directive works for the entire argument and will not do anything if it is not at the beginning of the argument. Do not use <b>SPLIT:</b> to break up arguments that are fixed, so avoid doing this:
*
*
* <pre>
* <code>
* SPLIT:ls -lih
* </code>
* </pre>
*
*
* Instead, break the command up explicitly:
*
*
* <pre>
* <code>
* ls
@@ -77,7 +77,7 @@ import org.alfresco.transform.base.TransformManager;
* If a transform specifies that it can convert from {@code "<MIMETYPE>"} to {@code "alfresco-metadata-embed"}, it is indicating that it can embed metadata in {@code <MIMETYPE>}.
*
* The transform calls {@link #embedMetadata(String, InputStream, String, OutputStream, Map, TransformManager)} which should results in a new version of supplied source file that contains the metadata supplied in the transform options.
*
*
* @author Jesper Steen Møller
* @author Derek Hulley
* @author adavis
@@ -216,7 +216,7 @@ public abstract class AbstractMetadataExtractorEmbedder implements CustomTransfo
* Based on AbstractMappingMetadataExtracter#getDefaultMapping.
*
* This method provides a <i>mapping</i> of where to store the values extracted from the documents. The list of properties need <b>not</b> include all metadata values extracted from the document. This mapping should be defined in a file based on the class name: {@code "<classname>_metadata_extract.properties"}
*
*
* @return Returns a static mapping. It may not be null.
*/
private Map<String, Set<String>> buildExtractMapping()
@@ -269,7 +269,7 @@ public abstract class AbstractMetadataExtractorEmbedder implements CustomTransfo
* This method provides a <i>mapping</i> of model properties that should be embedded in the content. The list of properties need <b>not</b> include all properties. This mapping should be defined in a file based on the class name: {@code "<classname>_metadata_embed.properties"}
* <p>
* If no {@code "<classname>_metadata_embed.properties"} file is found, a reverse of the {@code "<classname>_metadata_extract.properties"} will be assumed. A last win approach will be used for handling duplicates.
*
*
* @return Returns a static mapping. It may not be null.
*/
private Map<String, Set<String>> buildEmbedMapping()
@@ -58,17 +58,17 @@ import org.alfresco.transform.base.clients.FileInfo;
* <li>Provide expected json files (&lt;sourceFilename>"_metadata.json") as resources on the classpath.</li>
* <li>Override the method {@code testTransformation(FileInfo testFileInfo)} such that it calls the super method as a {@code @ParameterizedTest} for example:</li>
* </ul>
*
*
* <pre>
* &#64;ParameterizedTest
*
*
* &#64;MethodSource("engineTransformations")
*
*
* &#64;Override
* public void testTransformation(FileInfo testFileInfo)
*
* {
*
* {
* super.testTransformation(FileInfo testFileInfo)
* }
* </pre>
+1 -1
View File
@@ -1 +1 @@
target/docker/
target/docker/
@@ -1,2 +1,2 @@
queue:
engineRequestQueue: ${TRANSFORM_ENGINE_REQUEST_QUEUE:org.alfresco.transform.engine.example.acs}
engineRequestQueue: ${TRANSFORM_ENGINE_REQUEST_QUEUE:org.alfresco.transform.engine.example.acs}
@@ -16,4 +16,4 @@
]
}
]
}
}
+1 -1
View File
@@ -1 +1 @@
Jane
Jane
+1 -1
View File
@@ -1 +1 @@
target/docker/
target/docker/
+1 -1
View File
@@ -1 +1 @@
target/docker/
target/docker/
+1 -1
View File
@@ -3,4 +3,4 @@
* This transformer uses LibreOffice from The Document Foundation. See the license at
[https://www.libreoffice.org/download/license/](https://www.libreoffice.org/download/license/)
or the [libreoffice.txt](src/main/resources/licenses/3rd-party/libreoffice.txt)
file placed in the root directory of the docker image.
file placed in the root directory of the docker image.
@@ -43,7 +43,7 @@ import org.springframework.core.io.support.ResourcePatternResolver;
/**
* Manages LibreOffice user profile templates for transformations.
*
*
* @author Sayan Bhattacharya
*/
public class LibreOfficeProfileManager
@@ -56,7 +56,7 @@ import org.artofsolving.jodconverter.office.OfficeTask;
* @deprecated The JodConverterMetadataExtracter has not been in use since 6.0.1
*
* Extracts values from Open Office documents into the following:
*
*
* <pre>
* <b>author:</b> -- cm:author
* <b>title:</b> -- cm:title
@@ -8,4 +8,4 @@ transform:
timeout: ${LIBREOFFICE_TIMEOUT:1200000}
portNumbers: ${LIBREOFFICE_PORT_NUMBERS:8100}
templateProfileDir: ${LIBREOFFICE_TEMPLATE_PROFILE_DIR:alfresco_default}
isEnabled: ${LIBREOFFICE_IS_ENABLED:true}
isEnabled: ${LIBREOFFICE_IS_ENABLED:true}
@@ -243,4 +243,4 @@
]
}
]
}
}
@@ -35,7 +35,7 @@ import org.mockito.junit.MockitoJUnitRunner;
/**
* Test cases for LibreOfficeProfileManager
*
*
* @author Sayan Bhattacharya
*/
@RunWith(MockitoJUnitRunner.class)
+1 -1
View File
@@ -1 +1 @@
target/docker/
target/docker/
+6 -6
View File
@@ -1,10 +1,10 @@
### Licenses
* htmlparser http://htmlparser.sourceforge.net/license.html
* commons-compress http://jakarta.apache.org/commons/
* pdfbox-tools http://pdfbox.apache.org/
* poi-ooxml http://poi.apache.org/
* commons-compress, PDFBox and poi-ooxml are from Apache. See the license at http://www.apache.org/licenses/LICENSE-2.0 or the
* htmlparser <http://htmlparser.sourceforge.net/license.html>
* commons-compress <http://jakarta.apache.org/commons/>
* pdfbox-tools <http://pdfbox.apache.org/>
* poi-ooxml <http://poi.apache.org/>
* commons-compress, PDFBox and poi-ooxml are from Apache. See the license at <http://www.apache.org/licenses/LICENSE-2.0> or the
[Apache 2.0.txt](src/main/resources/licenses/3rd-party/Apache%202.0.txt)
file placed in the root directory of the docker image.
* NotoSans https://openfontlicense.org/open-font-license-official-text/
* NotoSans <https://openfontlicense.org/open-font-license-official-text/>
@@ -1,12 +1,12 @@
#
# HtmlMetadataExtractor - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
author=cm:author
title=cm:title
description=cm:description
#
# HtmlMetadataExtractor - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
author=cm:author
title=cm:title
description=cm:description
@@ -113,4 +113,4 @@
]
}
]
}
}
+1 -1
View File
@@ -1 +1 @@
target/docker/
target/docker/
@@ -3,4 +3,4 @@ queue:
transform:
core:
pdfrenderer:
exe: ${PDFRENDERER_EXE:/usr/bin/alfresco-pdf-renderer}
exe: ${PDFRENDERER_EXE:/usr/bin/alfresco-pdf-renderer}
@@ -20,4 +20,4 @@
]
}
]
}
}
+1 -1
View File
@@ -1 +1 @@
target/docker/
target/docker/
+2 -2
View File
@@ -1,4 +1,4 @@
### Licenses
* Tika is from Apache. See the licence at http://www.apache.org/licenses/LICENSE-2.0 or the [Apache 2.0.txt](src/main/resources/licenses/3rd-party/Apache%202.0.txt) file placed in the root directory of the docker image.
* Exiftool is from Phil Harvey. See licence at https://exiftool.org/#license and Perl at https://dev.perl.org/licenses/ (https://dev.perl.org/licenses/artistic.html) or [Perl Artistic License.txt](src/main/resources/licenses/3rd-party/Perl-Artistic-License.txt) file placed in the root directory of the docker image.
* Tika is from Apache. See the licence at <http://www.apache.org/licenses/LICENSE-2.0> or the [Apache 2.0.txt](src/main/resources/licenses/3rd-party/Apache%202.0.txt) file placed in the root directory of the docker image.
* Exiftool is from Phil Harvey. See licence at <https://exiftool.org/#license> and Perl at <https://dev.perl.org/licenses/> (<https://dev.perl.org/licenses/artistic.html>) or [Perl Artistic License.txt](src/main/resources/licenses/3rd-party/Perl-Artistic-License.txt) file placed in the root directory of the docker image.
@@ -68,7 +68,7 @@ import org.alfresco.transform.base.metadata.AbstractMetadataExtractorEmbedder;
/**
* The parent of all Metadata Extractors which use Apache Tika under the hood. This handles all the common parts of processing the files, and the common mappings.
*
*
* <pre>
* <b>author:</b> -- cm:author
* <b>title:</b> -- cm:title
@@ -120,7 +120,7 @@ public class IPTCMetadataExtractor extends AbstractTikaMetadataExtractorEmbeddor
/**
* Converts a date or date time strings into Iso8601 format
* <p>
*
*
* @param dateStrings
* @return dateStrings in Iso8601 format
* @see #iptcToIso8601DateString
@@ -151,7 +151,7 @@ public class IPTCMetadataExtractor extends AbstractTikaMetadataExtractorEmbeddor
* <li>"2001:02:01 16:15+00:00" will convert to "2001-02-01T16:15+00:00"</li>
* <li>"2021-06-11 05:36-01:00" will convert to "2021-06-11T05:36-01:00"</li>
* </ul>
*
*
* @param dateStr
* @return dateStr in Iso8601 format
*/
@@ -48,7 +48,7 @@ import org.alfresco.transform.tika.metadata.AbstractTikaMetadataExtractorEmbeddo
* Configuration: (see OfficeMetadataExtractor_metadata_extract.properties and tika_engine_config.json)
*
* This extractor uses the POI library to extract the following:
*
*
* <pre>
* <b>author:</b> -- cm:author
* <b>title:</b> -- cm:title
@@ -48,7 +48,7 @@ import org.alfresco.transform.tika.metadata.AbstractTikaMetadataExtractorEmbeddo
* <b>created:</b> -- cm:created
* <b>Any custom property:</b> -- [not mapped]
* </pre>
*
*
* @author Nick Burch
* @author Neil McErlean
* @author Dmitry Velichkevich
@@ -117,7 +117,7 @@ public class TikaAutoMetadataExtractor extends AbstractTikaMetadataExtractorEmbe
/**
* Exif metadata for size also returns the string "pixels" after the number value , this function will stop at the first non digit character found in the text
*
*
* @param sizeText
* string text
* @return the size value
@@ -1,12 +1,12 @@
#
# DWGMetadataExtracter - default mapping
#
# author: Nick Burch
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
author=cm:author
title=cm:title
description=cm:description
#
# DWGMetadataExtracter - default mapping
#
# author: Nick Burch
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
author=cm:author
title=cm:title
description=cm:description
@@ -138,4 +138,4 @@ XMP-plus\:PLUSVersion=plus:Version
XMP-plus\:PropertyReleaseID=plus:PropertyReleaseID
XMP-plus\:PropertyReleaseStatus=plus:PropertyReleaseStatus
stDim\:unit=stDim:unit
stDim\:unit=stDim:unit
@@ -1,30 +1,30 @@
#
# MP3MetadataExtracter - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
namespace.prefix.audio=http://www.alfresco.org/model/audio/1.0
# Core mappings
author=cm:author
title=cm:title
description=cm:description
created=cm:created
# Audio descriptive mappings
xmpDM\:album=audio:album
xmpDM\:artist=audio:artist
xmpDM\:composer=audio:composer
xmpDM\:engineer=audio:engineer
xmpDM\:genre=audio:genre
xmpDM\:trackNumber=audio:trackNumber
xmpDM\:releaseDate=audio:releaseDate
#xmpDM:logComment
# Audio specific mappings
xmpDM\:audioSampleRate=audio:sampleRate
xmpDM\:audioSampleType=audio:sampleType
xmpDM\:audioChannelType=audio:channelType
xmpDM\:audioCompressor=audio:compressor
#
# MP3MetadataExtracter - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
namespace.prefix.audio=http://www.alfresco.org/model/audio/1.0
# Core mappings
author=cm:author
title=cm:title
description=cm:description
created=cm:created
# Audio descriptive mappings
xmpDM\:album=audio:album
xmpDM\:artist=audio:artist
xmpDM\:composer=audio:composer
xmpDM\:engineer=audio:engineer
xmpDM\:genre=audio:genre
xmpDM\:trackNumber=audio:trackNumber
xmpDM\:releaseDate=audio:releaseDate
#xmpDM:logComment
# Audio specific mappings
xmpDM\:audioSampleRate=audio:sampleRate
xmpDM\:audioSampleType=audio:sampleType
xmpDM\:audioChannelType=audio:channelType
xmpDM\:audioCompressor=audio:compressor
@@ -1,14 +1,14 @@
#
# MailMetadataExtracter - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
sentDate=cm:sentdate
originator=cm:originator, cm:author
addressee=cm:addressee
addressees=cm:addressees
subjectLine=cm:subjectline, cm:description
#
# MailMetadataExtracter - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
sentDate=cm:sentdate
originator=cm:originator, cm:author
addressee=cm:addressee
addressees=cm:addressees
subjectLine=cm:subjectline, cm:description
@@ -1,14 +1,14 @@
#
# OfficeMetadataExtracter - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
author=cm:author
title=cm:title
subject=cm:description
createDateTime=cm:created
lastSaveDateTime=cm:modified
#
# OfficeMetadataExtracter - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
author=cm:author
title=cm:title
subject=cm:description
createDateTime=cm:created
lastSaveDateTime=cm:modified
@@ -1,21 +1,21 @@
#
# OpenDocumentMetadataExtracter - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
creationDate=cm:created
creator=cm:author
date=
description=
generator=
initialCreator=
keyword=
language=
printDate=
printedBy=
subject=cm:description
title=cm:title
#
# OpenDocumentMetadataExtracter - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
creationDate=cm:created
creator=cm:author
date=
description=
generator=
initialCreator=
keyword=
language=
printDate=
printedBy=
subject=cm:description
title=cm:title
@@ -1,13 +1,13 @@
#
# PdfBoxMetadataExtracter - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
author=cm:author
title=cm:title
subject=cm:description
created=cm:created
#
# PdfBoxMetadataExtracter - default mapping
#
# author: Derek Hulley
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
author=cm:author
title=cm:title
subject=cm:description
created=cm:created
@@ -1,13 +1,13 @@
#
# PoiMetadataExtracter - default mapping
#
# author: Neil McErlean
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
author=cm:author
title=cm:title
description=cm:description
created=cm:created
#
# PoiMetadataExtracter - default mapping
#
# author: Neil McErlean
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
# Mappings
author=cm:author
title=cm:title
description=cm:description
created=cm:created
@@ -1,34 +1,34 @@
#
# TikaAudioMetadataExtracter - audio mapping
#
# This is used to map from the Tika audio metadata onto your
# content model. This will be used for any Audio content
# for which an explicit extractor isn't defined
#
# author: Nick Burch
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
namespace.prefix.audio=http://www.alfresco.org/model/audio/1.0
# Core mappings
author=cm:author
title=cm:title
description=cm:description
created=cm:created
# Audio descriptive mappings
xmpDM\:album=audio:album
xmpDM\:artist=audio:artist
xmpDM\:composer=audio:composer
xmpDM\:engineer=audio:engineer
xmpDM\:genre=audio:genre
xmpDM\:trackNumber=audio:trackNumber
xmpDM\:releaseDate=audio:releaseDate
#xmpDM:logComment
# Audio specific mappings
xmpDM\:audioSampleRate=audio:sampleRate
xmpDM\:audioSampleType=audio:sampleType
xmpDM\:audioChannelType=audio:channelType
xmpDM\:audioCompressor=audio:compressor
#
# TikaAudioMetadataExtracter - audio mapping
#
# This is used to map from the Tika audio metadata onto your
# content model. This will be used for any Audio content
# for which an explicit extractor isn't defined
#
# author: Nick Burch
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
namespace.prefix.audio=http://www.alfresco.org/model/audio/1.0
# Core mappings
author=cm:author
title=cm:title
description=cm:description
created=cm:created
# Audio descriptive mappings
xmpDM\:album=audio:album
xmpDM\:artist=audio:artist
xmpDM\:composer=audio:composer
xmpDM\:engineer=audio:engineer
xmpDM\:genre=audio:genre
xmpDM\:trackNumber=audio:trackNumber
xmpDM\:releaseDate=audio:releaseDate
#xmpDM:logComment
# Audio specific mappings
xmpDM\:audioSampleRate=audio:sampleRate
xmpDM\:audioSampleType=audio:sampleType
xmpDM\:audioChannelType=audio:channelType
xmpDM\:audioCompressor=audio:compressor
@@ -1,52 +1,52 @@
#
# TikaAutoMetadataExtracter - default mapping
#
# This is used to map from the Tika and standard namespaces
# onto your content model. This will be used for any
# content for which an explicit extractor isn't defined,
# by using Tika's auto-selection facilities.
#
# author: Nick Burch
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
namespace.prefix.exif=http://www.alfresco.org/model/exif/1.0
namespace.prefix.audio=http://www.alfresco.org/model/audio/1.0
# Mappings
author=cm:author
title=cm:title
description=cm:description
created=cm:created
geo\:lat=cm:latitude
geo\:long=cm:longitude
tiff\:ImageWidth=exif:pixelXDimension
tiff\:ImageLength=exif:pixelYDimension
tiff\:Make=exif:manufacturer
tiff\:Model=exif:model
tiff\:Software=exif:software
tiff\:Orientation=exif:orientation
tiff\:XResolution=exif:xResolution
tiff\:YResolution=exif:yResolution
tiff\:ResolutionUnit=exif:resolutionUnit
exif\:Flash=exif:flash
exif\:ExposureTime=exif:exposureTime
exif\:FNumber=exif:fNumber
exif\:FocalLength=exif:focalLength
exif\:IsoSpeedRatings=exif:isoSpeedRatings
exif\:DateTimeOriginal=exif:dateTimeOriginal
xmpDM\:album=audio:album
xmpDM\:artist=audio:artist
xmpDM\:composer=audio:composer
xmpDM\:engineer=audio:engineer
xmpDM\:genre=audio:genre
xmpDM\:trackNumber=audio:trackNumber
xmpDM\:releaseDate=audio:releaseDate
#xmpDM:logComment
xmpDM\:audioSampleRate=audio:sampleRate
xmpDM\:audioSampleType=audio:sampleType
xmpDM\:audioChannelType=audio:channelType
xmpDM\:audioCompressor=audio:compressor
#
# TikaAutoMetadataExtracter - default mapping
#
# This is used to map from the Tika and standard namespaces
# onto your content model. This will be used for any
# content for which an explicit extractor isn't defined,
# by using Tika's auto-selection facilities.
#
# author: Nick Burch
# Namespaces
namespace.prefix.cm=http://www.alfresco.org/model/content/1.0
namespace.prefix.exif=http://www.alfresco.org/model/exif/1.0
namespace.prefix.audio=http://www.alfresco.org/model/audio/1.0
# Mappings
author=cm:author
title=cm:title
description=cm:description
created=cm:created
geo\:lat=cm:latitude
geo\:long=cm:longitude
tiff\:ImageWidth=exif:pixelXDimension
tiff\:ImageLength=exif:pixelYDimension
tiff\:Make=exif:manufacturer
tiff\:Model=exif:model
tiff\:Software=exif:software
tiff\:Orientation=exif:orientation
tiff\:XResolution=exif:xResolution
tiff\:YResolution=exif:yResolution
tiff\:ResolutionUnit=exif:resolutionUnit
exif\:Flash=exif:flash
exif\:ExposureTime=exif:exposureTime
exif\:FNumber=exif:fNumber
exif\:FocalLength=exif:focalLength
exif\:IsoSpeedRatings=exif:isoSpeedRatings
exif\:DateTimeOriginal=exif:dateTimeOriginal
xmpDM\:album=audio:album
xmpDM\:artist=audio:artist
xmpDM\:composer=audio:composer
xmpDM\:engineer=audio:engineer
xmpDM\:genre=audio:genre
xmpDM\:trackNumber=audio:trackNumber
xmpDM\:releaseDate=audio:releaseDate
#xmpDM:logComment
xmpDM\:audioSampleRate=audio:sampleRate
xmpDM\:audioSampleType=audio:sampleType
xmpDM\:audioChannelType=audio:channelType
xmpDM\:audioCompressor=audio:compressor
@@ -1,35 +1,35 @@
<?xml version="1.0" encoding="UTF-8"?>
<external-parsers>
<parser>
<check>
<command>exiftool -ver</command>
<error-codes>126,127</error-codes>
</check>
<command>env FOO=${OUTPUT} exiftool -args -G1 -sep "|||" ${INPUT}</command>
<mime-types>
<mime-type>image/x-raw-hasselblad</mime-type>
<mime-type>image/x-raw-sony</mime-type>
<mime-type>image/x-raw-canon</mime-type>
<mime-type>image/x-raw-adobe</mime-type>
<mime-type>image/gif</mime-type>
<mime-type>image/jp2</mime-type>
<mime-type>image/jpeg</mime-type>
<mime-type>image/x-raw-kodak</mime-type>
<mime-type>image/x-raw-minolta</mime-type>
<mime-type>image/x-raw-nikon</mime-type>
<mime-type>image/x-raw-olympus</mime-type>
<mime-type>image/x-raw-pentax</mime-type>
<mime-type>image/png</mime-type>
<mime-type>image/x-raw-fuji</mime-type>
<mime-type>image/x-raw-panasonic</mime-type>
<mime-type>image/tiff</mime-type>
<mime-type>image/webp</mime-type>
</mime-types>
<metadata>
<!-- Default output-->
<match>\s*([A-Za-z0-9/ \(\)]+\S{1})\s+:\s+([A-Za-z0-9\(\)\[\] \:\-\.]+)\s*</match>
<!-- args format-->
<match>^-([\S]+)\=(.*)</match>
</metadata>
</parser>
</external-parsers>
<?xml version="1.0" encoding="UTF-8"?>
<external-parsers>
<parser>
<check>
<command>exiftool -ver</command>
<error-codes>126,127</error-codes>
</check>
<command>env FOO=${OUTPUT} exiftool -args -G1 -sep "|||" ${INPUT}</command>
<mime-types>
<mime-type>image/x-raw-hasselblad</mime-type>
<mime-type>image/x-raw-sony</mime-type>
<mime-type>image/x-raw-canon</mime-type>
<mime-type>image/x-raw-adobe</mime-type>
<mime-type>image/gif</mime-type>
<mime-type>image/jp2</mime-type>
<mime-type>image/jpeg</mime-type>
<mime-type>image/x-raw-kodak</mime-type>
<mime-type>image/x-raw-minolta</mime-type>
<mime-type>image/x-raw-nikon</mime-type>
<mime-type>image/x-raw-olympus</mime-type>
<mime-type>image/x-raw-pentax</mime-type>
<mime-type>image/png</mime-type>
<mime-type>image/x-raw-fuji</mime-type>
<mime-type>image/x-raw-panasonic</mime-type>
<mime-type>image/tiff</mime-type>
<mime-type>image/webp</mime-type>
</mime-types>
<metadata>
<!-- Default output-->
<match>\s*([A-Za-z0-9/ \(\)]+\S{1})\s+:\s+([A-Za-z0-9\(\)\[\] \:\-\.]+)\s*</match>
<!-- args format-->
<match>^-([\S]+)\=(.*)</match>
</metadata>
</parser>
</external-parsers>
@@ -529,23 +529,23 @@
{
"transformerName": "IPTCMetadataExtractor",
"supportedSourceAndTargetList": [
{"sourceMediaType": "image/gif", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/jp2", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/jpeg", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/png", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/tiff", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/webp", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-adobe", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-canon", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-fuji", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-hasselblad", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-kodak", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-minolta", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-nikon", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-olympus", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-panasonic", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-pentax", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-sony", "priority": 45, "targetMediaType": "alfresco-metadata-extract"}
{"sourceMediaType": "image/gif", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/jp2", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/jpeg", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/png", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/tiff", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/webp", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-adobe", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-canon", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-fuji", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-hasselblad", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-kodak", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-minolta", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-nikon", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-olympus", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-panasonic", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-pentax", "priority": 45, "targetMediaType": "alfresco-metadata-extract"},
{"sourceMediaType": "image/x-raw-sony", "priority": 45, "targetMediaType": "alfresco-metadata-extract"}
],
"transformOptions": [
"metadataOptions"
@@ -1008,4 +1008,4 @@
]
}
]
}
}
+1 -1
View File
@@ -1 +1 @@
community=Alfresco Community
community=Alfresco Community
+2
View File
@@ -1,9 +1,11 @@
# alfresco-transform-model
Alfresco Transform Model - Contains the data model of json configuration files
and messages sent between clients, T-Engines and T-Router. It also contains code to
work out which transform should be used for a combination of configuration files.
## Upgrade to 3.0.0
When upgrading to 3.0.0, you will find that a number of classes in the alfresco-transform-model
have moved. Hopefully they are now located in more logical packages. Most classes will not have been
used in existing t-engines (based on the deprecated alfresco-transform-base), other than possibly for
+11 -13
View File
@@ -1,21 +1,19 @@
## Additional Alfresco Models (Content Metadata)
IPTC (Photo Metadata) Standard ( https://iptc.org/standards/photo-metadata/iptc-standard/ )
Alfresco provides an IPTC content model that maps the IPTC photo metadata fields to an
Alfresco Content Model.
IPTC (Photo Metadata) Standard ( <https://iptc.org/standards/photo-metadata/iptc-standard/> )
This IPTC content model used to be part of the Alfresco Media Management product. It is now
provided as part of the core open-source Alfresco Repository. Hence, it will be pre-configured
as part of future core Repository releases (eg. ACS 7.1.0 and related Alfresco Community release).
Alfresco provides an IPTC content model that maps the IPTC photo metadata fields to an
Alfresco Content Model.
This IPTC content model used to be part of the Alfresco Media Management product. It is now
provided as part of the core open-source Alfresco Repository. Hence, it will be pre-configured
as part of future core Repository releases (eg. ACS 7.1.0 and related Alfresco Community release).
The latest ("master") source files can also be found here:
- https://github.com/Alfresco/alfresco-community-repo/blob/master/repository/src/main/resources/alfresco/model/iptcModel.xml
- https://github.com/Alfresco/alfresco-community-repo/tree/master/repository/src/main/resources/alfresco/messages (iptc-model*.properties)
- <https://github.com/Alfresco/alfresco-community-repo/blob/master/repository/src/main/resources/alfresco/model/iptcModel.xml>
- <https://github.com/Alfresco/alfresco-community-repo/tree/master/repository/src/main/resources/alfresco/messages> (iptc-model*.properties)
In the meantime, for convenience, a copy of the Alfresco IPTC content model (XML + message properties)
is also provided here. These files can be configured to deploy the model into earlier versions of
In the meantime, for convenience, a copy of the Alfresco IPTC content model (XML + message properties)
is also provided here. These files can be configured to deploy the model into earlier versions of
ACS (eg. 7.0.0) using static bootstrap mechanism.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Item Identifier
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=A unique identifier created by a registry and applied by the creator of the item. This value shall not be changed after being applied. This identifier is linked to a corresponding Registry Organisation Identifier.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Organization Identifier
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=An identifier for the registry which issued the corresponding Registry Image Id.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Identifik\u00e1tor polo\u
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=Jedine\u010dn\u00fd identifik\u00e1tor vytvo\u0159en\u00fd registrem a aplikovan\u00fd autorem polo\u017eky. Po pou\u017eit\u00ed se ji\u017e tato hodnota nesm\u00ed m\u011bnit. Tento identifik\u00e1tor je spojen s p\u0159\u00edslu\u0161n\u00fdm identifik\u00e1torem organizace registru.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Identifik\u00e1tor organizace
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=Identifik\u00e1tor registru, kter\u00fd vydal p\u0159\u00edslu\u0161n\u00e9 ID sn\u00edmku registru.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Emne-identifikator
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=En unik identifikator oprettet af et register og anvendt af emnets opretter. Denne v\u00e6rdi \u00e6ndres ikke efter anvendelse. Denne identifikator er knyttet til en tilsvarende organisationsidentifikator til registrering
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Organisationsidentifikator
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=En identifikator til det register, der udstedte det tilsvarende registreringsbillede-id.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Element-ID
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=Eine eindeutige Kennung, die von einem Register erstellt oder vom Ersteller des Elements angewendet wurde. Dieser Wert darf nach seiner Anwendung nicht mehr ge\u00e4ndert werden. Diese Kennung ist mit einer entsprechenden Registerorganisationskennung verkn\u00fcpft.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Organisations-ID
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=Eine Kennung f\u00fcr die Registerstelle, welche die entsprechende Registerbild-ID ausgestellt hat.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Identificador de elemento
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=Identificador \u00fanico creado por una organizaci\u00f3n de registro y aplicado por el creador del elemento. No puede modificarse despu\u00e9s de su aplicaci\u00f3n. Este identificador est\u00e1 vinculado al correspondiente identificador de organizaci\u00f3n de registro.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Identificador de organizaci\u00f3n
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=Identificador de la organizaci\u00f3n de registro que emiti\u00f3 el correspondiente ID de imagen de organizaci\u00f3n de registro.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Kohteen tunniste
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=Rekisteriviraston luoma ja kohteen luojan soveltama ainutlaatuinen tunniste. T\u00e4t\u00e4 arvoa ei tule muuttaa soveltamisen j\u00e4lkeen. T\u00e4m\u00e4 tunniste littyy vastaavaan rekisteriviraston tunnisteeseen.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Rekisteriviraston tunniste
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=Kuvan tunnisteen luoneen rekisteriviraston tunniste.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Identifiant de l'\u00e9l\
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=Un identifiant unique cr\u00e9\u00e9 par un organisme d'enregistrement et appliqu\u00e9 par le cr\u00e9ateur de l'\u00e9l\u00e9ment. Une fois appliqu\u00e9e, cette valeur n'est pas modifiable. Cet identifiant est li\u00e9 \u00e0 l'identifiant correspondant de l'organisme d'enregistrement.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Identifiant de l'organisation
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=Un identifiant pour l'organisme d'enregistrement qui a d\u00e9livr\u00e9 l'ID correspondant d'enregistrement de l'image.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Identificatore elemento
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=Identificatore univoco creato da un registro e applicato dal creatore dell'elemento. Una volta applicato, questo valore non pu\u00f2 pi\u00f9 essere modificato. Questo identificatore \u00e8 connesso al corrispondente Identificatore dell'organismo di registrazione.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Identificatore organizzazione
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=Identificatore del registro che ha rilasciato il corrispondente ID immagine registro.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=\u30a2\u30a4\u30c6\u30e0
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=\u30ec\u30b8\u30b9\u30c8\u30ea\u306b\u3088\u3063\u3066\u4f5c\u6210\u3055\u308c\u3001\u30a2\u30a4\u30c6\u30e0\u306e\u4f5c\u6210\u8005\u306b\u3088\u3063\u3066\u9069\u7528\u3055\u308c\u308b\u30e6\u30cb\u30fc\u30af\u306a\u8b58\u5225\u5b50\u3002\u3053\u306e\u5024\u306f\u3001\u9069\u7528\u5f8c\u306b\u5909\u66f4\u3057\u3066\u306f\u306a\u308a\u307e\u305b\u3093\u3002\u3053\u306e\u8b58\u5225\u5b50\u306f\u3001\u5bfe\u5fdc\u3059\u308b\u30ec\u30b8\u30b9\u30c8\u30ea\u7d44\u7e54\u8b58\u5225\u5b50\u306b\u30ea\u30f3\u30af\u3055\u308c\u3066\u3044\u307e\u3059\u3002
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=\u7d44\u7e54 ID
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=\u5bfe\u5fdc\u3059\u308b\u30ec\u30b8\u30b9\u30c8\u30ea\u30a4\u30e1\u30fc\u30b8ID\u3092\u767a\u884c\u3057\u305f\u30ec\u30b8\u30b9\u30c8\u30ea\u306e\u8b58\u5225\u5b50\u3002
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Objektidentifikator
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=En unik identifikator opprettet av et register og brukt av oppretteren av elementet. Denne verdien skal ikke endres etter innf\u00f8ring. Denne identifikatoren er knyttet til en samsvarende organisasjonsidentifikator for registeret.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Organisasjonsidentifikator
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=En identifikator for registeret som utstedte den samsvarende registerbilde-ID-en.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Onderdeel-ID
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=Een unieke ID die wordt gemaakt door een register en wordt toegepast door de maker van het item. Deze waarde blijft na het toepassen ongewijzigd. Deze ID is gekoppeld aan een bijbehorende registerorganisatie-ID.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Organisatie-ID
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=Een ID voor het register dat de bijbehorende registerafbeelding-ID heeft uitgegeven.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Identyfikator elementu
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=Unikatowy identyfikator utworzony przez zarejestrowanie i przydzielony przez tw\u00f3rc\u0119 tego elementu. Tej warto\u015bci nie wolno zmienia\u0107 po przydzieleniu. Identyfikator jest po\u0142\u0105czony z odpowiednim identyfikatorem organizacji w rejestrze.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Identyfikator organizacji
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=Identyfikator rejestru, z kt\u00f3rego pochodzi odpowiedni identyfikator obrazu.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Identificador do Item
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=Um identificador exclusivo criado por um registro e aplicado pelo criador do item. Esse valor n\u00e3o pode ser alterado depois de aplicado. Esse identificador \u00e9 vinculado a um identificador de organiza\u00e7\u00e3o de registro correspondente.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Identificador de Organiza\u00e7\u00e3o
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=Um identificador do registro que emitiu a ID de imagem do registro correspondente.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=\u0418\u0434\u0435\u043d\
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=\u0423\u043d\u0438\u043a\u0430\u043b\u044c\u043d\u044b\u0439 \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440, \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u044b\u0439 \u0440\u0435\u0435\u0441\u0442\u0440\u043e\u043c \u0438 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u043c\u044b\u0439 \u0441\u043e\u0437\u0434\u0430\u0442\u0435\u043b\u0435\u043c \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430. \u042d\u0442\u043e \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0435 \u043d\u0435\u043b\u044c\u0437\u044f \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u043f\u043e\u0441\u043b\u0435 \u043f\u0440\u0438\u043c\u0435\u043d\u0435\u043d\u0438\u044f. \u0414\u0430\u043d\u043d\u044b\u0439 \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440 \u0441\u0432\u044f\u0437\u0430\u043d \u0441 \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u043c \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440\u043e\u043c \u043e\u0440\u0433\u0430\u043d\u0438\u0437\u0430\u0446\u0438\u0438 \u0440\u0435\u0435\u0441\u0442\u0440\u0430.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=\u0418\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440 \u043e\u0440\u0433\u0430\u043d\u0438\u0437\u0430\u0446\u0438\u0438
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=\u0418\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440 \u0440\u0435\u0435\u0441\u0442\u0440\u0430, \u0432\u044b\u0434\u0430\u0432\u0448\u0435\u0433\u043e \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0439 \u0438\u0434\u0435\u043d\u0442\u0438\u0444\u0438\u043a\u0430\u0442\u043e\u0440 \u043e\u0431\u0440\u0430\u0437\u0430 \u0440\u0435\u0435\u0441\u0442\u0440\u0430.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=Objektidentifierare
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=En unik identifierare som skapats av en registreringsenhet och till\u00e4mpas av skaparen av objektet. V\u00e4rdet f\u00e5r inte \u00e4ndras efter att det till\u00e4mpats. Denna identifierare kopplas till motsvarande organisationsidentifierare f\u00f6r registreringsenheten.
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=Organisationsidentifierare
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=En identifierare f\u00f6r registreringsenheten som tilldelade motsvarande registreringsbild-ID.
-2
View File
@@ -191,5 +191,3 @@ iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.title=\u9879\u76ee\u6807\u8bc6\
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegItemId.description=\u7531\u6ce8\u518c\u8868\u521b\u5efa\u5e76\u7531\u9879\u76ee\u521b\u5efa\u8005\u5e94\u7528\u7684\u552f\u4e00\u6807\u8bc6\u7b26\u3002\u8be5\u503c\u5728\u5e94\u7528\u540e\u4e0d\u5f97\u6539\u53d8\u3002\u6b64\u6807\u8bc6\u7b26\u94fe\u63a5\u5230\u76f8\u5e94\u7684\u6ce8\u518c\u8868\u7ec4\u7ec7\u6807\u8bc6\u7b26\u3002
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.title=\u7ec4\u7ec7\u6807\u8bc6\u7b26
iptcxmp_iptcmodel.property.Iptc4xmpExt_RegOrgId.description=\u53d1\u653e\u76f8\u5e94\u6ce8\u518c\u8868\u6620\u50cf Id \u7684\u6ce8\u518c\u8868\u7684\u6807\u8bc6\u7b26\u3002
+4 -4
View File
@@ -209,7 +209,7 @@
<tokenised>false</tokenised>
</index>
</property>
<!-- Deprecated by IPTC
<property name="photoshop:Urgency">
<type>d:text</type>
@@ -266,7 +266,7 @@
<tokenised>false</tokenised>
</index>
</property>
<!-- Deprecated by IPTC
<!-- Deprecated by IPTC
<property name="Iptc4xmpExt:DigitalSourcefileType">
<type>d:text</type>
</property>
@@ -615,7 +615,7 @@
</properties>
</aspect>
</aspects>
</model>
</model>
@@ -40,7 +40,7 @@ import org.alfresco.transform.exceptions.TransformException;
/**
* Reads {@link TransformConfig} from json or yaml files. Typically used by {@code TransformEngine.getTransformConfig()}.
*
*
* <pre>
* transformConfigResourceReader.read("classpath:pdfrenderer_engine_config.json");
* </pre>
@@ -53,7 +53,7 @@ import org.alfresco.transform.common.TransformerDebug;
* <li>When there are no steps left in a level the level is removed</li>
*
* Each level is represented by a String with a pipeline or failover flag @{code 'P'|'F'} followed by a step counter and start time used in debug, a retry count and a sequence of transform steps. Each step is made up of three parts:
*
*
* @{code<transformerName>|<sourceMimetype>|<targetMimetype> . All fields are separated by a @code{'\u23D0'} character. The last step in the sequence is the current transform being performed. The top level transform is a pipeline of one step. Although the source and target mimetypes are always the same for failover transforms, they use the same structure.
*/
public class TransformStack
@@ -89,7 +89,7 @@ public interface TransformServiceRegistry
/**
* Returns {@code true} if the {@code function} is supported by the named transformer. Not all transformers are able to support all functionality, as newer features may have been introduced into the core t-engine code since it was released. Normally used in conjunction with {@link #findTransformerName(String, long, String, Map, String)} rather than {@link #isSupported(String, long, String, Map, String)}.
*
*
* @param function
* to be checked.
* @param transformerName