Giter Site home page Giter Site logo

Comments (3)

Sammyjo20 avatar Sammyjo20 commented on July 2, 2024 1

Hey @denjaland thank you for letting me know about this, this is because the event contains closures which cannot be serialized, so sadly you wouldn't be able to implement the ShouldQueue interface onto your listener. You could handle the listener synchronously and fire off a queued job to process specific parts of the response e.g the body which could be quite easily serialised as an array or a string.

I also really appreciate the sponsor!

from saloon.

denjaland avatar denjaland commented on July 2, 2024 1

Hi @Sammyjo20,

that is indeed the workaround I applied meanwhile. Are you having plans to get rid of the closures inside the event? Haven't dug into the code yet, but it would be really nice I believe :-)

Other than that I really like the package, so thanks for contributing to the community. I can't afford more atm, but always try to sponsor where I can, either by buying a paid product or though the sponsorship program here. So thanks again :-)

from saloon.

Sammyjo20 avatar Sammyjo20 commented on July 2, 2024

Hey @denjaland

I don't have any immediate plans to change the way the response works, I think it's extremely useful that a response contains the pending request, request and connector from the request so you can easily trace it back, and unfortunately that means the middleware (which is closure-based) cannot be seralized. I will add it to my notes to see if this can be improved for v4.

from saloon.

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.