ores.scheduler.core

Table of Contents

Diagram

ores.scheduler.core component diagram

Figure 1: ores.scheduler.core

Summary

ores.scheduler.core provides cron-based job scheduling for ORE Studio. It manages job definitions (cron expressions, target actions) and job instances (execution history, status), runs a persistent scheduler loop that fires due jobs, and exposes NATS handlers for querying and managing jobs at runtime. It supports SQL, NATS-publish, and message-queue action types, making it the general-purpose periodic-operation backbone for the platform.

Inputs

  • NATS request messages for job-definition CRUD and instance queries.
  • PostgreSQL connections to ores_scheduler_* tables for job persistence.
  • System clock for evaluating cron expressions.

Outputs

  • Job-definition and job-instance records persisted to the ores_scheduler schema.
  • Triggered actions: SQL statements executed, NATS messages published, or MQ actions dispatched per job schedule.
  • NATS response messages returned to callers.

Entry points

  • include/ores.scheduler.core/ores.scheduler.hpp — aggregate include.
  • include/ores.scheduler.core/messaging/registrar.hpp — registers all NATS handlers.
  • include/ores.scheduler.core/service/scheduler_loop.hpp — the main scheduling loop driven by the service host.
  • include/ores.scheduler.core/builder/job_definition_builder.hpp — fluent builder for creating job definitions programmatically.

Dependencies

  • ores.scheduler.api — shared domain types and NATS protocol schemas.
  • ores.dq — ORM base classes and persistence infrastructure.
  • ores.iam.core — identity and authorisation context.
  • rfl — JSON serialisation via reflection.
  • soci — SQL ORM for PostgreSQL persistence.
  • nats.c — NATS messaging client.

See also

Emacs 29.1 (Org mode 9.6.6)