Standalone indexing trackers for Pristy Search Services — feeds Solr 9 from Alfresco
1.5K
Standalone indexing service for Pristy Search Services. It polls an Alfresco Community repository for node, ACL and content changes and indexes them into Solr 9 through SolrJ.
In stock Alfresco Search Services the trackers run inside the Solr webapp. This fork externalizes them into a Spring Boot 3.5 service, so Solr stays vanilla and the two halves are deployed, restarted and tuned independently.
jeci/pristy-search-services — required| Tag | Contents |
|---|---|
1.1.0, 1.0.0, … | Released versions, cut from a Git tag. Use these. |
latest | Moves with the most recent release tag. |
develop, stable | Head of the corresponding branch. Unstable, for testing only. |
Keep this image and jeci/pristy-search-services on the same tag. They are
released together and are not tested across versions.
| Tracker | Role | Default cron |
|---|---|---|
| ModelTracker | Syncs content models from the repository into Solr | every 10 s |
| MetadataTracker | Indexes node metadata (properties, paths, aspects) | every 5 s |
| AclTracker | Indexes ACL readers/denied, for permission filtering | every 5 s |
| ContentTracker | Extracts and indexes text content via repository transforms | every 20 s |
| CascadeTracker | Updates child paths when a parent is renamed or moved | every 10 s |
| CommitTracker | Coordinates Solr commits across the others | every 5 s |
| RepairTracker | Re-indexes nodes that previously failed | every minute |
It also serves the Solr admin actions that used to live in Solr —
SUMMARY, REPORT, NODECHECK, PURGE, REINDEX, BACKUP, RESTORE — on
port 8085, in two flavours:
GET|POST /api/admin/{action} — idiomatic RESTGET /solr/admin/cores?action={ACTION} — same shape as the old Solr admin,
so existing tooling keeps workingAnd a versioned Pristy API (/api/v1): the verdict on one node's indexing,
computed from the index and the repository, and a live stream of indexing
progress with a standalone page at /indexing.html.
Assumes an Alfresco Community repository at http://alfresco:8080/alfresco and a
jeci/pristy-search-services container at http://solr:8983/solr.
services:
trackers:
image: jeci/pristy-indexing-trackers:1.1.0
environment:
ALFRESCO_TRACKER_SOLR_URL: http://solr:8983/solr
ALFRESCO_TRACKER_SOLR_COLLECTION: alfresco
ALFRESCO_TRACKER_SOLR_COLLECTIONS: alfresco,archive
ALFRESCO_TRACKER_SOLR_SECURECOMMS: secret
ALFRESCO_TRACKER_SOLR_SHAREDSECRET: please-change-me
ALFRESCO_TRACKER_REPOSITORY_URL: http://alfresco:8080/alfresco
ALFRESCO_TRACKER_REPOSITORY_SECURECOMMS: secret
ALFRESCO_TRACKER_REPOSITORY_SHAREDSECRET: please-change-me
ports:
- "8085:8085"
volumes:
- trackers-models:/opt/solr/data
volumes:
trackers-models:
Check that it is alive and connected:
curl http://localhost:8085/actuator/health
curl "http://localhost:8085/solr/admin/cores?action=SUMMARY&core=alfresco"
The full compose stack (repository, Solr, trackers, transform service) is in the project repository.
The service reads standard Spring Boot configuration, so every key in
application.yml has an environment-variable form. The ones that matter:
| Variable | Default | Purpose |
|---|---|---|
ALFRESCO_TRACKER_SOLR_URL | http://localhost:8983/solr | Base URL of the Solr node. |
ALFRESCO_TRACKER_SOLR_COLLECTION | alfresco | Primary core. |
ALFRESCO_TRACKER_SOLR_COLLECTIONS | alfresco,archive | Every core to track. |
ALFRESCO_TRACKER_SOLR_SECURECOMMS | none | none, secret or https. |
ALFRESCO_TRACKER_SOLR_SHAREDSECRET | — | Shared secret in secret mode. |
| Variable | Default | Purpose |
|---|---|---|
ALFRESCO_TRACKER_REPOSITORY_URL | http://localhost:8080/alfresco | Base URL of the repository. |
ALFRESCO_TRACKER_REPOSITORY_SECURECOMMS | none | none, secret or https. |
ALFRESCO_TRACKER_REPOSITORY_SHAREDSECRET | — | Shared secret in secret mode. |
The two channels are configured independently: running secret towards the
repository and https towards Solr is a supported combination.
| Variable | Default | Purpose |
|---|---|---|
ALFRESCO_TRACKER_BATCH_COUNT | 5000 | Nodes fetched per pass. |
ALFRESCO_TRACKER_CRON_METADATA | 0/5 * * * * ? | Quartz cron, metadata. |
ALFRESCO_TRACKER_CRON_ACL | 0/5 * * * * ? | Quartz cron, ACL. |
ALFRESCO_TRACKER_CRON_CONTENT | 0/20 * * * * ? | Quartz cron, content. |
ALFRESCO_TRACKER_CRON_COMMIT | 0/5 * * * * ? | Quartz cron, commit. |
ALFRESCO_TRACKER_CASCADE_TRACKING_ENABLED | true | Cascade path updates. |
ALFRESCO_TRACKER_SOLR_HOME | /opt/solr/data | Where the synced content models are persisted. |
Every setting has a per-core override: alfresco.tracker.cores.<name>.*,
i.e. ALFRESCO_TRACKER_CORES_ARCHIVE_CRON_METADATA. An unset per-core key
inherits the global one. Full reference:
tracker-configuration.md.
Configurable globally (alfresco.tracker.tuning.*) and per core, e.g.
ALFRESCO_TRACKER_TUNING_METADATA_PARALLELISM or
ALFRESCO_TRACKER_CORES_ARCHIVE_TUNING_METADATA_PARALLELISM.
| Key | Default | Purpose |
|---|---|---|
node-batch-size | 50 | Nodes per batch: one repository metadata call and one Solr update each. |
metadata-parallelism | 8 | Threads indexing node batches. |
acl-parallelism | 8 | Threads indexing ACL batches. |
content-parallelism | 8 | Threads extracting content (load on the transform service). |
cascade-parallelism | 8 | Threads processing cascade updates. |
Raising the parallelism does not speed indexing up: measured on a 30 000-node
folder, 4 to 32 threads index in the same time, Solr being the bottleneck. Tune
these knobs down, to leave CPU and heap to the other core — the packaged
configuration already does so for archive.
The image sets JAVA_OPTS=-XX:MaxRAMPercentage=75, so the heap follows the
container memory limit. Add JVM options through JAVA_TOOL_OPTIONS:
overriding JAVA_OPTS drops the heap back to the JVM default of 25%.
| Variable | Default | Purpose |
|---|---|---|
ALFRESCO_TRACKER_BACKUP_ENABLED | false | Opt-in. |
ALFRESCO_TRACKER_BACKUP_CRON | 0 0 2 1 * ? | Monthly, 1st at 02:00. |
ALFRESCO_TRACKER_BACKUP_LOCATION | /backup/solr | Must be a dedicated volume on the Solr container, listed in solr.allowPaths. |
ALFRESCO_TRACKER_BACKUP_NUMBER_TO_KEEP | 2 | Full copies retained. |
| Variable | Default | Purpose |
|---|---|---|
TRACKER_SERVER_SSL_ENABLED | false | Serves :8085 over TLS, client auth required. |
TRACKER_SERVER_SSL_KEY_STORE / _PASSWORD | — | PKCS12 keystore. |
TRACKER_SERVER_SSL_TRUST_STORE / _PASSWORD | — | PKCS12 truststore. |
| Path | Purpose |
|---|---|
/actuator/health | Liveness and repository reachability. Used by the image HEALTHCHECK. |
/actuator/info | Build information. |
/actuator/prometheus | Metrics. |
/actuator/repairreport | Pending indexing errors, recent repairs, per-category summary. |
/api/admin/{action} | Admin actions, REST form. |
/solr/admin/cores?action={ACTION} | Admin actions, Solr-compatible form. |
/api/v1 | Service version and advertised capabilities. A 404 means a service older than the API. |
/api/v1/index/node?ref=<dbid|uuid|noderef> | Indexing verdict for one node: indexed, stale, error, orphan, unindexed, unverified or absent. |
/api/v1/progress, /api/v1/progress/stream | Indexing progress, as a snapshot or a Server-Sent Events stream (throughput, ETA). |
/indexing.html | Standalone page rendering that stream. |
For Alfresco itself to reach these admin endpoints, install
fr.pristy:pristy-search-subsystem-solr9 in the repository's WEB-INF/lib and
start it with:
-Dindex.subsystem.name=solr9
-Dsolr.host=solr -Dsolr.port=8983
-Dsolr.tracker.host=trackers -Dsolr.tracker.port=8085
solr.tracker.host must be set: it defaults to localhost, and every admin
call then fails with Connection refused. Queries and the health ping keep going
to Solr; only the admin actions go to this service.
trackers, uid/gid 33007eclipse-temurin:17-jre-alpineHEALTHCHECK on /actuator/health/opt/solr/data/alfrescoModels holds the synced content models — mount a
volume to avoid re-syncing them on every restartshard.method in solrcore.properties is inert. Distributed
queries still work.FINGERPRINT search is not indexed. The MINHASH field is no longer
computed at index time, so similarity search returns nothing.Since 1.1.0, a node the repository reports as unindexable leaves an error document
and surfaces in REPORT, /actuator/repairreport and retry, instead of being
skipped with a WARN. A Solr outage on the write path no longer loses nodes
either: the batch is rolled back and tracked again.
LGPL v3 or later. Alfresco-derived sources keep their original Alfresco copyright and LGPL v3 headers.
Issues and merge requests: https://gitlab.com/pristy-oss/pristy-search-services
Content type
Image
Digest
sha256:7d70e3466…
Size
179 MB
Last updated
6 days ago
docker pull jeci/pristy-indexing-trackers