0018 - Add ADR about Horizontal Migration#26
Conversation
jolelievre
left a comment
There was a problem hiding this comment.
Ok for me except a typo and a detail about public fields from legacy controller
Progi1984
left a comment
There was a problem hiding this comment.
I vote No.
I don't think it's a good idea to add a new migration. Why ? People, simply people.
The developer responsible of this ADR leaves in July. We have less maintainers since one year (some leave the Core Team, some leave the Maintainer Team). So less review, less management of this part. This makes it seem like we are spreading ourselves too thin with the few resources the project has. So it's why I reject this ADR.
|
I don't understand your reasoning @Progi1984. This represents less work to finish the symfony migration, not more work. What's your suggestion? Should we abandon the migration? |
|
I've added further clarification as to why I think this approach makes sense |
I would prefer one migration per page, so that when a fully migrated page is released, the non-migrated ones remain as they were before. This gives more stability as of yet for developers and for the user who knows that when a page is migrated it is converted to the new synfony environment while a page that is not migrated is in the legacy system. A horizontal migration, especially if carried on for a long time due to lack of programmers, could be a real mess. Finding yourself working with a code that is partly migrated and partly not because the refactoring activity is missing does not benefit anyone and does not bring many benefits in my opinion. I am better off working when all the layers managing a given page are either all migrated to the new system or all legacy. |
|
I lean more toward the "No". I was skeptical about this from the beginning. Why?
I don't believe in removing critical things for the ecosystem one by one, such as "in this version, we'll remove Migration is for who? For the merchants? No. We can't possibly fix all the bugs simply because we remove Without going into the details - this strategy means more work for community developers to keep up to date with all the modifications they have in their modules. With the new strategy, it wasn't that hard to make the module compatible with a new Orders page, new Customers page, etc. It seems much more complicated.
If I'm not mistaken, in every stage of the migration, we need complete tests for the pages. Compare it to one thoroughly tested migration of the page.
Who would benefit from removing obsolete systems? In the second stage, you want to:
What's the point of refactoring `Helper's if we're going to remove them in the next stage. You don't want migration to last the next four years, but these stages sound like a "1 year per stage" + massive amount of work that won't be needed. What's the alternative? Focus on migrating pages one by one. Let's take the Permissions configuration page as an example. Was it slow because of the developer? Was it slow because of the difficulties? No. It was slow because of us. Because we failed to deliver reviews, we could not provide proper feedback every time the author needed it. A little history of it: are you sure it is the strategy that is wrong? How can we be sure that the lack of specification for the pages won't slow down the new strategy too? |
I completely agree. I think page by page migration is more clear for developer and users that have to use prestashop. |
jolelievre
left a comment
There was a problem hiding this comment.
A typo and a precision and it's ok for me
|
I had a chance to speak with @eternoendless to understand this concept better. A couple of essential points that help me to change my vote are:
A few additional thoughts:
I'm still not sure if this will help QA, this is why I would like to know their thoughts as soon as possible, but it doesn't block me from giving this a ✅ |
Yes, for me the fundamental points are 3
|
|
To be discussed in another place. |
Co-authored-by: Jonathan Lelievre <jo.lelievre@gmail.com>
|
As I explained to Krystian earlier today, the spirit of this strategy change is to accelerate the migration, which is required to keep the ecosystem interesting for developers. Of course it's preferrable to migrate pages vertically. But doing that will take us too long before we reach the minimum level of a Symfony-based architecture. We cannot migrate pages vertically faster because we don't have enough people to do the specification, development, and review. The gaps in functional knowledge make it even harder to refactor, improve, and test because we don't always know what the expected behavior is. The only way I see to accelerate the migration is to focus on the migration itself so that we can deliver the Symfony features (the critical part at least) as quickly as possible, and defer the refactoring to a second stage so that we can have more time to catch up on the knowledge part. It's like salary. Would you rather work for a whole year and collect all your money on December 31st, or be paid monthly? It's about receiving part of the value as soon as possible. This is why phase 1 consists in migrating the page without refactoring it extensively – only the controller and the routing is changed. Dividing the migration perimeter into smaller stages means that, where a vertical PR changes 80 files (controller, commands, queries, handlers, form types, form theme, template, grid...), a horizontal migration stage 1 PR should include maybe 2 or 3 files (the controller, the router, and maybe some service configuration files). Smaller PRs are easier to review and verify. In phase 1, the view doesn't change one bit: it's exactly the same, driven by the original helpers on the same Smarty theme. This should also reduce the temptation to "fix" any UX or historical functional issue that already existed within the page, one of the main reasons for scope "telescoping" in the past, which made some pages take years to review and validate. This should reduce back-and-forths with product and QA. Initially, I even intended us to simply copy-paste the content of legacy controllers inside Symfony controllers. But after some exploration, we realized that it wasn't possible because the structure of legacy controllers is very complex, override-oriented, tightly coupled to helpers, and globally too hard to make compatible with the Symfony router. Keeping it exactly the same would have required us to create a different kind of Symfony controller – the opposite of my intention. Horizontally migrated controllers are not a different kind of controller, they are the same controllers as the vertical ones. The only difference is that they include a couple of traits that allow the use of Smarty. One more thing: currently, migrated pages are not usually activated by default. I think we should industrialize feature flags so that we can easily merge incomplete or unstable pages behind feature flags and only activate them once we are confident they are stable. This should also streamline the QA process amd reduce the time to merge (and the risk of rebase conflicts). But that proposal needs to be discussed with QA and subject to another ADR. |
matthieu-rolland
left a comment
There was a problem hiding this comment.
I vote "yes" 👍
Thank you all for sharing your reasoning and counter-points, and @matks for answering my questions
|
Blank vote for me, I'm trusting backend developers if they feel like it will be easier for them to maintain/improve this side of the project |
|
|
|
@sowbiba any comment from you? |
|
Hello, I think everyone was able to provide his opinion and vote We have 6 YES, 3 Blank and 1 NO so the majority has said YES. Consequently this ADR is accepted. Thank you everybody. Also QA team submitted feedback about it and after discussing together they agreed to it through the person of @sarahdib |
Vote