You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shenyu.apache.org by GitBox <gi...@apache.org> on 2021/07/13 00:58:17 UTC

[GitHub] [incubator-shenyu] iwongta commented on issue #1747: how to get requset body in my plugin??

iwongta commented on issue #1747:
URL: https://github.com/apache/incubator-shenyu/issues/1747#issuecomment-878695610


       exchange.getRequest().getBody()
           .map(x -> {
             byte[] b = new byte[x.readableByteCount()];
             x.read(b);
             String string = new String(b , StandardCharsets.UTF_8);
             exchange.getAttributes().put(Constants.PARAM_TRANSFORM , string);
             log.info("PreFcOpenPlugin Constants.PARAM_TRANSFORM => {}" , string);
             return string;
           }).subscribe();
           此方式获取,频繁出现  Connection prematurely closed BEFORE response 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org