saivarmaakireddy270-star commented on issue #64678:
URL: https://github.com/apache/airflow/issues/64678#issuecomment-4191367294
It looks like the duplicate `Date` header is being introduced because it’s
being set at multiple layers (application + server/proxy).
According to the HTTP spec, the `Date` header should only be set once, and
most servers (Node.js, Nginx, etc.) automatically add it. If the application
code also sets it manually, it results in duplication.
**Suggested fix:**
* Remove any manual setting of the `Date` header in the application code.
* Ensure that only one layer (preferably the server/proxy) is responsible
for setting it.
For example, in Node.js:
```js
// ❌ Avoid this
res.setHeader("Date", new Date().toUTCString());
```
If a reverse proxy like Nginx is involved, you can also hide the upstream
header:
```nginx
proxy_hide_header Date;
```
This should ensure only a single `Date` header is present in responses and
resolve the issue.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]