{"record":{"id":"6c9f5fbfcec5308b","repo":"risingwavelabs/risingwave","slug":"should-get-commit-response-but-get-6c9f5f","errorCode":null,"errorMessage":"should get commit response but get {:?}","messagePattern":"should get commit response but get (.+?)","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"src/rpc_client/src/sink_coordinate_client.rs","lineNumber":114,"sourceCode":"    pub async fn commit(\n        &mut self,\n        epoch: u64,\n        metadata: SinkMetadata,\n        schema_change: Option<PbSinkSchemaChange>,\n    ) -> anyhow::Result<()> {\n        self.send_request(CoordinateRequest {\n            msg: Some(coordinate_request::Msg::CommitRequest(CommitRequest {\n                epoch,\n                metadata: Some(metadata),\n                schema_change,\n            })),\n        })\n        .await?;\n        match self.next_response().await? {\n            CoordinateResponse {\n                msg: Some(coordinate_response::Msg::CommitResponse(_)),\n            } => Ok(()),\n            msg => Err(anyhow!(\"should get commit response but get {:?}\", msg)),\n        }\n    }\n\n    pub async fn update_vnode_bitmap(&mut self, vnode_bitmap: &Bitmap) -> anyhow::Result<u64> {\n        self.send_request(CoordinateRequest {\n            msg: Some(coordinate_request::Msg::UpdateVnodeRequest(\n                UpdateVnodeBitmapRequest {\n                    vnode_bitmap: Some(vnode_bitmap.to_protobuf()),\n                },\n            )),\n        })\n        .await?;\n        match self.next_response().await? {\n            CoordinateResponse {\n                msg:\n                    Some(coordinate_response::Msg::StartResponse(StartCoordinationResponse {\n                        log_store_rewind_start_epoch,\n                    })),","sourceCodeStart":96,"sourceCodeEnd":132,"githubUrl":"https://github.com/risingwavelabs/risingwave/blob/6469eb736d691e8e9b8a419a57edd6429ca77417/src/rpc_client/src/sink_coordinate_client.rs#L96-L132","documentation":"SinkCoordinateClient::commit sends a Commit request over the sink coordination stream and then awaits the next response. If the response is not a CommitResponse, it errors. This means the coordinator replied with an unexpected message type (or the stream desynchronized), so the commit's outcome is unknown.","triggerScenarios":"Calling SinkCoordinateClient::commit when the coordinator sends a different CoordinateResponse variant — e.g. stream out-of-order after prior failed round-trips, coordinator restart, or protocol mismatch between client and stream engine versions.","commonSituations":"Sink coordinator crashed and re-answered with an error-shaped message; interleaving requests on a shared stream; version skew between compute node and meta after upgrade.","solutions":["Inspect the debug-printed response in the message to identify what the coordinator actually returned","Recreate the SinkCoordinateClient stream (the protocol state machine is likely desynced) and retry the epoch","Check coordinator logs for errors around the commit; verify compute node and meta versions match"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"// Rust\nmatch client.commit().await {\n    Ok(()) => {},\n    Err(e) if e.to_string().starts_with(\"should get commit response\") => {\n        tracing::warn!(\"commit desynced: {e:#}; rebuilding coordination stream\");\n        client = rebuild_sink_coordinate_client().await?;\n        client.commit().await?;\n    }\n    Err(e) => return Err(e),\n}","preventionTips":["Keep one request/response round-trip at a time on the coordination stream","Align component versions across upgrades","Log unexpected coordinator responses for triage"],"tags":["grpc","protocol","sink","streaming"],"backgroundTag":"unexpected-response-shape","analyzedSha":"6469eb736d691e8e9b8a419a57edd6429ca77417","analyzedAt":"2026-09-11T21:06:21.487Z","contentChangedAt":"2026-09-11T21:06:21.487Z","schemaVersion":2},"datasetVersion":"2026-09-14T16:17:12.679Z"}