DDEV advanced – mutagen, custom services, hooks, shared team configuration
DDEV out of the box is fast to set up but the defaults leave performance on the table. Mutagen file sync, custom services, project hooks, and shared team configuration in version control reduce friction for everyone on the project. I show the advanced DDEV setup I use on large Magento 2 projects with multiple developers.
- Published in Środowiska
Production to dev migration – mydumper, GDPR anonymisation, DDEV automation hooks
Copying a production database to a development environment without a proper process is either a GDPR violation or a security incident waiting to happen. I show a complete pipeline: fast dump with mydumper, automatic anonymisation of personal data, and DDEV hooks that make the sanitised database available to the whole team with a single command.
- Published in Środowiska
PHP Fibers deep dive – own scheduler, cooperative multitasking, parallel HTTP requests
PHP 8.1 introduced Fibers as a foundation for cooperative multitasking. Most developers use them only indirectly through ReactPHP or Amp. But understanding Fibers at the mechanism level unlocks the ability to build your own concurrency primitives. I show how Fibers work, implement a minimal cooperative scheduler, and use it to run parallel HTTP requests without a framework dependency.
- Published in PHP
GraphQL batch loading – BatchServiceContractResolverInterface, cache tags, N+1 fix
The N+1 problem is especially acute in GraphQL because resolvers compose independently without awareness of each other. A query for 20 products that each have categories will trigger 20 separate category queries without batching. Magento 2’s BatchServiceContractResolverInterface and the DataLoader pattern solve this. I show both approaches with cache tag integration.
- Published in Magento / Adobe Commerce
