Most Easegress traffic is message-based, but Easegress v2 pipeline is protocol independent, that's it supports stream-based traffic like TCP, and there's stream traffic even in HTTP.
Another new feature in Easegress v2 is multiple requests/responses support, this requires the payload of a request/response can be read more than once, for message-based traffic, this is simple and easy to do, as Easegress can read the full message payload into memory. But for stream-based traffic, this is impossible, as the payload may require too much memory, and/or take too much time to read it into memory.
To resolve the above issue, Easegress allow user or developer to configure whether a request/response is a stream, for example:
clientMaxBodySize
of an HTTP server to a negative value to
tell Easegress the request is a stream, and not a stream otherwise. Please
refer HTTPServer for more information.serverMaxBodySize
of a Proxy
filter to a negative value to
tell Easegress the response is a stream, and not a stream otherwise. Please
refer Proxy for more information.As we have mentioned above, the payload of a stream-based request/response can only be read once, so some features are not possible for these requests/responses, including:
template
of RequestBuilder
or ResponseBuilder
, you cannot
access the payload(in HTTP, the body) of an existing stream-based
request/response, while it is fine to access other information of the
request/response.Proxy
.HeaderToJSON
filter does not support stream-based requests/responses.WasmHost
filter.Вы можете оставить комментарий после Вход в систему
Неприемлемый контент может быть отображен здесь и не будет показан на странице. Вы можете проверить и изменить его с помощью соответствующей функции редактирования.
Если вы подтверждаете, что содержание не содержит непристойной лексики/перенаправления на рекламу/насилия/вульгарной порнографии/нарушений/пиратства/ложного/незначительного или незаконного контента, связанного с национальными законами и предписаниями, вы можете нажать «Отправить» для подачи апелляции, и мы обработаем ее как можно скорее.
Опубликовать ( 0 )