response (IncomingMessaging) has been read by interceptor and make downstream library unreadable
See original GitHub issueI am using Axios to get the raw stream, but Interceptors read the stream in utils/getIncomingMessageBody
, so that the downstream http client cannot read the stream anymore. This can be a side effect and ideally that stream should be piped and not touch the original stream.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:2
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Spring Boot Adding Http Request Interceptors - Stack Overflow
I have followed this way to intercept the signup requests come to my application in order to do some common validations. But the...
Read more >Using the Spring RestTemplate Interceptor - Baeldung
In this tutorial, we're going to learn how to implement a Spring RestTemplate Interceptor. We'll go through an example in which we'll create...
Read more >How to use Axios interceptors, a step-by-step guide with ...
In this tutorial, learn how to use Axios interceptors step by step with an example to track response duration for each Axios request....
Read more >Top 10 ways to use Interceptors in Angular - Medium
There are many ways to use an interceptor, and I'm sure most of us have only ... It provides a way to intercept...
Read more >Setting up Axios Interceptors for all HTTP calls in an application
Today, you can: order a car and have it pick you up at your exact location ... In addition to all the basic...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@kettanaito I’m happy to take this on. Will advise on progress.
@kettanaito For me it was relevant.
I am using the interceptors in a browser context (namely
XMLHttpRequest
&fetch
) andfetch
is pretty much useless because of this issue which is why I linked to a possible solution because the issue is the same in the serviceworker context: they HAVE to read the response, yet still pipe it further down to the client.