Which PHP framework recommendations are suitable for high-concurrency, high-traffic, and high-performance website development?

Source: Internet
Author: User
0 reply content: High concurrency, high traffic, high performance?
These problems cannot be solved by a php framework. The closer the lamp architecture is to the bottom layer, the more influential php is, if you want to optimize the performance, first optimize the underlying hardware and software.You can understand Swoole extensions and frameworks.
Swoole: PHP asynchronous, parallel, and distributed extension framework
High concurrency, high traffic, and high performance
It sounds like an architecture problem. The so-called architecture is similar to the following:

  • Database Cluster processing, read/write splitting;
  • Load Balancing, high traffic, adding machines, no money? I have never heard of any projects with high traffic and no money ...;
  • CDN: stores static content on cdn to accelerate download speeds and reduce bandwidth usage on data servers;
  • Cache, some data that does not change frequently or can be controlled or changed, but is frequently read. In the cache, the data is directly read at the next read. Compared to every computing operation, the data is read from the database, hundreds of times faster;
  • The queue system puts time-consuming tasks in the background for fast response.

Of course, a good framework, such as Laravel It provides many convenient tools to meet your architectural design needs.

  • Database read/write splitting-> database usage Basics
  • CDN support. In Web development, the static files are added with version numbers. For example, 'all.css 'is generated with 'all-16d570a7.css'. For details, see Elixir documentation-> Laravel Elixir.
  • Unified cache interface, supporting various popular caches, such as MemcachedAnd RedisFor details, see cache-Laravel Chinese document.
  • The queue system supports convenient interfaces to make everything look so simple-Laravel Chinese documentation

The PHP framework is designed to solve the problem of development efficiency. Compared with JAVA and C/C ++, PHP Execution efficiency is slow enough. The framework is built on PHP with a bunch of code, therefore, PHP is not recommended for the ultimate performance. phalcon is required. The full stack framework implemented with c-extension can meet your needs and achieve high performance. Generally, you do not need to write your own frameworks ~ All the frameworks are simply slowing down the system speed. If you are only pursuing the performance of the framework, you can try to use the C language to write the framework yaf in php extension mode.
But should I choose a development framework from the development team? Whether it is easy to get started, whether there are rich documents, how Community support is, how the expansion mechanism is, and whether there are problems caused by the Framework Team can be solved in a timely manner, these problems were not solved at the beginning, if problems cannot be solved in later development, it will be too much trouble. If Facebook's php-to-c framework requires so much, you won't be able to make an undergraduate graduation project. You have to decide based on the project requirements and funding. Don't share too many things and you won't be able to handle it yourself, I suggest you use the CI framework or thinkphp for less than 0.2 million projects. It is simple and quick. The main purpose of writing a program is to convert the program into money after the task is completed. Why do you need to dig holes for yourself?
High concurrency, high traffic, and high performance are required. A large number of java. net frameworks are waiting for you. Just like the common php development framework, some people have really tested the code execution time of each framework.
The high concurrency, high traffic, and many requirements are the server architecture.
If the performance is high, the frontend and backend must be optimized. Let's take a look at CmlPHP and integrate the cache in the orm. Configure one mysql master, multiple slave, and multiple cache instances as needed. The framework automatically performs distributed processing. There is a need to directly use mongodb is also possible http://cmlphp.51beautylife.com

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.