Clean Code and Design Principles in Action: develop quality applications, faster
DATE: Thursday the 19th of November
As developers, we often feel that we are always asked for more: more features, more bugfixes, more code to get our application done, faster. In the workshop you’ll learn first hand how applying Clean Code and Design Principles will help you complete solid & maintainable applications in less time.
Take a look to the Special Packages:
– “1 Workshop + Conference Ticket”: we offer 15% DISCOUNT on the total price!
– “2 Workshops + Conference Ticket”: we offer 20% DISCOUNT on the total price!
Click here to know how to obtain these discounts.
LANGUAGE
Italian
LEVEL
Medium
DURATION
The workshop is full-day (8 hours) from 9:00 to 18:00, with one hour lunch break.
CHECK IN: 8:30 – 9:00
LOCATION
Politecnico di Milano – Bovisa | Building BL25, aula 0.12
Via R. Lambruschini, 4 – Milano
PRICES:
Every 8 hours workshop’s ticket is fixed:
– to 125 € until the 23rd of September;
– to 160 € from the 24th of September to the 15th of November
– to 190 € from the 16th of March to the end of the sales.
Take a look to the Special Packages:
– “1 Workshop + Conference Ticket”: we offer 15% DISCOUNT on the total price!
– “2 Workshops + Conference Ticket”: we offer 20% DISCOUNT on the total price!
Click here to know how to obtain these discounts.
CARLO BONAMICO
Carlo’s passion for Software began with a C128, then grew with Linux, Java/JavaScript, web & enterprise apps, and now cloud & security. After a PhD and research experience at the University of Genova and the CNIT National TLC Research Consortium, and an exciting time at startup Eptamedia, he’s now a Solution Architect and Senior Trainer at NIS s.r.l.. His personal communication style as an architect and trainer, both technically precise and able to present in an engaging way complex topics to an heterogeneous audience has been appreciated online and at many events from Devoxx to Codemotion.
ABSTRACT
We are often asked for more features, more bugfixes, faster. But is “running” always the fastest way to get things done? For a mountain climber, “running” means more mistakes, falling off more often,thus proceeding more slowly. So like a climber gets to the top through a continuous chain of small, safe steps, we can improve coding by making design & implementation steps clean, safe and incremental. In the workshop, starting from concrete examples, you will learn first hand how applying Clean Code and Design Principles will help you complete more solid & maintainable applications in less time
TABLE OF CONTENTS
How does our code become unmanageable? A practical example
– fast-forward demo through the life of an (apparently) trivial function
– the effects: code-writing time vs application-ready time
– what happens after 6 months?
– why this happens? the “deadly sins” of development (cut & paste,
optimization lust, haste, false savings, naming avarice, trial and
error wrath, my code is perfect pride, making it right is too hard –
discouragement)
What can we do about that? Clean Code, Design Principles and Lean to the rescue
– improving our code
– improving our design
– practice, practice, practice and continuous / daily improvement (Kaizen)
Clean Code by example: key concepts
Concept 1 – Naming
-reading code vs writing code
– what is a good name?
– same but different: the importance of conventions
– be meaningful
– aside: commit messages
Concept 2 – Formatting
– making code readable
– making code diff-friendly & commit-friendly
– making code modification-friendly
Concept 3 – What’s in a good function?
– single responsibility
– separing inputs from outputs
– if you have to do 3 things, make 4 functions
– primitives and orchestrators
Concept 4 – What’s in a good class? Design Principles
– Single Responsibility Principle
– collaborating with other classes
– composition vs inheritance (and the Open/Closed principle)
– Dependency Injection
– interfaces and the importante of Contracts
Concept 5 – Making our code Testable
– avoid statics
– testable code vs good design
Concept 6 – Making debug and troubleshooting easier
– one task – one statement
– make return values visible
– logging
Concept 7 – Refactoring
– from bad code to good code
– in steps
– learn your IDE refactoring tools
– The “Boy Scout Rule”
– Why we need unit tests?
Rewriting the initial example in a cleaner way
So what did we just do? Understand the principles
– the relationship between quality and productivity
– the need for a continuous chain of small, safe steps of design &
implementation
Incremental development and evolutionary design
– how to do everything incrementally
– Separation of Concerns in practice: ask yourself questions!
– incremental implementation: in-application Mocks & the Walking
Skeleton approach
– how to keep track of what you do and what is missing
– how to manage incremental commits
A more complex example – applying the method to real-world problems
– the feedback loop
– splitting the problem
– getting more feedback
– getting feedback more frequently
– model the problem
– avoid trial and error, but if you need it, do it fast
How to continue by yourself: references for further learning
– Principles of Package Design
– More on TDD
For each module, hands-on lab will include
– quizzes (which of these variants is better? trade-offs)
– interactive examples to complete and modify in an online IDE
TRAINING OBJECTIVES
– Understand the basic dynamics of software development and particularly the relationship between quality and productivity
– Learn the basic principles of Design and where they are applicable
– Learn what Clean Code means
– Become able to apply these principles in your daily work
– Get the “Incremental” mindset
– Learn to constanlty refactor
– Become better at troubleshooting and debugging code
WHO THE WORKSHOP IS DEDICATED TO?
Basically, to all developers! Independently from the language / platform you are developing on, and from your expertise level, if you are interested in improving your approach to coding, and develop higher quality applications with more productivity, this workshop is for you.
PREREQUISITES NEEDED FROM ATTENDEES
Working knowledge and practical experience in one programming language (you should be able to write/compile/test/debug by yourself a program which reads and parses input and presents output either on the command line or in a simple GUI). Basic knowledge of HTTP.
HARDWARE AND SOFTWARE REQUIREMENTS
Laptop Web Browser (Chrome or Firefox) Text Editor (Sublime, Atom, Visual Studio Code,…) and/or IDE (Eclipse, NetBeans, Intellij, Visual Studio,.. )
The workshop will be held only if the minimun number of attendees is reached.
Take a look to the Special Packages:
– “1 Workshop + Conference Ticket”: we offer 15% DISCOUNT on the total price!
– “2 Workshops + Conference Ticket”: we offer 20% DISCOUNT on the total price!
Click here to know how to obtain these discounts.