-
-
Notifications
You must be signed in to change notification settings - Fork 6.9k
Description
I did this
POST /report/generate -> 303 Location /poll/<some id>
GET /poll/<some id> -> 429 with Retry-After or 301 with Location /download/<some id>
I am running the following curl command:
curl -v -L --retry 4 -H "Content-Type: application/json" --data '{"hello":"world"}' http://localhost:8000/report/generate
I want to see a single POST request to /report/generate, but instead I am getting first POST request to /report/generate then GET to /poll/..., which returns 429. In this moment it asks for some reason /report/generate, but this time with GET. I think this is a bug.
All logs and also sample server in deno I saved in gist here: https://gist.github.com/kilork/4899caddd6b6f9d9263c0b48c2d36a5c
I expected the following
First request is POST to /report/generate
Then come GET requests to /poll/
And finally I receive 301 to /download/
So basically I want to have poll until done single command. This works correctly with wget, but they do not proceed Retry-After, which also not quite pleasant.
curl/libcurl version
curl 7.70.0 (x86_64-w64-mingw32) libcurl/7.70.0 OpenSSL/1.1.1g (Schannel) zlib/1.2.11 brotli/1.0.7 libidn2/2.3.0 libpsl/0.21.0 (+libidn2/2.3.0) libssh2/1.9.0 nghttp2/1.40.0
Release-Date: 2020-04-29
Protocols: dict file ftp ftps gopher http https imap imaps ldap ldaps pop3 pop3s rtsp scp sftp smtp smtps telnet tftp
Features: AsynchDNS brotli HTTP2 HTTPS-proxy IDN IPv6 Kerberos Largefile libz Metalink MultiSSL NTLM PSL SPNEGO SSL SSPI TLS-SRP
operating system
Windows 10