Migrating from CodeIgniter |
[eluser]Peter Denk[/eluser]
I'm considering to migrate a medium-size project written with CodeIgniter to another framework. One that is or soon will be in "stable development", where things get updated at a slow but steady pace. What would be the best option from your experience when migrating? Kohana? FuelPHP? Laravel? Zend? Yii? Symphony? It is with sadness that I ask this question but there has been a) no major version update in 2-3 years (2.0 jan 2011, 2.1 nov 2011) b) not one word from EllisLab in the last five months about the future of CodeIgniter. c) no reply to the e-mails I've sent EllisLab. So therefor my conclusion is that it might be time to move on if nothing happens within the near future.
[eluser]noideawhattotypehere[/eluser]
I moved to Laravel. I was thinking about FuelPHP too but Laravel just looks so good and clean, and i love its ORM
[eluser]Peter Denk[/eluser]
[quote author="noideawhattotypehere" date="1386756510"]I moved to Laravel. I was thinking about FuelPHP too but Laravel just looks so good and clean, and i love its ORM[/quote] Did you migrate any code or did you only start using Laravel for new projects?
[eluser]Otemu[/eluser]
Hi, I haven't had any experience of migrating from Codeigniter to Laravel, I have seen a good topic here on stack with other people experiences which might help you make a choice if you decide to go the Laravel route.
[eluser]noideawhattotypehere[/eluser]
[quote author="Peter Denk" date="1386757364"][quote author="noideawhattotypehere" date="1386756510"]I moved to Laravel. I was thinking about FuelPHP too but Laravel just looks so good and clean, and i love its ORM[/quote] Did you migrate any code or did you only start using Laravel for new projects?[/quote] No, i only moved with new projects to Laravel. IMO there is no point moving a finished project just for the sake of a new framework. If something is finished and does its job, why change it? Not sure if i would be even migrating half-done project. Just use it in the future i guess thats easiest way to change frameworks
[eluser]jonez[/eluser]
[quote author="Peter Denk" date="1386720915"]I'm considering to migrate a medium-size project written with CodeIgniter to another framework. One that is or soon will be in "stable development", where things get updated at a slow but steady pace. What would be the best option from your experience when migrating? Kohana? FuelPHP? Laravel? Zend? Yii? Symphony? It is with sadness that I ask this question but there has been a) no major version update in 2-3 years (2.0 jan 2011, 2.1 nov 2011) b) not one word from EllisLab in the last five months about the future of CodeIgniter. c) no reply to the e-mails I've sent EllisLab. So therefor my conclusion is that it might be time to move on if nothing happens within the near future. [/quote] You can download CI3 from GitHub, it's stable and includes a lot of fixes. Personally I'd recommend using it over swapping to a new framework unless there's a feature you absolutely need. I found myself in a similar situation recently due to a bug in CI2 with sessions. After reviewing a number of frameworks I found Laravel to be the obvious replacement. I created a few test projects to see what it was like and personally I wasn't a fan. Mind you I don't have much experience with Laravel but the idea that I'd have to write routes manually really annoyed me and feels like a step backwards. Something about their tagline "a framework for web artisans" makes me wonder why they have to try so hard. Laravel is basically a mash of Symphony plugins which is odd but apparently it works quite well. And you have to use composer, yuk. I upgraded to CI3 which fixed the issue I had with sessions and never looked back. At the end of the day what it comes down to is this: which framework solves your problems and enables you to keep a productive workflow. For me that was CI, my project doesn't need name spacing, dependency management, or anything else that Laravel offers over the others. Is there something your app needs that you can't do in CI and you can do easily in another framework? If the answer is yes, then swap. If it's not upgrade to CI3, you're effort would be better suited elsewhere.
[eluser]Alucemet[/eluser]
[quote author="jonez" date="1386765984"]You can download CI3 from GitHub, it's stable and includes a lot of fixes. Personally I'd recommend using it over swapping to a new framework unless there's a feature you absolutely need. I found myself in a similar situation recently due to a bug in CI2 with sessions. After reviewing a number of frameworks I found Laravel to be the obvious replacement. I created a few test projects to see what it was like and personally I wasn't a fan. Mind you I don't have much experience with Laravel but the idea that I'd have to write routes manually really annoyed me and feels like a step backwards. Something about their tagline "a framework for web artisans" makes me wonder why they have to try so hard. Laravel is basically a mash of Symphony plugins which is odd but apparently it works quite well. And you have to use composer, yuk. I upgraded to CI3 which fixed the issue I had with sessions and never looked back. At the end of the day what it comes down to is this: which framework solves your problems and enables you to keep a productive workflow. For me that was CI, my project doesn't need name spacing, dependency management, or anything else that Laravel offers over the others. Is there something your app needs that you can't do in CI and you can do easily in another framework? If the answer is yes, then swap. If it's not upgrade to CI3, you're effort would be better suited elsewhere.[/quote] After being a dev for more than a decade, it's now easy to see the warning signs of when a project is going to die. To me CodeIgniter has been showing those signs for a couple of years. Sure, it's struggling to stay alive while on its deathbed. That doesn't instill confidence though. I know I'm not starting any new CI based apps again, and I would certainly not recommend a CI app to any of my customers. I'd say the framework OP migrates to is not mission critical. I'd probably choose Symfony or Laravel if I didn't want to use my own private framework.
[eluser]kwoodfriend[/eluser]
I would suggest that you start taking your current application and rewriting the individual parts so they are as framework independent as possible. For any dependencies your components need, I would start pulling in Composer packages and use those, instead of CI's. Avoid CI classes as much as possible. This will make your application much more portable. If you move to another framework, and don't like it, it will also be easier to change again. You might need to write a some glue code to get the packages working with CI, but it will be worth it in the end. Also, don't make use of CI's singleton pattern and avoid use of "$this->{library_name || model_name}" where possible. For models, instantiate them manually (i.e. $foo = new Foobar()) and don't load them via CI's loader class. I would try to get your use of CI down to a few responsibilities: - Routing - Views - Maybe a few others? If you can, clean up your controllers so they offload a lot of their work to other objects or private/protected methods. A good chunk of CI's helpers are independent, and can probably be brought along with your application to another framework. Of the frameworks you listed, I only have experience w/ Laravel and Symfony, so I cannot speak for the others, but a checklist I would use when choosing: - Must be Composer based. - Should be split up into relatively independent components. This will be useful as you can start pulling in these components now, before switching frameworks. - Should have a published release schedule. I know Symfony has one. Laravel has one that mimics Symfony's. You don't need an exact schedule, like Ubuntu has, just having knowledge of a general time frame for the next release is very helpful. - Decent documentation. Depending on your skill level, some frameworks might not have adequate documentation.
[eluser]jonez[/eluser]
[quote author="Alucemet" date="1386838651"]I know I'm not starting any new CI based apps again, and I would certainly not recommend a CI app to any of my customers.[/quote] I don't understand that sentiment. I'm probably starting to sound like a broken record but... 1. If you've been a dev for 10y then you know as well as I do that legacy code is everywhere. No matter how hard you try you will never escape it. Developers should not be spending effort trying to "future proof" an app because it's not possible and never will be. 2. Every task requires a different solution. CI works for my needs, it may not for you, but that question is project/goal specific. No framework should ever be considered ideal for every task. Quote:- Must be Composer based.3. Why is Composer so important? How many 3rd party library's are you guys using..? Other then API integrations (which are already easy) what could you possibly need dependency management like that for? If your app already works in CI what are you going to gain by changing? If your project grew and now needs namespaces, swap. If you're having trouble managing dependencies and need composer, swap. CI is faster then both Symphony and Laravel so you won't make any gains there. Unless a massive security exploit is found what is the concern in sticking with CI? In 2 years time when another new framework comes out and everyone raves that it's the best, are you going to blindly rewrite again? See how pointless and time consuming that mentality becomes? If your app/site is successful eventually it will outgrow any framework. Needs change in unexpected ways, solve the problems you face today and if the time comes that you need to rewrite to accommodate a set of features go for it. How anyone can recommend swapping frameworks for no tangible benefit (today) is beyond me. [rant] Personally I think the entire concept of repo's for programming is misguided and a detriment to our talent pool. Programming is not gluing code from 10 different authors together. You will never learn as much as writing it yourself. Third party library's should be used as a necessity not the other way around. This is blatantly obvious in you deal with front end developers. The number of developers who can't write pure JS and rely on jQuery for everything is down right scary. [/endrant]
[eluser]gdweb[/eluser]
@jonez I totally agree with you. We build app for users, and users doesn`t care if you use CodeIgniter, Larvel or any other framework. If you are good in a framework, that means that, if a bug appear you will fix it fast, then stick with it. Users care to resolve bug fast. If we can build an app in 6 months in framework A(last realease-12months ago), and in 12 months in framework B(last realease-1week ago). Choose framework A, a user will thank you for that. We must focus on end user, even if we are not front-end developers. Personally if I want to do/learn something new, I will focus on framework based on node.js(now it is to young maybe in 1-2 years), and not on another framework that do the same thing. |
Welcome Guest, Not a member yet? Register Sign In |