feat(api): consolidate temporal-context stored-request GET and CLI - #464
Conversation
… GET
GAP-003A unique slice: GET /v1/temporal-context/{idempotency_key}/request returns the accepted LineageWeave create request on AnalysisRunLiveService / tepp-loopback. Metric-free of RMSE/tepp.scientific_acceptance.v1. inference_status remains temporal_association_only. Naruon refused. NaruonLiveService stays POST-only. ADR 0091.
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Team Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
| let bytes = read_bounded(&mut stream, MAXIMUM_HTTP_RESPONSE_BYTES)?; | ||
| parse_http_response(&bytes) |
| let mut request_bytes = [0_u8; 4096]; | ||
| let received = stream.read(&mut request_bytes).expect("read request"); | ||
| let request = std::str::from_utf8(&request_bytes[..received]).expect("utf8 request"); | ||
| assert!(request.starts_with("GET /v1/temporal-context/idem-tcp/request HTTP/1.1\r\n")); | ||
| assert!(request.contains("tepp-consumer: lineageweave\r\n")); | ||
| assert!(request.contains("content-length: 0\r\n\r\n")); |
| let consumer = require_headers(headers, self.bound_addr, false)?; | ||
| if consumer != LINEAGEWEAVE_CONSUMER_CODE { | ||
| return Err(ApiError::InvalidWirePayload); | ||
| } | ||
| let replay_key = format!("{consumer}\u{1f}{idempotency_key}"); | ||
| let (stored_request, projection) = self | ||
| .accepted_temporal_contexts | ||
| .get(&replay_key) | ||
| .ok_or(ApiError::InvalidWirePayload)?; |
seonghobae
left a comment
There was a problem hiding this comment.
exact-head COMMENT only (not APPROVE) on 1b3a477242336634be2c7867b29d39979e9a6dca. Devin COMMENTED is not independent APPROVE.
Unique remains tepp-temporal-context-request + ADR 0092 (GET /v1/temporal-context/{idempotency_key}/request). LineageWeave stored-request GET after validate_temporal_context_registry_identity; Naruon refused; NaruonLiveService stays POST-only. Metric/causal keys stay in FORBIDDEN_STORED_REQUEST_KEYS. Do not duplicate this surface. Do not ship a second temporal-context stored-request GET/CLI. Do not treat consumer-only scoping as a tenant oracle. Do not un-quarantine export stored-request-by-client-key (that is ADR 0099 on #466, not this adapter).
Still draft. Do not un-draft. Zero exact-head APPROVEs. Do not merge without two independent current-head APPROVEs under ruleset 18156473. #451 CLOSED — do not reopen.
Consolidated landing vehicle
This PR folds predecessor #463 into one LineageWeave-facing Analysis Run / temporal-context application-adapter vehicle. The current head contains #463 as its direct ancestor; retargeting to #463's former base preserves the stored-request GET implementation and tests while eliminating one open micro-PR. #463 remains available as immutable review/history evidence.
Preserved GET behavior from #463:
/v1/temporal-context/{idempotency_key}/requestextra-segment parsing, hostile identity/body/consumer refusals, LineageWeave-only ownership, metric-free output,temporal_association_onlysemantics, and focused HTTP/retrieval tests.CLI behavior on this head: published
tepp-temporal-context-request get, empty-stdin admission, public-bind/localhost/http-origin/credential/consumer/identity refusals, stored-request rendering, and the external real-127.0.0.1TCP contract test added after review.NaruonLiveServiceremains POST-only.This is an application/adapter landing vehicle, not a bounded context. ADR 0091/0092 are implementation lineage pending #437 normalization. Further compatible temporal-context route/CLI mechanics should fold into this vehicle or its coherent successor rather than opening one-operation PRs.
Merge only after fresh exact-head hosted checks, resolved review threads, and the live ruleset's qualifying independent approval. No predecessor-head evidence transfer or bypass.