Skip to main content

Compute-over-data architecture across remote sites and object stores

Compute-over-data means choosing a compute location with practical access to the input, instead of automatically centralizing every dataset. In Bacalhau, an orchestrator receives a job and compute nodes execute Docker or WASM tasks; inputs and outputs are described as part of the job. See the architecture overview for component responsibilities.

Reference topology

LayerResponsibilityDesign question
OrchestratorReceives jobs and coordinates stateWho operates its availability, identity, and audit trail?
Compute nodesExecute isolated task environmentsWhich sites can reach each dataset and meet runtime needs?
Input storageProvides files, objects, or URLsWhich credentials and network paths are permitted?
Result publisherStores artifacts and resultsWhere may outputs reside and who can retrieve them?

Keep the network boundary explicit: object storage is not automatically mounted simply because a node is nearby, and a job constraint does not change a storage bucket policy.

Model the job rather than the marketing diagram

This example uses a URL input and local publisher so the data path is visible. Substitute your controlled source and publisher only after reviewing the relevant source and result specifications.

Type: batch
Count: 1
Tasks:
- Name: summarize
Engine:
Type: docker
Params:
Image: alpine:3.21
Parameters: [sh, -c, "wc -l /inputs/events.txt > /outputs/line-count.txt"]
InputSources:
- Alias: events
Target: /inputs/events.txt
Source:
Type: urlDownload
Params:
URL: https://example.org/events.txt
Publisher:
Type: local
ResultPaths:
- Name: outputs
Path: /outputs

Submit it with bacalhau job run job.yaml, then use bacalhau job describe <job-id> to inspect execution state. The quick start shows the same imperative and declarative workflow.

Tradeoffs and controls

RequirementUseful Bacalhau mechanismBoundary outside Bacalhau
Keep work at a siteNode labels and job constraintsNetwork segmentation and physical/data residency controls
Limit a task's inputsExplicit input sourcesStorage IAM, object ACLs, and secret distribution
Preserve resultsResult paths and a publisherRetention, encryption, and downstream access policy
Recover from a failureJob state and operator monitoringSite disaster recovery and capacity planning

Read the constraint specification, input-source specification, and publishing results guide before choosing production values.

Limitations

This architecture does not eliminate data transfer: container images, inputs, logs, and results can still cross a network. Instrument those paths, test loss of a site or storage endpoint, and define whether a no-match constraint must fail closed or trigger an approved fallback.