Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Switching off legacy code using one Symfony com...
Search
Loulier Guillaume
November 07, 2023
Programming
1
110
Switching off legacy code using one Symfony command at a time
Loulier Guillaume
November 07, 2023
Tweet
Share
More Decks by Loulier Guillaume
See All by Loulier Guillaume
Demandez et votre application répondra, la recherche sémantique avec PHP et Meilisearch
guikingone
1
68
Building a semantic search experience using PHP and Meilisearch
guikingone
0
93
Symfony UX et le frontend
guikingone
1
43
K6, stresser son application en douceur
guikingone
1
50
Need to search through your data? Heard about Meilisearch?
guikingone
1
200
Meilisearch
guikingone
1
130
SQLite en production ? Et si vous réévaluiez vos options ?
guikingone
1
990
Dagger, la CI, autrement
guikingone
1
260
Rector, time to refactor your code easily
guikingone
2
340
Other Decks in Programming
See All in Programming
Vibe Codingをせずに Clineを使っている
watany
17
6.3k
DataStoreをテストする
mkeeda
0
290
Laravel × Clean Architecture
bumptakayuki
PRO
0
110
状態と共に暮らす:ステートフルへの挑戦
ypresto
1
700
ウォンテッドリーの「ココロオドル」モバイル開発 / Wantedly's "kokoro odoru" mobile development
kubode
1
150
リアルタイムレイトレーシング + ニューラルレンダリング簡単紹介 / Real-Time Ray Tracing & Neural Rendering: A Quick Introduction (2025)
shocker_0x15
1
310
Make Parsers Compatible Using Automata Learning
makenowjust
2
5.2k
PHP で学ぶ OAuth 入門
azuki
1
210
PHPで書いたAPIをGoに書き換えてみた 〜パフォーマンス改善の可能性を探る実験レポート〜
koguuum
0
170
複雑なフォームの jotai 設計 / Designing jotai(state) for Complex Forms #layerx_frontend
izumin5210
4
1.1k
Vibe Coding の話をしよう
schroneko
11
2.7k
プロダクト横断分析に役立つ、事前集計しないサマリーテーブル設計
hanon52_
2
450
Featured
See All Featured
Building a Modern Day E-commerce SEO Strategy
aleyda
40
7.2k
Site-Speed That Sticks
csswizardry
5
500
How to Ace a Technical Interview
jacobian
276
23k
GraphQLとの向き合い方2022年版
quramy
46
14k
Mobile First: as difficult as doing things right
swwweet
223
9.6k
Building Adaptive Systems
keathley
41
2.5k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
29
1.6k
Bash Introduction
62gerente
611
210k
Automating Front-end Workflow
addyosmani
1369
200k
How To Stay Up To Date on Web Technology
chriscoyier
790
250k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
12k
The Pragmatic Product Professional
lauravandoore
33
6.5k
Transcript
Switching off legacy code using one Symfony command at a
time
Greetings
Hellcome Guillaume Loulier / @Guikingone Lead developer @SensioLabs Works mainly
with PHP and Rust Sometimes, I break things, especially legacy ones (and I like that)
Summary 01 - Legacy code is fun 02 - Migrating,
a far far away dream 04 - Symfony to the rescue 05 - Wrapping up 01
Legacy code is fun
Well, it should
Diving into the joke Refu*toring - The process of taking
a well-designed piece of code and, through a series of small, reversible changes, making it completely unmaintainable by anyone except yourself. Jason Gorman
Let the fun begin A legacy code is just an
abandoned one that generate revenues Maintaining legacy code should be easy At least, until it breaks Never needed to migrate PHP 5 code?
Dealing with technical debt Technical debt is ambiguous Yesterday code
is already outdated, sorry Need to migrate it? Bon chance
Keep dreamin’
I made a dream
Time for a wishlist Tracking, being aware of changes, updating
and deleting A new interface? For which use case? What about this method arguments type? Code spread across repositories?
Sadly What about using a dedicated channel? Or using trigger_error?
Or tools like Sentry, OpenTelemetry and many more? What if we’re in a special architecture?
Symfony?
Well…
The full experience Symfony brings a lot of components Could
we bring them together to help us? Look at Rector, PHPStan and more! What if we could “track & switch off” files?
Time to “Switchoff” Built on top of Symfony components and
nikic/PHP-Parser (chief kiss) Attributes for the win! Analyze, check, switch off, repeat Could be used via the CLI / CI
Want a demo?
What’s next?
To sum it up Handling migration is hard, not to
say boring Symfony could ease the process but lack of tools Relying on a framework is a recipe for failure Each project has its own rules / flaws
What about switchoff? Not fully stable (for now) A Symfony
bundle? (Already planned) An HTML dashboard What about a PHPStan / Rector bridge?
Wrapping up