ores.compute.core

Table of Contents

1. Diagram

ores.compute.core component diagram

Figure 1: ores.compute.core

2. Summary

ores.compute.core manages the compute cluster for ORE risk runs. It maintains a registry of available compute applications (app, app_version), assigns batch jobs to available hosts, tracks execution state, and collects results. Worker nodes running ores.compute.wrapper register themselves and receive job assignments via NATS; results flow back through the same channel.

3. Inputs

  • NATS messages from ores.compute.wrapper instances (registration, heartbeat, job completion with result paths).
  • NATS request messages from UI clients (batch CRUD, host/app queries).
  • PostgreSQL connections to ores_compute_* tables.

4. Outputs

  • Batch and result records persisted to the ores_compute schema.
  • NATS job-assignment messages dispatched to compute workers.
  • NATS response messages returned to callers.

5. Entry points

  • include/ores.compute.core/ores.compute.hpp — the component's banner header, the same shape every component carries. It declares no symbol.
  • include/ores.compute.core/messaging/registrar.hpp — registers handlers.
  • include/ores.compute.core/service/ — app, batch, host, result services.

6. Dependencies

  • ores.compute.api — shared domain types and NATS protocol schemas.
  • ores.dq — ORM base classes.
  • ores.iam.core — authorisation context.
  • nats.c; PostgreSQL through ores.database.

7. Build dependencies

What the shared profile cannot know, declared here rather than hand-edited into the generated build file. Each block is spliced into its generated file after the profile's baseline.

8. See also

9. Test dependencies

The suites link what the profile cannot know about.

target_link_libraries(${lib_target_name}
    PUBLIC
        ores.compute.api.lib
        ores.database.lib
        ores.nats.lib
        ores.dq.api.lib
        ores.diff.lib
        ores.service.lib
    PRIVATE
        ores.security.lib
        ores.utility.lib
        ores.logging.lib
        ores.platform.lib
        ores.reporting.api.lib
        ores.iam.client.lib
        ores.history.core.lib
        faker-cxx::faker-cxx
        libfort::fort)
target_link_libraries(${tests_target_name}
    PRIVATE
        ${lib_target_name}
        ores.utility.lib
        ores.testing.lib
        ores.logging.lib
        ores.eventing.api.lib
        ores.eventing.core.lib
        ores.refdata.core.lib
        Catch2::Catch2
        faker-cxx::faker-cxx
        Threads::Threads)

Emacs 29.3 (Org mode 9.6.15)