feat(#2591): add GET /api/build-log/<node_id> {,/raw} query endpoints
The raw-graph wire drops the inline build_log_id; the client fetches a
node's captured output on demand. Two handlers resolve node id -> log-row
id (JobQueue::build_log_id_of, now keyed by the wire u64) then delegate to
the existing get_full / raw handlers: /api/build-log/<node_id> serves the
BuildLogFull JSON ({stdout, stderr} + header), /raw serves text/plain.
404 when the node has no linked log.
This commit is contained in:
parent
02e2bf895e
commit
52dd9ede23
4 changed files with 55 additions and 7 deletions
|
|
@ -100,6 +100,14 @@ pub async fn serve(
|
|||
)
|
||||
.route("/api/audit-log", get(misc_api::api_audit_log))
|
||||
.route("/api/build-logs", get(build_logs::get_build_logs_all))
|
||||
.route(
|
||||
"/api/build-log/{node_id}",
|
||||
get(build_logs::get_build_log_for_node),
|
||||
)
|
||||
.route(
|
||||
"/api/build-log/{node_id}/raw",
|
||||
get(build_logs::get_build_log_raw_for_node),
|
||||
)
|
||||
.route(
|
||||
"/api/build-logs/{agent}",
|
||||
get(build_logs::get_build_logs_agent),
|
||||
|
|
|
|||
Loading…
Reference in a new issue