mirror of
https://github.com/fnproject/fn.git
synced 2022-10-28 21:29:17 +03:00
fn: LB runner client header processing fix (#1565)
When LB is processing http headers from flat array representation in gRPC, it should use http.Header.Add() to grow http headers to handle header keys with multiple values. Set() overrides the previous entries.
This commit is contained in:
@@ -386,8 +386,8 @@ DataLoop:
|
||||
span.Annotate([]trace.Attribute{trace.StringAttribute("status", infoMsg)}, "")
|
||||
log.Debugf(infoMsg)
|
||||
for _, header := range meta.Http.Headers {
|
||||
clonedHeaders.Set(header.Key, header.Value)
|
||||
w.Header().Set(header.Key, header.Value)
|
||||
clonedHeaders.Add(header.Key, header.Value)
|
||||
w.Header().Add(header.Key, header.Value)
|
||||
}
|
||||
if meta.Http.StatusCode > 0 {
|
||||
statusCode = meta.Http.StatusCode
|
||||
|
||||
Reference in New Issue
Block a user