Skip to content
open-recPublic

About

No description, website, or topics provided.

Resources

Code of conduct

Contributing

Security policy

Stars

6 stars

Watchers

1 watching

Forks

Latest commit

 

History

148 Commits

Folders and files

OpenRec Distribution

Release v0.2.0 · Changelog

Quality Standalone E2E Cluster E2E License

This repository is the distribution and compatibility authority for OpenRec. It assembles the independently developed OpenRec components into versioned standalone and cluster deployments, provides a reproducible sample dataset and Web Demo, and owns cross-repository end-to-end CI.

Quick start · Deployment modes · Architecture · Versioning · Releasing · Organization overview

OpenRec v0.2.0 pins immutable component commits. Use this tagged release for reproducible source deployments; the supplied cluster Compose is an integration/reference topology and requires security and HA work before production use.

Java migration prerequisites

rec-server and web use JDK 21 / Spring Boot 4.1.1; data-processor uses JDK 21 with Spark 4.0.4 and Flink 2.2.1. SDK, init and all shared rec-server modules also target Java 21. Install JDK 21 before invoking the source-build scripts:

export OPENREC_JAVA21_HOME=/path/to/jdk-21

The scripts and GitHub Actions use only Java 21 for every Java component. JAVA_HOME pointing to JDK 21 also works without an explicit OPENREC_JAVA21_HOME. The rec-server Dockerfile independently builds and runs on Java 21. The companion commits are recorded in release/openrec.json. Publish those component commits before publishing this distribution commit so a fresh checkout can resolve the manifest.

See recommendation readiness for startup warmup, traffic admission and the required companion versions.

What this repository guarantees

  • release/openrec.json records the exact component refs composing this distribution.
  • Pull requests validate repository policy, DAG syntax, shell, Compose, and cross-repository Java compatibility.
  • Standalone E2E starts real Redis, Elasticsearch, rec-server, rec-console, and the Web Demo, imports sample data, and executes a real recommendation request.
  • Cluster E2E runs the full startup path, infrastructure smoke, Kafka/Spark/Redis feature parity, recommendation warmup, recall-node diagnostics, ranked recommendations and Kafka ingestion. The separate cluster/verify_*.sh flows cover deeper persistence, recall publication, analytics, deletion, model lifecycle and rollback acceptance.
  • Release tags package the manifest, deployment definitions, documentation, sample data, and checksums as one immutable distribution bundle.

The component repositories remain the source of their application images and libraries. This repository defines which component versions are known to work together.

Feature and model lifecycle

The canonical global feature definitions live in model/feature/catalog; rec-algorithm and data-processor carry validated copies. The model repository also holds generated bootstrap artifacts. Runtime training versions are stored separately in the shared model artifact volume. rec-console selects supported LR/FM/LightGBM feature subsets and triggers Airflow; rec-algorithm prepares samples with Spark and trains/evaluates in an isolated offline process. rank-engine only loads published versions and performs online inference. Training never automatically publishes.

Feature implementation and backfills remain engineering tasks. See the cluster model lifecycle guide for independent training/publication, coordinated component upgrades and local-image validation.

Quick start

1. Clone the distribution and components

git clone https://github.com/open-rec/openrec.git openrec
cd openrec
./scripts/release/checkout-components.sh

The checkout script creates the required sibling layout and checks out the refs in the release manifest:

openrec/
├── openrec/
├── bigdata-platform/
├── data-processor/
├── rank-engine/
├── rec-algorithm/
├── rec-console/
├── rec-server/
└── sdk/

Pass a destination to create the workspace somewhere else:

./scripts/release/checkout-components.sh /opt/openrec

2. Start standalone

./standalone/start.sh

The command builds current component sources in an isolated runtime directory, starts the serving infrastructure and applications, imports the bundled dataset, verifies the configured serving DAG, and starts the Web Demo.

Service URL
Web Demo http://127.0.0.1:12345
OpenRec Console http://127.0.0.1:8095
Recommendation API http://127.0.0.1:13579
Grafana http://127.0.0.1:3000

Stop the applications while retaining infrastructure data, or remove the complete standalone runtime:

./standalone/stop.sh
./standalone/stop.sh --with-storage

Sample credentials and published ports are intended only for an isolated development machine. Review the standalone guide before sharing the deployment on a network.

Deployment modes

Concern Standalone Cluster
Primary use Evaluation, development, small-to-medium integration Distributed integration and production reference architecture
Ingestion Direct Redis write Versioned Kafka mutations
Historical storage Bundled source data HBase and partitioned Hive/HDFS data
Processing Local loader and algorithms Spark/Flink streaming and Spark batch jobs
Recall release Local import to Elasticsearch aliases Airflow + Spark + rec-console validation and activation
Ranking Bypass supported Trained, evaluated, versioned rank models
Control plane Monitoring, entities, serving graph Full graph, recall, Airflow, analytics, model, and experiment operations
Required host resources Developer workstation Dedicated integration host or CI runner

