Giter Club home page Giter Club logo

Comments (12)

shinayser avatar shinayser commented on September 2, 2024 2

Hey @CodingAleCR please take a look on this issue. The bot seems not not like it and keeps closing xD

from http_interceptor.

stale avatar stale commented on September 2, 2024 1

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

from http_interceptor.

stale avatar stale commented on September 2, 2024 1

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

from http_interceptor.

vixez avatar vixez commented on September 2, 2024

I have created a PR for how I currently solved this issue.

from http_interceptor.

CodingAleCR avatar CodingAleCR commented on September 2, 2024

Really interesting FR (Feature Request). Is this request based on the need for having multiple requests but refresh token only once for all subsequent requests?

from http_interceptor.

CodingAleCR avatar CodingAleCR commented on September 2, 2024

This could be interesting as well if the "pausing" was performed when the retry policy is triggered instead of always as well, in any case, how would you feel about this?

from http_interceptor.

vixez avatar vixez commented on September 2, 2024

Hey,
Yes, we use the client to talk to our own backend. So when one of the requests returns a 401 all future requests should wait until the token is refreshed.
If the token fails to refresh it could be nice to cancel further requests, since they will fail anyway without a token.

Maybe requests could be 'grouped' by a GUID, or adding tags to requests. With some way to cancel requests that belong to a certain group/tag.
This would be convenient to cancel pending requests when a user is logged out due to an expired token, and cancel pending requests that user authentication. Se that group or tag would be cancelled then.

from http_interceptor.

vixez avatar vixez commented on September 2, 2024

@CodingAleCR
I have created a PR with how I implemented it in my app (both the limiting and pausing of requests), albeit a bit more abstract.

from http_interceptor.

stale avatar stale commented on September 2, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

from http_interceptor.

stale avatar stale commented on September 2, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

from http_interceptor.

brxxxx avatar brxxxx commented on September 2, 2024

Any developments on this feature?

from http_interceptor.

CodingAleCR avatar CodingAleCR commented on September 2, 2024

There's a PR outdated that deals with pooling requests and working on pauses. But other than that there's no current development at the moment.

Feel free to drop a PR with an implementation if that's something you think could help 😉👌🏼

Thank you both for bringing this up as well!

from http_interceptor.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.