We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5c5a330 commit 3dd4ff1Copy full SHA for 3dd4ff1
src/server/streamableHttp.ts
@@ -162,8 +162,9 @@ export class StreamableHTTPServerTransport implements Transport {
162
}));
163
return;
164
}
165
-
166
- res.writeHead(200, headers);
+ // We need to send headers immediately as message will arrive much later,
+ // otherwise the client will just wait for the first message
167
+ res.writeHead(200, headers).flushHeaders();
168
169
// Store the response for this request so we can use it for standalone server notifications
170
// This response doesn't have an associated request ID, so we'll use a special string to track it
0 commit comments