mathetake / envoy-dynamic-modules

the custom Envoy proxy with dynamic module HTTP filters
Apache License 2.0
12 stars 4 forks source link

Add functionality to retrieve all headers from RequestHeaders and ResponseHeaders #30

Open jonfriesen opened 1 month ago

jonfriesen commented 1 month ago

Currently, the RequestHeaders and ResponseHeaders interfaces don't provide a straightforward way to retrieve a list of all headers. This functionality would be beneficial for debugging, logging, and processing purposes.

Maybe something like:

type RequestHeaders interface {
    All() map[string]HeaderValue
    ...
}

or

type Header struct {
    Key string
    HeaderValue
}
type RequestHeaders interface {
    All() []Header
    ...
}
mathetake commented 1 month ago

that's a valid feature request indeed!