Files
open-cmis-tck/docs/LOCAL-TCK-RUNTIME.md
2026-05-08 07:51:42 +02:00

5.9 KiB

Local OpenCMIS TCK Runtime

Status: draft Created: 2026-05-07

Purpose

This document describes the local runtime needed to actually run Apache Chemistry OpenCMIS TCK checks from the open-cmis-tck guide-board extension.

The TCK is an open source Java toolkit. It is not vendored into this repository. The extension provides a pinned Maven runtime descriptor and adapter commands that resolve and run the TCK locally.

Runtime Pin

The first local runtime uses:

  • Maven coordinate: org.apache.chemistry.opencmis:chemistry-opencmis-test-tck:1.1.0
  • License: Apache License 2.0
  • Runner class: org.apache.chemistry.opencmis.tck.runner.ConsoleRunner
  • Runner contract: session-parameters file plus group-list file

The Apache Chemistry project is retired, so this extension pins the 1.1.0 Maven artifact and records the retirement boundary in runtime summaries.

Sources:

Bootstrap

From this repository:

PYTHONPATH=src python3 scripts/bootstrap_opencmis_tck.py

This checks Java, Maven, and the local runtime descriptor. It writes:

.local/opencmis-tck/runtime-summary.json

To resolve/cache Maven dependencies, run:

PYTHONPATH=src python3 scripts/bootstrap_opencmis_tck.py --resolve

The --resolve step downloads Maven dependencies into the user's Maven cache. It does not commit artifacts into this repository.

Current Local Prerequisites

The local runner expects:

  • java on PATH
  • mvn on PATH
  • network access or an already-populated Maven cache for the first --resolve

On Ubuntu/WSL, a typical prerequisite install is:

sudo apt-get update
sudo apt-get install -y openjdk-17-jdk maven

Use an already managed Java/Maven installation instead if this workstation has one outside WSL.

When sudo is not available, use the local toolchain installer:

python3 scripts/install_local_toolchain.py
source .local/toolchains/env.sh

This keeps the JDK and Maven under .local/toolchains, which is ignored by git. It is intended as a workstation bootstrap convenience, not as a committed runtime artifact.

Guide-Board Invocation

For the full local sequence, see docs/LOCAL-RUNBOOK.md.

The baseline assessment profile now points the OpenCMIS wrapper at:

adapters/opencmis_console_adapter.py

The adapter generates:

  • session.properties.redacted
  • groups.txt
  • console-runner-invocation.json
  • console-runner-stdout.txt
  • console-runner-stderr.txt

and invokes Maven's exec:java goal against:

runtime/opencmis-tck/pom.xml

That Maven descriptor pulls the OpenCMIS TCK artifact and runs ConsoleRunner.

The adapter normalizes the native ConsoleRunner text report into guide-board case evidence. The retained raw stdout/stderr files remain the audit trail; the normalized result records OpenCMIS result statuses, test names, messages, source locations where present, and per-status counts.

Local In-Memory Pilot Target

The extension can also launch Apache Chemistry's in-memory server WAR under Tomcat 9 as a controlled CMIS Browser Binding pilot target:

python3 scripts/opencmis_inmemory_server.py start
python3 scripts/opencmis_inmemory_server.py probe
python3 scripts/opencmis_inmemory_server.py stop

The default Browser Binding URL is:

http://127.0.0.1:18080/inmemory/browser

The default repository ID from the bundled in-memory configuration is A1. Runtime files, logs, downloaded WAR/Tomcat artifacts, and server state are kept under .local/opencmis-inmemory.

Because OpenCMIS 1.1.0 predates modern JDK module removals, the launcher also adds Java EE API compatibility jars for JAX-WS, JWS, SOAP, and annotations to the local Tomcat runtime. These files stay under .local/.

The bundled in-memory repository uses the sample credentials from its default configuration:

export OPENCMIS_INMEMORY_USER=dummyuser
export OPENCMIS_INMEMORY_PASSWORD=dummysecret

Preflight and the TCK adapter both consume the target profile's credentials_ref, so the local pilot profile uses these environment variables without committing secrets.

Session Parameters

For Browser Binding runs, the adapter writes OpenCMIS session parameters such as:

org.apache.chemistry.opencmis.binding.spi.type=browser
org.apache.chemistry.opencmis.binding.browser.url=<browser-url>
org.apache.chemistry.opencmis.session.repository.id=<repository-id>
org.apache.chemistry.opencmis.binding.browser.succinct=true
org.apache.chemistry.opencmis.binding.compression=true
org.apache.chemistry.opencmis.binding.cookies=true

User and password fields are written only when explicitly supplied. Secret values are written to a private session file for the ConsoleRunner process and removed after use; guide-board retains only session.properties.redacted.

Credential references come from the target profile:

credentials_ref: null
credentials_ref: env:CMIS_TCK_USER,CMIS_TCK_PASSWORD
credentials_ref: file:/absolute/path/to/cmis-tck-credentials.json

For an authenticated local run:

export CMIS_TCK_USER='alice'
export CMIS_TCK_PASSWORD='local-secret'

Check Group Mapping

The first adapter maps guide-board check groups to OpenCMIS TCK group classes:

  • repository-type: BasicsTestGroup, TypesTestGroup
  • object-content: CRUDTestGroup
  • navigation: FilingTestGroup
  • query-acl-versioning: QueryTestGroup, ControlTestGroup, VersioningTestGroup
  • relationships: CRUDTestGroup
  • change-log: ControlTestGroup
  • extension-gaps: no executable group yet; treated as known-gap review

This mapping should be refined after the first live pilot output is reviewed.