SShortSingh.
Back to feed

Como garantir que um Pix seja creditado exatamente uma vez

0
·2 views

Todo sistema que recebe Pix depende de uma notificação assíncrona do PSP: o webhook. Em produção, esse webhook chega duplicado quando o PSP não recebe o 200 a tempo, chega atrasado, chega fora de ordem (a devolução antes do crédito) e às vezes não chega. Mesmo assim, cada centavo precisa ser creditado exatamente uma vez, e no fim do dia o saldo interno tem que bater com o extrato do PSP. Montei um laboratório para provar isso, o PixLab: um PSP falso que injeta essas falhas de propósito, com seed, e um recebedor de referência que precisa sobreviver a todas. Seguem as cinco decisões que fazem a

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

The Sheet Outlives AppSheet. Check That Its References Do.

The usual argument for AppSheet over Power Apps is about where the data lives. AppSheet keeps its records in a Google Sheet you own, so if you cancel the subscription the app disappears and the spreadsheet stays. Power Apps keeps them in Dataverse, which is a proper relational database but not a file you can open. That argument is correct as far as it goes. The rows survive.

0
ProgrammingDEV Community ·

First post, Jr Dev!

Vengo del mundo de los negocios, la logística y la atención al cliente, pero hoy mi cabeza está metida en bases de datos, APIs y Node.js, cursando la carrera de Analista de Sistemas. Estoy convencido de que los mejores productos tecnológicos se hacen entendiendo primero el dolor del negocio. Y como la mejor forma de aprender es tirándose al agua, esta semana me sumé al #Hacktoberfest. ¡Ya tengo mis dos primeros Pull Requests en revisión para un proyecto Open Source! Más allá de sumar código, la verdadera ganancia estuvo en enfrentarme al flujo de trabajo real de un equipo de desarrollo: Correg

0
ProgrammingDEV Community ·

Salvage, Rebuilt, Flood: A Developer-Friendly Guide to Title Brands and NMVTIS

If you're shopping for a used car, the single most expensive mistake is buying a vehicle with a branded title you didn't know about. This post explains what title brands are, how NMVTIS works, and where a plain VIN decode fits in. A title brand is a permanent notation a state DMV adds to a vehicle's title when something significant happens to it. Common brands include: Salvage – an insurer declared the vehicle a total loss (damage cost exceeds a state-defined share of its value). Rebuilt / Reconstructed – a salvage vehicle that was repaired and passed a state inspection.

0
ProgrammingDEV Community ·

Onchain experiments, and why we need them

The blockchain industry should never go stale, but something’s off. What used to feel wide open is getting squeezed by prediction markets and memecoins. That can’t be the whole story. When I first ran into Web3, CryptoKitties were a thing, NFTs were everywhere, and DeFi was exploding. You could seriously imagine building the next decentralized stablecoin, the next onchain collectible, the next lending protocol, with millions of people actually using the chain.