GithubHelp home page GithubHelp logo

Comments (3)

binaryfire avatar binaryfire commented on June 9, 2024 1

@subomi Yeah, I think that makes sense. That would allow you to use any part of the request (headers or specific JSON keys) as the idempotent key.

from convoy.

subomi avatar subomi commented on June 9, 2024 1

Hey @binaryfire ,

This has shipped in the latest release! And we just launched it here

from convoy.

subomi avatar subomi commented on June 9, 2024

Thanks @binaryfire ,

You're correct. Convoy will process each event independently. This feature is a little trickier to implement, which is counterintuitive to what I expected. The problem is identifying the idempotent key to use because various providers implement this feature differently, Let's take 3 examples:

  1. Stripe: The Idempotent key is included in the request body. So you'll need to retrieve the id field from the request payload. See the docs.
  2. Adyen: The Idempotent key is a combination of eventCode and pspReference. So we'll need to extract both values and create a unique constraint out of them. See the docs.
  3. GitHub: The Idempotent key is the HTTP Header: X-GitHub-Delivery. See the docs.

Of all the implementations, GitHub is the easiest to implement; we can open up a form field on the source configuration to specify the header to act as the idempotent key, but this doesn't work for all use cases. I suggest we'll need to implement a "request matching dsl" to match the different patterns to accommodate different provider's idempotency key implementation.

What do you think?

from convoy.

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.