Skip to content

Need to configure a response header with DownstreamHeaderTransform containing multiple values being separated by commas #2269

Closed Answered by raman-m
RahulBorana94 asked this question in Q&A
Discussion options

You must be logged in to vote

Hello, Rahul!
The problem is in used comma char , in header values!
Did you read this discussion? 👉

Don't use comma in header value and everything will be fine. But if downstream services produce such a values with commas then you must encode value. So, the possible solution has provided in #2249 .
Other possible solutions:

  • Fork Ocelot repo, develop special HeaderFindAndReplaceCreator class replacing , with something appropriate for your project.
  • You are able to develop custom HeaderFindAndReplaceCreator service and replace it in DI container using the IHeaderFindAndReplaceCreator interface service 👇

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by raman-m
Comment options

You must be logged in to vote
1 reply
@raman-m
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
Headers Transform Ocelot feature: Headers Transformation
2 participants