Summary
The entire private_link module returns Result<serde_json::Value> on 14 methods where the spec promises TaskStateUpdate. Additionally, vpc_peering and transit_gateway deletes return Value::Null (response body discarded) when the spec returns a Task. Cuts callers off from polling the resulting async operation.
Expected behavior
Every connectivity endpoint that the spec marks as task-returning (i.e. has a taskId in the response) should return the canonical TaskStateUpdate so callers can poll /tasks/{taskId} to completion.
Actual behavior
src/connectivity/private_link.rs:325-625 — 14 typed methods (get_private_link, create_private_link, delete_private_link, update_private_link, add_principal, remove_principal, get_endpoint_script, disassociate_connections, plus the active-active variants and PSC service variants) all return Result<Value>.
src/connectivity/transit_gateway.rs:189,325 — TGW deletes return Result<Value> and discard the body (Value::Null).
src/connectivity/vpc_peering.rs — VPC peering deletes have the same shape.
The spec lists TaskStateUpdate as the response on each of these.
Impact
Callers cannot use the typed handlers to track async operations on connectivity. They must drop to client.get_raw("/tasks/{id}") themselves and reconstruct the polling loop. Inconsistent with the rest of the crate, which already returns TaskStateUpdate for similar mutating operations on databases/subscriptions.
Relevant code
src/connectivity/private_link.rs:325-625 (14 methods)
src/connectivity/transit_gateway.rs:189,325
src/connectivity/vpc_peering.rs (delete handlers)
Suggested fix
Change the return type from Result<Value> to Result<TaskStateUpdate> (using the canonical type from #64). For deletes, send the delete_with_body request and deserialize the response.
This is best done after — or as part of — #64 so we don't migrate Value→Value-typed-as-TaskStateUpdate→canonical-TaskStateUpdate in two passes.
Acceptance criteria
References
Summary
The entire
private_linkmodule returnsResult<serde_json::Value>on 14 methods where the spec promisesTaskStateUpdate. Additionally,vpc_peeringandtransit_gatewaydeletes returnValue::Null(response body discarded) when the spec returns a Task. Cuts callers off from polling the resulting async operation.Expected behavior
Every connectivity endpoint that the spec marks as task-returning (i.e. has a
taskIdin the response) should return the canonicalTaskStateUpdateso callers can poll/tasks/{taskId}to completion.Actual behavior
src/connectivity/private_link.rs:325-625— 14 typed methods (get_private_link,create_private_link,delete_private_link,update_private_link,add_principal,remove_principal,get_endpoint_script,disassociate_connections, plus the active-active variants and PSC service variants) all returnResult<Value>.src/connectivity/transit_gateway.rs:189,325— TGW deletes returnResult<Value>and discard the body (Value::Null).src/connectivity/vpc_peering.rs— VPC peering deletes have the same shape.The spec lists
TaskStateUpdateas the response on each of these.Impact
Callers cannot use the typed handlers to track async operations on connectivity. They must drop to
client.get_raw("/tasks/{id}")themselves and reconstruct the polling loop. Inconsistent with the rest of the crate, which already returnsTaskStateUpdatefor similar mutating operations on databases/subscriptions.Relevant code
src/connectivity/private_link.rs:325-625(14 methods)src/connectivity/transit_gateway.rs:189,325src/connectivity/vpc_peering.rs(delete handlers)Suggested fix
Change the return type from
Result<Value>toResult<TaskStateUpdate>(using the canonical type from #64). For deletes, send thedelete_with_bodyrequest and deserialize the response.This is best done after — or as part of — #64 so we don't migrate Value→Value-typed-as-TaskStateUpdate→canonical-TaskStateUpdate in two passes.
Acceptance criteria
private_linkmethods returnResult<TaskStateUpdate>(or the canonical type from refactor(types): consolidate shared task/tag/link models and normalize task status typing #64)Result<TaskStateUpdate>, body is parsed (no moreValue::Null)TaskStateUpdateReferences