Skip to content

precompute_engine has no source abstraction — ingest is hardcoded to HTTP #300

@milindsrivastava1997

Description

@milindsrivastava1997

The HTTP server is the only ingest path in precompute_engine, and it is hardcoded directly in engine.rs::run(). There is no trait or interface representing an ingest source.

The closest shared logic is route_decoded_samples() in ingest_handler.rs, which both HTTP handlers call. However, this function is private and coupled to the private IngestState struct, making it inaccessible to any alternative ingest path. SeriesRouter has a clean public interface (route_group_batch, broadcast_flush, broadcast_shutdown), but there is no abstraction above it that unifies how sources push data into the router.

As a result, adding any new ingest source (file, Kafka-native, etc.) requires modifying engine.rs::run() directly and duplicating routing logic, rather than implementing a defined interface. This makes the engine difficult to extend and tests each new source in isolation from the common routing path.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions