Starting soon!
Join us on https://www.crowdcast.io/e/the-legacy-of-socrates--/register
Password:">https://www.crowdcast.io/e/the-leg... GoLegacyOfSoCraTes
#legacyCode #remote #conference
Join us on https://www.crowdcast.io/e/the-legacy-of-socrates--/register
Password:">https://www.crowdcast.io/e/the-leg... GoLegacyOfSoCraTes
#legacyCode #remote #conference
@pbourgau is starting the game with a live refactoring of Legacy Code with "Golden Master" and the @mikadomethod
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐ช" title="Flexed biceps" aria-label="Emoji: Flexed biceps">
"Golden Master" takeaways:
- enforces to distinct refactoring and new features
- don& #39;t push them in your CI
- they& #39;re here to help you refactor
- enforces to distinct refactoring and new features
- don& #39;t push them in your CI
- they& #39;re here to help you refactor
The @mikadomethod helps you not getting lost when you& #39;re working with Legacy Code.
It& #39;s a recipe you can follow to get your way out.
Now @pbourgau is about to show a live demo of it
https://abs.twimg.com/emoji/v2/... draggable="false" alt="โณ" title="Flag in hole" aria-label="Emoji: Flag in hole">
It& #39;s a recipe you can follow to get your way out.
Now @pbourgau is about to show a live demo of it
Philippe uses https://coggle.it/ ">https://coggle.it/">... to build his Mikado map.
It seems simple and powerful
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐" title="Ok hand" aria-label="Emoji: Ok hand">
It seems simple and powerful
"The Parking technique"
A place to put things you think you could improve w/ the code, but that are not related to your current goal
Helps you stay focus and get things out of your head
A place to put things you think you could improve w/ the code, but that are not related to your current goal
Helps you stay focus and get things out of your head
Things are starting to get crossed off the list.
We& #39;re getting out of the tunnel!
Also: commit frequently
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐" title="Winking face" aria-label="Emoji: Winking face">
We& #39;re getting out of the tunnel!
Also: commit frequently
Key takeaways from the Mikado Method:
- you can cut refactoring in parts small enough so you don& #39;t need to ask permission
- you can share the graph with others
- you can cut refactoring in parts small enough so you don& #39;t need to ask permission
- you can share the graph with others
Next up is @afilina
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐" title="Studio microphone" aria-label="Emoji: Studio microphone">
She& #39;ll share her amazing expertise in working with very old Legacy codebases!
#legacyCode
She& #39;ll share her amazing expertise in working with very old Legacy codebases!
#legacyCode
"Let& #39;s rewrite this old Legacy system!"
Pick 10 new technologies to try out on the new system
Fail because of too many moving parts
https://abs.twimg.com/emoji/v2/... draggable="false" alt="โ " title="Skull and crossbones" aria-label="Emoji: Skull and crossbones">
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐ก" title="Electric light bulb" aria-label="Emoji: Electric light bulb"> Don& #39;t try too many things at once
Pick 10 new technologies to try out on the new system
Fail because of too many moving parts
2 useful tools to work with Legacy PHPย codebases:
- PHP CodeSniffer https://github.com/squizlabs/PHP_CodeSniffer
-">https://github.com/squizlabs... Rector https://github.com/rectorphp/rector">https://github.com/rectorphp...
- PHP CodeSniffer https://github.com/squizlabs/PHP_CodeSniffer
-">https://github.com/squizlabs... Rector https://github.com/rectorphp/rector">https://github.com/rectorphp...
A more sustainable approach to migrate a codebase: a *progressive* rewrite
Don& #39;t freeze developments
Do this by module
The URL is an interface which can be implemented by different applications (modules)
Don& #39;t freeze developments
Do this by module
The URL is an interface which can be implemented by different applications (modules)
Refactor code when you need to change it
@martinfowler "Refactoring" book is a gold mine: https://martinfowler.com/books/refactoring.html">https://martinfowler.com/books/ref...
@martinfowler "Refactoring" book is a gold mine: https://martinfowler.com/books/refactoring.html">https://martinfowler.com/books/ref...
Unused endpoints are dead code. It slows you down.
Spot abandoned code and get rid of it.
Spot abandoned code and get rid of it.
Remote conferences have their own set of challenges.
Currently dealing with technical issues so we can get @ToF_ started
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐
" title="Smiling face with open mouth and cold sweat" aria-label="Emoji: Smiling face with open mouth and cold sweat">
Thanks @adibolb is on it!
#legacyOfSocrates
Currently dealing with technical issues so we can get @ToF_ started
Thanks @adibolb is on it!
#legacyOfSocrates
And we& #39;re back!
@ToF_ is now speaking: "Stop managing technical debt and start solving problems again"
Let& #39;s focus on the end-users a bit
https://abs.twimg.com/emoji/v2/... draggable="false" alt="โค๏ธ" title="Red heart" aria-label="Emoji: Red heart">
#legacyOfSocrates
@ToF_ is now speaking: "Stop managing technical debt and start solving problems again"
Let& #39;s focus on the end-users a bit
#legacyOfSocrates
It& #39;s an worthy exercise to deconstruct the heuristics, context and objectives behind a conflict
#legacyOfSocrates
#legacyOfSocrates
"Why did they put the POC in production?"
Well, that& #39;s a typical conflict of objectives
#legacyOfSocrates
Well, that& #39;s a typical conflict of objectives
#legacyOfSocrates
Align your state of the art
Bring all people together, give & #39;em post-its and discover the hidden conflicts
#legacyOfSocrates
Bring all people together, give & #39;em post-its and discover the hidden conflicts
#legacyOfSocrates
Great books to read
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐" title="Ok hand" aria-label="Emoji: Ok hand">
#legacyOfSocrates
#legacyOfSocrates
Our next great speaker is @alexboly
He& #39;ll present a way to refactor Legacy Code using pure functions
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐ฉ" title="Top hat" aria-label="Emoji: Top hat">
#legacyOfSocrates
He& #39;ll present a way to refactor Legacy Code using pure functions
#legacyOfSocrates
Slides are available here:ย https://www.slideshare.net/alexboly/refactor-legacy-code-through-pure-functions
https://www.slideshare.net/alexboly/... href="https://twtext.com//hashtag/legacyOfSocrates"> #legacyOfSocrates
https://www.slideshare.net/alexboly/... href="https://twtext.com//hashtag/legacyOfSocrates"> #legacyOfSocrates
Alex is mentioning the Strangler Pattern
As a reminder, @w3ltraumpirat did a great talk on this in the last edition: https://www.youtube.com/watch?v=jm_ZBc5z6B0">https://www.youtube.com/watch...
As a reminder, @w3ltraumpirat did a great talk on this in the last edition: https://www.youtube.com/watch?v=jm_ZBc5z6B0">https://www.youtube.com/watch...
Alex& #39;s approach follows 3 steps:
1. Refactor code to pure functions
2. Write data-driven or property-based tests on the pure functions
3. Refactor pure functions to classes (or something else)
#legacyOfSocrates
1. Refactor code to pure functions
2. Write data-driven or property-based tests on the pure functions
3. Refactor pure functions to classes (or something else)
#legacyOfSocrates
It& #39;s nice when functions are boring
When you go back home, you don& #39;t expect side-effects when you turn the lights on
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐ก" title="Electric light bulb" aria-label="Emoji: Electric light bulb">
#legacyOfSocrates
When you go back home, you don& #39;t expect side-effects when you turn the lights on
#legacyOfSocrates
"Any program can be used as a combination of pure functions & I/O functions"
Yes!
Domain vs. Infra => keep them separated
#legacyOfSocrates
Yes!
Domain vs. Infra => keep them separated
#legacyOfSocrates
Finally, @WoodyZuill is talking about #MobProgramming and how that can help you work with Legacy Code
Which is, to be honest, most of the code we need to work with
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐" title="Winking face" aria-label="Emoji: Winking face">
#legacyOfSocrates
Which is, to be honest, most of the code we need to work with
#legacyOfSocrates
Optimize for the flow of the work, not individual outputs
That& #39;s a mindset shift
#legacyOfSocrates
That& #39;s a mindset shift
#legacyOfSocrates
"The driver is a smart input device" to the computer
Like, a smart keyboard
The rest of the team thinks, navigates
#legacyOfSocrates
Like, a smart keyboard
The rest of the team thinks, navigates
#legacyOfSocrates
Navigators share the cognitive load
You can relax: front-end experts will catch the front-end issues, SQL experts will remember the database exports, etc.
You don& #39;t have to keep everything in YOUR mind
#legacyOfSocrates
You can relax: front-end experts will catch the front-end issues, SQL experts will remember the database exports, etc.
You don& #39;t have to keep everything in YOUR mind
#legacyOfSocrates
It started with a team of 6 and:
- pair-programming
- refactoring
- introducing tests
Learning to do "solo" work as a team
#legacyOfSocrates
- pair-programming
- refactoring
- introducing tests
Learning to do "solo" work as a team
#legacyOfSocrates
And we& #39;re off!
That was great. We& #39;ll take some rest, publish the videos and plan a 3rd edition some time later
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐" title="Thumbs up" aria-label="Emoji: Thumbs up">
Thank you @adibolb for dealing with the tech side and @pbourgau @afilina @ToF_ @alexboly @WoodyZuill for the amazing talks
https://abs.twimg.com/emoji/v2/... draggable="false" alt="๐" title="Folded hands" aria-label="Emoji: Folded hands">
https://abs.twimg.com/emoji/v2/... draggable="false" alt="โค๏ธ" title="Red heart" aria-label="Emoji: Red heart">
#legacyOfSocrates
That was great. We& #39;ll take some rest, publish the videos and plan a 3rd edition some time later
Thank you @adibolb for dealing with the tech side and @pbourgau @afilina @ToF_ @alexboly @WoodyZuill for the amazing talks
#legacyOfSocrates