Skip to content

Conversation

@fekitibi
Copy link
Contributor

Summary

When a service's upstream is another service with rate-limiting enabled, enabling a rate-limiting plugin on the service results in duplicate headers. This PR fixes the issue by removing Kong's rate-limiting headers from the upstream response and applying only the headers from the plugin.

Checklist

  • The Pull Request has tests
  • A changelog file has been created under changelog/unreleased/kong or skip-changelog label added on PR if changelog is unnecessary. README.md
  • There is a user-facing docs PR against https://github.com/Kong/docs.konghq.com - PUT DOCS PR HERE

Issue reference

Fix #14353

When a service's upstream is another service with rate-limiting enabled, enabling a rate-limiting plugin on the service results in duplicate headers. This PR fixes the issue by removing Kong's rate-limiting headers from the upstream response and applying only the headers from the plugin.

Kong#14353
@CLAassistant
Copy link

CLAassistant commented Mar 12, 2025

CLA assistant check
All committers have signed the CLA.

@team-eng-enablement team-eng-enablement added the author/community PRs from the open-source community (not Kong Inc) label Mar 12, 2025
@pull-request-size pull-request-size bot added size/S and removed size/M labels Mar 13, 2025
@fekitibi fekitibi closed this Mar 13, 2025
@fekitibi fekitibi deleted the fix/douplicate-kong-rate-limiting-headers-in-nested-environment branch March 13, 2025 13:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author/community PRs from the open-source community (not Kong Inc) size/S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Duplicate or Conflicting X-RateLimit Headers When Upstream is Another Kong Gateway Service with Rate Limit Plugin Set

3 participants