Pull The Plug Modeling: A reset before you model

I work as a software architect for an Indigenous organization. Twice a year, we get together offsite for a team retreat. We reflect on our values, challenge our assumptions, and reconnect as a team. We often invite an Elder to open the event with a prayer. I am not a spiritual person. But I have always been struck by what that prayer accomplishes. Everyone arrives carrying something different. Different concerns, different frames of reference, different languages. The prayer does not erase those differences. It suspends them, just long enough for everyone to find common ground before the work begins. ...

March 25, 2026 · 7 min · Maxime Gosselin

Proposing a PSR for PDO Providers

Last week I published In Search of the Missing PDO Interface, arguing that PDO should have an interface. The discussion on r/PHP convinced me I was solving the wrong problem. The real problem When you pass a \PDO instance to a library, you hand over a fixed connection, not access to one. The library now holds something it cannot reconnect if the connection drops, cannot swap out, and cannot wrap transparently. You have surrendered control over the connection lifecycle. ...

March 10, 2026 · 2 min · Maxime Gosselin

Parallel Task Execution in PHP... with Go

PHP is a blocking language. When you loop over a batch of images and resize each one sequentially, you wait for every conversion to finish before starting the next. For small batches that is acceptable. For anything larger, it becomes a bottleneck. The natural instinct is to reach for a parallelism solution inside PHP. But I have come to prefer a different approach: accept that PHP is blocking, and delegate the responsibility of parallelism to a language that does it beautifully. ...

March 7, 2026 · 6 min · Maxime Gosselin

In Search of the Missing PDO Interface

Update: This post led to a follow-up. Read Proposing a PSR for PDO Providers for a more accurate framing of the problem and a concrete proposal. PHP’s PDO extension has been the standard database abstraction layer since PHP 5.1. It does its job well: it provides a unified API over multiple database drivers and handles the low-level details of connecting, querying, and fetching results. Yet, after nearly two decades, PDO is still missing something fundamental: an interface. ...

March 1, 2026 · 9 min · Maxime Gosselin

Using the Middleware Pattern to Extend PHP Libraries

If you have been writing PHP professionally for the past few years, you have almost certainly encountered PSR-15. It formalized the concept of middleware for HTTP request handling, and it changed the way we think about extensibility in PHP applications. But here is the thing: the idea behind PSR-15 is too good to leave confined to HTTP. This article is for PHP developers who maintain libraries. If you have ever exposed an extension point in your library using the Decorator pattern, I want to show you a better default. ...

February 27, 2026 · 7 min · Maxime Gosselin

Implementing a DCB-Compliant Event Store in SQLite

Dynamic Consistency Boundary doesn’t require specialized infrastructure. A four-column SQLite table is enough. The DCB specification defines the minimal feature set an Event Store must provide to support Dynamic Consistency Boundary. This article walks through how to implement it using SQLite, requirement by requirement. This approach relies on SQLite’s global file-level lock to guarantee consistency. It cannot be applied as-is with MariaDB, MySQL, or PostgreSQL. See the appendix for details. The READ Requirements Let’s go through each READ requirement from the spec and map it to a column. ...

February 25, 2026 · 9 min · Maxime Gosselin

Backslash: Event Sourcing in PHP, Built for the Real World

Event sourcing is often overlooked A lot of people hesitate to adopt event sourcing. The literature is full of distributed systems, eventual consistency, sophisticated event stores, and architectural diagrams that look like they belong at Netflix. It’s easy to walk away thinking this is not for me. Most of that complexity is self-inflicted. None of it is inherent to event sourcing. It’s a set of choices, and you can make different ones. ...

February 20, 2026 · 4 min · Maxime Gosselin