Backend Engineer | Web3 | Golang | Laravel | Mod @BerfBased

127.0.0.1
Buchy retweeted
Database Transactions One thing you don't want in a wallet system is money leaving one account without reaching the other. I am building PropInvest, a property investment platform where users can fund wallets and invest in real estate. When an investor puts money into a property, the system needs to: - Deduct funds from their wallet - Create the investment record - Update the property's funding status - Log the transaction Now, what happens if the wallet is debited, but the server crashes before creating the investment? The investor's money is gone, but they don't own any shares. That's a nightmare. This is why database transactions matter. A database transaction lets you group multiple operations together so they either all succeed or all fail. If the wallet debit, investment creation, and transaction log all succeed, the transaction commits. If any step fails, everything rolls back. The wallet stays untouched. No partial state. This is called atomicity, the A in ACID. ACID stands for: - Atomicity: All operations succeed, or none do. - Consistency: The transaction preserves database rules and constraints. - Isolation: Concurrent transactions don't interfere with each other. - Durability: Once committed, changes persist even if the system crashes. For PropVest's wallet operations, every debit, credit, and record is wrapped in the same database transaction. One important detail though: this protects database changes within that transaction. It doesn't automatically reverse an external action, like a payment already sent to Paystack. That is why I also used idempotency keys, locked balances, and reconciliation workers. But transactions were the foundation. When handling money, a successful API response isn't enough. You need to make sure the underlying operations are actually safe. Never assume your code will complete every step. Design your database operations to handle failure.
1
1
1
15
Buchy retweeted
One of the reasons we have so much slop is cause people don’t understand that just because something can be created doesn’t mean it should be created.
16
192
1,119
14,829
100% and then, have to go back and learn another skill....and the cycle continues. because, no matter how we try to deny it, AI IS taking software engineering jobs, or at least morphing it. Tasks/projects that could take an entire team months can now be handled by a single engineer in a few weeks and if that engineer has solid fundamentals, he can easily maintain/scale it and there will be no consequence of bad code. So, more unemployed software engineers, less entry level roles. we're already feeling it, and AI agents are only getting smarter
The problem isn’t that we don’t want to learn a digital skill. We just don’t want to spend 2 to 3 years learning a skill that doesn’t exist at the end because AI can now do it better.
1
1
1
1,390
Buchy retweeted
Transactional Outbox Pattern One thing I've implemented in PropInvest - a platform I am building for fractional real estate ownership, is the Transactional Outbox Pattern. Say you're building a wallet system for property investments. A user purchases shares in a property. You debit their wallet, credit the property pool, and commit the transaction. Then you publish an "investment_completed" event to Kafka (or any other message broker e.g RabbitMQ) so that the notification service can alert the user and update their portfolio. Simple enough, right? But what happens if your application crashes after the database commit but before publishing the event? The investment succeeded, money moved, but the notification was never sent. Other services that depend on that event - like portfolio tracking - may never know the investment happened. Now, if you publish the event before committing the transaction, you have the opposite problem. The event gets published, but the database transaction might fail. Other services are reacting to an investment that never actually went through. This is the dual-write problem. The Transactional Outbox Pattern solves this by saving the business data and the event in the same database transaction. If the transaction commits, both are saved. If it rolls back, neither is saved. A separate worker reads pending events from the outbox table, publishes them to the message broker - Kafka in this case, and marks them as processed. If the worker goes down, the event is still in the database and can be published when the worker comes back up. But there's a catch. The worker could publish an event successfully, crash before marking it as processed, and publish it again after restarting. That means duplicates are possible. This is where idempotency comes in. Give every event a unique ID, and let consumers track which events they've already processed. If an event arrives again, the consumer can safely skip the duplicate. The same principle applies to API requests. If a client retries an investment purchase because of a timeout, an idempotency key helps prevent the same shares from being purchased twice. One thing to keep in mind: the outbox prevents the database change and the intent to publish from getting out of sync. It doesn't guarantee exactly-once delivery or processing. You still have to handle retries and duplicates yourself. The outbox handles reliable event delivery. Idempotency handles repeated execution. Both matter when building systems where a missed event or a duplicate operation can cause real problems - especially when real money is involved.
1
2
3
188
lmao since after university days, i never gather morale enter that line again. anytime i remember, na so so "someday" i go dey talk inside my mind 😂
That year for Ph, I go do Networking class. I no know where I gather confidence, I rush go write CCNA. I fail am. I ginger myself re-study BGP, EIGRP and those rubbish. Rush go retake am. As I fail am again, I rest. It's been 14 years. It's not for me please😂
1
152
Buchy retweeted
Money just dey fly up and down for America.
Whop has raised $200M in Series D funding at a $5.1B valuation, backed by @sequoia and @shopify. It really feels like we are barely touching the tip of the iceberg in a market larger than anyone can imagine. We first launched Whop as a better way for us to sell sneaker bots, one of the most niche types of desktop software out there. Total TAM? Probably $20,000 per day. Who cares, tiny market. But, what people discounted is the idea that there were actually 70,000 other markets exactly like that one. Beyond the investment itself, I am especially excited to welcome legendary silicon valley investor @dougleone to our board of directors. Doug and the sequoia team are nothing but a brilliant, resourceful, and principled group of people. My co-founder Cameron and I started building on Shopify when we were 13 years old. Shopify is one of the most impactful all-in-one cloud ecosystems ever created; @tobi has pioneered modern entrepreneurship the way we know it and we are thrilled to have him in our corner. We have a tenet at Whop to be the dumbest in the room and I am very grateful that this has recently become a lot easier. We are focused on markets, scale economies, and progressive media. If that is up your alley, please message me directly. The $200M raised will support our expansion as we build economic infrastructure for the next century, continuing on our mission of delivering everyone an income.
13
12
118
5,116
Buchy retweeted
Holy Spirit, please help me plan my life.
44
2,307
9,883
93,722
actually, life tip
One 9 to 5 tip: you just have to accept that people are probably gossiping about you at work.😂 It’s a rookie behaviour to care.
1
61
don't rage bait me this night
Funny how Men would spend their last dime on their mums and receive nothing but prayers in return, but when it comes to their girlfriends, they start setting limits, as if their girlfriends haven’t played motherly roles in their lives, too.
48
Buchy retweeted
BBC was the greatest trio in football, not because they were the most beautiful, but because they were the most inevitable. MSN was beauty. You watched them and you smiled. The one-twos, the little flicks, the friendship. It was football as art. It was made to be admired. BBC was not made to be admired. BBC was made to win. To destroy. Bale running like a horse that escaped war. Benzema sacrificing himself, linking, bleeding for the team with no credit. And Ronaldo - the storm in the middle. The end product. The man who turned every attack into a sentence. MSN would caress you. BBC would kill you. And that is the dichotomy of Messi and Ronaldo. Messi is beauty. When he plays, football feels pure. It feels like it was meant to be like that. You watch him and you feel something in your chest. Ronaldo is greatness. When he plays, football feels powerful. It feels like willpower can beat talent. You watch him and you feel something in your gut - the fear, the awe, the inevitability that he will find a way. Both are good. But one is beautiful, the other one is great. Beauty makes you fall in love with football. Greatness makes you remember why you will never forget it.
Best trio in football history (past and present): 1. Benzema - Bale - Cristiano 2. Messi - Suarez - Neymar 3. Rooney - Teves - Ronaldo 4. Robben - Lewandoski- Ribery 5. Mane- Firmino - Salah 6. Kvara - Dembele - Doue 7. Raphinha- Lewandoski- Yamal 8. Messi - Mbappe - Neymar 9. Kante- kovacic - Jorginho 10. Rogers - Joao Pedro - Palmer (fast rising)
86
604
3,248
96,952
real
unlimited wifi na life saver
50
this is who jorge jesus and the portugal team wants to disrespect?? someone that literally carried their team for years! appalling!
When the moment demanded courage, he never hid. He was Fearless, Reliable & Inevitable. That’s Cristiano Ronaldo 🐐🥰 You can never re-write history cuz he will forever be HIM. Until the end idolo 🐐❤️
1
65
The harder you work, the luckier you become.
21
197
974
24,996
Buchy retweeted
As long as I’m alive, I’ve infinite chances of making it.
94
519
2,183
49,596
I"ll be starting with Sriniously's YT series "Backend Principles". It comes highly recommended and I have been meaning to go through it. I like the fact that it is language-agnostic so that I can focus on the principles and not worry about syntax at the same time.
I've observed that there are some gaps in my fundamentals; I'm not yet a cracked engineer as i would like to be, so I will be going back to the basics and building up from there again from now until new year's. Let's see how it goes.
1
1
102
I've observed that there are some gaps in my fundamentals; I'm not yet a cracked engineer as i would like to be, so I will be going back to the basics and building up from there again from now until new year's. Let's see how it goes.
2
180