In #6328 we document the X-Debug plugin's behavior with multiple proxies. Unfortunately, its done in the opposite order of the Via header (which is append, based on https://tools.ietf.org/html/rfc7230#section-5.7.1). This is confusing -- we can have 2 headers next to each other with similar data, but, needs to be read in the exact opposite order.
Proposal is to standardize the X-Cache header to behave like Via.