feat(telemetry): add bounded native pipeline lifecycle
This commit is contained in:
@@ -75,6 +75,7 @@ PROMETHEUS_SAMPLE = re.compile(
|
||||
r"(?:\{[^}]*\})?\s+(?P<value>[0-9.eE+-]+)$"
|
||||
)
|
||||
TELEMETRY_QUERY_SCHEMA: Final = "missioncore.telemetry-query/v1"
|
||||
PIPELINE_TELEMETRY_SCHEMA: Final = "missioncore.agent-pipeline-telemetry/v1"
|
||||
DEFAULT_TELEMETRY_QUERY_URL: Final = "http://127.0.0.1:18030"
|
||||
|
||||
RootProvider = Callable[[], Path]
|
||||
@@ -510,6 +511,12 @@ def _agent_raw_document(document: dict[str, Any]) -> dict[str, Any]:
|
||||
if model_load_seconds is not None:
|
||||
perception["model_load_seconds"] = model_load_seconds
|
||||
perception["collector_state"] = fields.get("collector_state")
|
||||
elif sample.get("source_schema") == PIPELINE_TELEMETRY_SCHEMA:
|
||||
# Native lifecycle rows are immutable run evidence. The current
|
||||
# service snapshot remains owned by the periodic health sample,
|
||||
# so a terminal event cannot make a healthy worker look idle,
|
||||
# failed, or busy after the fact.
|
||||
continue
|
||||
else:
|
||||
pipeline_payload = _mapping(payload.get("payload")) or payload
|
||||
for name, value in pipeline_payload.items():
|
||||
|
||||
Reference in New Issue
Block a user