Welcome Guest, Not a member yet? Register   Sign In
Long-living PHP support (Swoole/RoadRunner etc)

Quote:The question is does CI need to support Swoole, RoadRunner, etc What for? Performance?
Performance is a major key. Even PHP version updates consist of performance improvement.

Further, performance isn't the only reason. Swoole or similar servers offer features like WebSockets, asynchronous programming, coroutines, and microsecond cronjobs that are not available with traditional NGINX or Apache servers.

Quote:Let's leave it at that. Otherwise, it will become a big lazy monster like Laravel.

I guess there is a misunderstanding regarding if CI supports long-living applications. Laravel is slow because 3-rd party libraries are involved. WordPress CMS is slow because of the availability of plenty of plugins and themes for it.

Here the concern is about designing CodeIgniter in a better manner that would support those servers as well. For example, removing usages of superglobals, and static variables from its core. Simplicity and speed will remain in their place or even will improve.

Quote:It could turn out that the changes required to support Swoole will attract 5% of new users, but bring a bad experience to 50% of existing ones

It won't turn out. I'm a person who is using OpenSwoole for a live project and I'm extremely thankful to the CI team and @monkenWu. I had started the project (2nd version) with CI4 in PHP-FPM. And even in that case, I was not happy as it was performing slower than CI3. (The original project was written in CI3 and is now being recreated with CI4, then after OpenSwoole replaced Apache).

From my experience, I can say that incorporating such changes won't impact those 50%. It is about design patterns that are causing blocks from intended use as well as leveraging their full potential, not about including a feature with X library. Also, the development speed would remain faster because theoretically, we are writing application code in the same manner from CI2 to CI4 while there has been a lot of change among these three.

Quote:99% of performance problems are caused by bad application code.
As it is. If CI changes its architecture to support non-traditional servers or to reduce performance difference between CI 4/3, ultimately, it will depend on the application developer to write good application code.

CI allowed importing various namespaces and packages. Why shouldn't it support non-traditional servers? Even PHP has an official extension for Swoole. If a framework won't support a server, where else an end-developer would go?

Messages In This Thread
RE: Long-living PHP support (Swoole/RoadRunner etc) - by amits - 01-16-2023, 12:11 PM

Theme © iAndrew 2016 - Forum software by © MyBB