rikka0w0
Explore posts from serversCDCloudflare Developers
•Created by rikka0w0 on 4/5/2025 in #general-help
Cloudflare CDN wont send any of the POST body to the backend until the CDN receives the entire POST
As the title says.
To confirm this behavior, I wrote a simple client and server program (in NodeJS). On the client side, I started a POST request to my own website behind the Cloudflare CDN, without specifying the Content-Length. The client code sends a number every 1 second and closes the connection after sending 5 numbers. My expectation was to receive one number per second on the server side. But what actually happened was that I didn't get anything on my server end and then suddenly received all 5 numbers in one batch.
Looks like the CDN "caches" the POST request that does not have body length specified until it fully receives the body, then sends it to the backend.
How could we change this behavior (on a per-request or per-url base)?
Thanks!
1 replies