Start cluster only on a host sized for the complete data platform:

./cluster/start.sh
./cluster/verify_daily_recall.sh
./cluster/verify_entity_delete.sh
./cluster/verify_data_analytics.sh
./cluster/verify_rank_model.sh

See the cluster guide for prerequisites, startup ownership, endpoints, failure diagnosis, and shutdown behavior. For the local image/mirror configuration, start cluster with ./cluster/start.sh --local. Standalone startup does not need this flag. Sample recall imports reserve revision r000; scheduled daily publications start at r001. This keeps same-day fixture indexes separate from immutable offline releases.

Distribution contents

Path Purpose
release/openrec.json Distribution version, component repositories, refs, and compatibility metadata
standalone Minimum complete deployment and smoke acceptance
cluster Distributed deployment and lifecycle acceptance suites
data Small committed dataset for deterministic CI and evaluation
init Redis and Elasticsearch data/recall loader
web Interactive recommendation and feedback demo
scripts Component checkout, policy validation, and release assembly
docs Architecture, versioning, release, and CI documentation

End-to-end CI

flowchart LR
    PR[Pull request] --> Quality[Policy · syntax · Compose]
    Quality --> Build[Cross-repository build and tests]
    Build --> Standalone[Standalone E2E]
    Main[Default branch or schedule] --> Standalone
    Schedule[Schedule or manual dispatch] --> Cluster[Cluster startup E2E on GitHub-hosted runner]
    Tag[Version tag] --> Bundle[Validated release bundle + checksums]
Loading
Workflow Trigger Runner Coverage
quality.yml Pull request and push GitHub-hosted Manifest, links, generated files, shell, Python DAGs, Compose, Java build/tests, Python/Flink/Spark feature parity
standalone-e2e.yml Main changes, schedule, manual GitHub-hosted Complete standalone startup and recommendation acceptance
cluster-e2e.yml Schedule and manual GitHub-hosted Cluster startup, platform smoke, feature parity, warmup, recall diagnostics, ranked recommendations, Kafka ingestion
release.yml v* tag GitHub-hosted Version consistency, distribution archive, SHA-256 checksums, GitHub Release

Cluster CI runs on a GitHub-hosted runner with constrained JVM heaps, reduced parallelism, and an explicit disk-space cleanup step. It is scheduled and manually dispatchable rather than a required check on every pull request because it starts Kafka, HDFS, Hive, HBase, Spark, Flink, Airflow, Redis, Elasticsearch, monitoring, and all OpenRec applications together. Resource assumptions and failure diagnostics are documented in CI.

The cluster workflow does not run every verify_*.sh lifecycle check. For the registered full regression, use the sibling auto-test runner: its cluster full suite adds deletion, analytics, daily recall and model lifecycle checks plus API and browser coverage. Its standalone suite verifies the capabilities supported in that mode.

Versioning and releases

The distribution version is stored in VERSION. Component repositories may release independently, but an OpenRec distribution release is valid only when every ref in release/openrec.json is immutable and all required E2E checks pass.

See versioning for compatibility rules and releasing for the release checklist. Production automation must consume a version tag or commit digest rather than master or latest.

Contributing and support

Use this repository for installation, distribution, release, and cross-component issues. File component-local defects in the repository that owns the code. Contributions follow the shared OpenRec contribution guide, Code of Conduct, and Security Policy.

License

This distribution is licensed under the Apache License 2.0. Included component and third-party artifacts retain their respective licenses.

Raw-data initialization

Both modes accept OPENREC_DATA_DIR and OPENREC_MODEL_ROOT. Missing or stale model bundles are rebuilt from raw CSVs before import. Mode-specific initialization lives in each mode’s init.sh, with a shared Java storage loader. See initialization inputs, reuse rules, and existing-data behavior.

See the tool directory guide for initialization, runtime checks, CI, and release commands.

Local source regression with existing images

Use ./standalone/start.sh --reuse-images or ./cluster/start.sh --reuse-images when compatible application and infrastructure images already exist locally. This mode compiles current Java services and frontend assets, mounts Python sources, and refreshes the Spark algorithm ZIP. It never builds or pulls images; missing images cause startup to fail. Node.js/npm are needed for the local frontend build. Dependency or Dockerfile changes require an explicit image rebuild. The sibling auto-test runner uses this mode by default for --start and --restart; its --build-images flag opts into the regular image-building startup path.

About

No description, website, or topics provided.

Resources

Code of conduct

Contributing

Security policy

Stars

6 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages