@pbourgau is starting the game with a live refactoring of Legacy Code with "Golden Master" and the @mikadomethod 💪
"Golden Master" takeaways:

- enforces to distinct refactoring and new features
- don't push them in your CI
- they're here to help you refactor
The @mikadomethod helps you not getting lost when you're working with Legacy Code.

It'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/  to build his Mikado map.

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
Things are starting to get crossed off the list.

We'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't need to ask permission
- you can share the graph with others
Next up is @afilina 🎙

She'll share her amazing expertise in working with very old Legacy codebases!

#legacyCode
Beware the full rewrite.

It's a trap.
"Let's rewrite this old Legacy system!"

Pick 10 new technologies to try out on the new system

Fail because of too many moving parts ☠

💡 Don't try too many things at once
A more sustainable approach to migrate a codebase: a *progressive* rewrite

Don'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
Unused endpoints are dead code. It slows you down.

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 😅

Thanks @adibolb is on it!

#legacyOfSocrates
And we're back!

@ToF_ is now speaking: "Stop managing technical debt and start solving problems again"

Let's focus on the end-users a bit ❤️

#legacyOfSocrates
It's an worthy exercise to deconstruct the heuristics, context and objectives behind a conflict

#legacyOfSocrates
"Why did they put the POC in production?"

Well, that's a typical conflict of objectives

#legacyOfSocrates
Align your state of the art

Bring all people together, give 'em post-its and discover the hidden conflicts

#legacyOfSocrates
Great books to read 👌

#legacyOfSocrates
Our next great speaker is @alexboly

He'll present a way to refactor Legacy Code using pure functions 🎩

#legacyOfSocrates
Alex is mentioning the Strangler Pattern

As a reminder, @w3ltraumpirat did a great talk on this in the last edition:
Alex'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
It's nice when functions are boring

When you go back home, you don'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
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 😉

#legacyOfSocrates
Optimize for the flow of the work, not individual outputs

That'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
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't have to keep everything in YOUR mind

#legacyOfSocrates
Typical scenario where mob programming shines

@WoodyZuill speaks from experience here
It started with a team of 6 and:

- pair-programming
- refactoring
- introducing tests

Learning to do "solo" work as a team

#legacyOfSocrates
A few reasons why teams still work in mob programming

#legacyOfSocrates
And we're off!

That was great. We'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
You can follow @nicoespeon.
Tip: mention @twtextapp on a Twitter thread with the keyword “unroll” to get a link to it.

Latest Threads Unrolled: