Gaining the ability to modify the code architecture to make it more extendable, readable and testable by applying design patterns.
- come back with ideas for changes in the organization of work in their teams to enable continuous improvement of existing legacy code to clean code
- practice code refactoring towards design patterns
- learn more about selected design patterns
- experience whether, when and how to work on reducing technical debt
Participants will practice live refactoring by following the trainer working on the continuous improvement of code quality. These improvements will vary from the smallest changes resulting in better readability and saving time needed to understand the code, upto the introduction of design patterns. Design patterns enable the use of proven and repeatable architectural solutions for similar groups of challenges.
Clean Code is a very famous term that was coined by Uncle Bob. It describes what good code should look like so it is readable,maintainable and maintainable. T
During the workshop, the concept of the Refactoring Pyramid will be discussed, which defines groups of issues for working with existing legacy code as interdependent layers.
- Clean flow of logic
- Smaller method extraction
- Building smaller classes
- Looking for design patterns
- Clean Architecture
Design patterns are common solutions for similar groups of problems. They have proven useful and helpful due to their reusability and effectiveness.
When the number of lines of code is increasing, there is usually one of the design patterns missing. That’s when we think “if only I had applied the Strategy / State / Chain of Responsiblity design pattern earlier instead of all these nested if-else statements…”. And it is these insights that lead us to refactor into relavant design patterns at the right time – not too early and not too late.
The remaining 25% of the training is devoted to the inspirational and motivational part, which allows you to look for improvements on how to make cleaning existing legacy code everyday habit and become part of the software development process. This, in turn, will enable to keep technical debt under control.
This training is mainly about refactoring to clean code and patterns – and about code architecture appropriate at the moment for current requirements. Different teams may prefer different architectures, and the goal of this training is to show how easily we can re-architect code to meet new business requirements.
Day 1 – training content Refaktoryzacja do Czystego Kodu
Part 1 – Cleaning Code in small steps
- Review of Legacy Code project
- It’s only one more “if” statement…
- Review of automated refactorings in IntelliJ
- Live refactoring in small steps
- Habits of personal effectiveness for code quality
- Clean Code & Pyramid of Refactoring
- SOLID Principles & Pyramid of Refactoring
Part 2 – Clean Code to ease extendability and testability
- Review of “Extended” Legacy Code project
- New Requirements + No Cleaning = (More) Dirty Legacy Code
- More Requirements are coming…
- Live refactoring towards extraction of extension points
- Clean code is extendable code
- Habits of team effectiveness for code quality
- Implementation of additional functionality using TDD
Main topics for the remaining days
- practice of code refactoring to design patterns
- linking how your software development process impacts final code quality
Legacy code refactoring completed with the implementation of the following design patterns
- Interpreter
- Chain of Responsibility
- Fluent Builder
- Iterator
- State
Legacy code refactoring completed with the implementation of the following design patterns
- Template
- Bridge
- Composite
- Factory Method
- Abstract Factory
- Adapter