Welcome to the Age of Static Analysis and Automated Refactoring
Programmers live a dangerous life. It’s so easy to make mistakes and mess things up, so we like to limit the scope of our changes. There may be large parts of a code base that we don’t dare to touch at all. It makes us somewhat conservative when it comes to large upgrades or refactorings.
If only we could have a tool that has our back when we make changes that influence remote parts of a code base, or that can even make those changes for us. One that tells us about mistakes immediately after we make them. And maybe even one that fixes our problems, without the risk of making a mistake.
Moving Forward with Legacy Code
Yes, progress is possible. Even in the worst legacy code projects. Yes, you’ll need courage, and discipline, but when you stick to the plan, you can make really big changes.
Part I: The Mikado Method
In part I of this tutorial we’ll practice these virtues by applying The Mikado Method, also known as: Just Do It, or Break things fast (but learn from it). This method can be applied in the small and in the large.
Static Analysis and Automated Refactoring
With PHPStan you can catch many programming mistakes before they reach your production server. Rector can fix many programming mistakes for you.
Since Rector relies heavily on PHPStan, the first step towards automated refactoring is static analysis. This training focuses on setting up PHPStan for your project, making it part of your development workflow, and extending it with your own rules. At the end of the program we kickstart automated refactoring with Rector.
Rector Fireside Chat
In this talk Matthias Noback and Tomas Votruba, the authors of the book “Rector - The power of automated refactoring”, will tell you what Rector is, how you can use this tool, and what amazing things you can achieve with it.
You’ll get a taste of Rector and how it can be used in everyday situations to move your code forward. We’ll take time to answer questions from the audience as well.
Design patterns for modernizing legacy code bases
- 2021-06-17 The Legacy of SoCraTes 5th Edition
Decoupling from infrastructure
Most application code freely mixes domain logic with infrastructural concerns. Models are directly tied to the relational database of the project, use cases are inseparable from their web controllers, and external services are used without an appropriate abstraction. This limits your ability to design the application in a domain-driven, test-first way.
What we need is a way to separate core code from infrastructure code. And that’s surprisingly easy. All the design patterns have already been invented for that. Until we run out of time, we’ll keep (re)discovering patterns like Controller, Application Service, Entity, Read Model, Domain event, and so on. These patterns can be used to establish a testable, portable application core, with a focus on behavior, instead of data.
Advanced Web Application Architecture
This talk will be an in-depth discussion of the three layers that constitute a layered architecture: the Domain, Application, and Infrastructure layer. We’ll discuss how hexagonal architecture (“ports & adapters”) will be a great addition to the layering style.
You’ll find out how you can:
- Keep your domain model clean, free from infrastructural concerns,
- Model your application’s use cases as application services,
- Connect your application and domain layers to the world outside, using port adapters.
- 11/27/2019 TechNight at Developers.nl, Rotterdam website video (Dutch)
- 11/21/2019 SymfonyCon, Amsterdam website
- 11/13/2019 PHP Barcelona website video
- 11/11/2019 Docplanner meetup, Barcelona website
- 10/24/2019 Full Stack Europe, Antwerp website
- 10/15/2019 Tech Tuesday meetup at Freshheads, Breda website
- 05/09/2019 Full Stack meetup at Way2Web, Utrecht website slides
Building Autonomous Services
In this workshop we’ll dive into the topic of Autonomous Service development, with a sandbox project containing several interdependent services. These projects send messages to each other, and they call each other to retrieve data. In other words, they’re not autonomous at all. We’ll figure out some ways in which we can invert dependencies and leverage a messaging solution to achieve autonomy after all.
In a relatively short period you’ll get acquainted with the basics of asynchronous integration, CQRS, domain events and integrating bounded contexts.
Advanced Web Application Architecture training
This workshop covers all of the three layers from what is known as a layered architecture: the domain, application and infrastructure layer. You’ll learn how to:
- Design a clean domain model
- Model your application’s use cases as application services
- Connect those well-designed layers to the world outside
Protecting your high quality domain model can be accomplished by applying a so-called ports & adapters or hexagonal architecture.
Some of the keywords for this workshop: aggregate design, domain events, application services, commands, queries and events, eventual consistency, layered architecture, ports & adapters, hexagonal architecture.