You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While creating Response object the library puts all headers in java.util.HashMap which is case-sensitive (see: https://github.com/sendgrid/java-http-client/blob/main/src/main/java/com/sendgrid/Client.java#L163). It works fine when nothing messes up with headers. But when, for example, Istio sidecar is running along the application that uses SendGrid envoy proxy lower-cases all HTTP headers (e.g. X-Message-Id becomes x-message-id). In order to keep things working one has to manually write logic for looking both X-Message-Id and x-message-id which is rather inconvenient. Having headers stored in something like java.util.TreeMap with String.CASE_INSENSITIVE_ORDER comparator would make work with headers much easier.
Steps to Reproduce
Run SendGrid application along with something that manipulates headers (e.g. makes all of them lower-case).
Activity
thinkingserious commentedon Apr 21, 2021
Hi @akandybaev!
Thank you for the suggestion along with the detailed explanation!
This issue has been added to our internal backlog to be prioritized. Pull requests and +1s on the issue summary will help it move up the backlog.
With best regards,
Elmer