PHP Skill Tree---The path of the Great God Advanced

Source: Internet
Author: User
Tags apc epoll fpm install php php framework mysql backup zend install redis

The PHP7 ushered in a huge performance boost, again returning to the focus of attention. According to these years in the development circle summed up the LNMP program Ape development trajectory, combined with personal experience, summed up a lot of programmers on the future of the mist, especially on the technical learning of the blind and flustered, a simple comb this each stage of the PHP Programmer's technical requirements, to help many PHP programmers to set the learning growth target.
This article is based on the current mainstream technology to do a basic comb and assume that the PHP programmer is not a very solid foundation of the setting, and all the settings are very specific and clear.

1th stage: Beginner PHP programmer

Focus: LNMP Skilled (core is the basic operation of the installation configuration)
target: Can complete basic LNMP environment installation, simple configuration maintenance, can do basic simple system PHP development, can support a PHP function module development in PHP medium-sized system.
time: The time to complete this stage varies from person to person, and some grow up almost half a year on the past, growing slowly two or three years also have.

Basic command, operation, startup, basic service configuration (including RPM installation files, various service configurations, etc.); write simple shell scripts and awk/sed script commands.

to be able to install configuration nginx+php, know the basic nginx core configuration options, know Server/fastcgi_pass/access_log and other basic configuration, the goal is to enable NGINX+PHP_FPM to work smoothly.

will build MySQL, know the basic MySQL configuration options, know the difference between InnoDB and MyISAM, know the different configuration options for InnoDB and MyISAM two engines; know the difference between the basic two engines and choose the difference above To build a MySQL database and configure the code to run normally and stably; The core idea is to be able to build a running MySQL database.

basic Syntax array, string, database, XML, Socket, gd/imagemgk image processing, and so on; be familiar with the various APIs (MYSQL/MYSQLI/PDO) linked to MySQL, and know the solution to various coding problems Know the regular skilled PHP framework (thinkphp, Zendframework, Yii, YAF, etc.); understand the basic MVC mechanism and why you do it, a little bit about the differences between different PHP frameworks, and the ability to quickly learn an MVC framework. Be able to know the file directory organization in the development project, have the basic good code structure and the style, can complete the small system development and the medium system one module development work. Thousand front php now hand-taught handwriting MVC framework in the industry good reputation, is a good PHP learning reference.

5.web Large front end:
must be familiar with the Div+css+javascript, now the front-end of the weight of more and more heavy, a variety of framework after the village bamboo shoots operation. Vue.js, React.js, Angular.js, are very popular with enterprises. These are easy to learn if you build a solid foundation.

6. Development system Design:
It is best to be able to complete the basic design of the small system independently, including the simple database design, which can complete the basic: design and development of database architecture, such as browser-nginx+php, and support the development and maintenance work of hundreds of thousands of to millions of traffic daily .

2nd Stage: Intermediate PHP programmer

Focus: Improve the skills for LNMP, can be more comprehensive to the LNMP have skilled application.
Objective: To set up the LNMP environment anytime, anywhere, to quickly complete the general configuration, to trace the most encountered development and online environment problems, to be able to independently assume the framework and development of the medium-sized system, to assume the development of a medium-sized module in a large-scale system ;

1. Linux:
on the basis of the first stage, we can use the shell script to do a lot of automated work smoothly, Awk/sed/perl is also very good, can complete a lot of text processing and data statistics, etc., basically can install most non-special Linux programs (including various libraries, packages, Third-party dependencies and so on, such as Redis/sphinx/xunsearch/svn/git); Learn about basic Linux services, know how to view Linux performance metrics data, know basic Linux problem tracking, and more.

2. Nginx:
in the first stage of the foundation, understand the complex nginx configuration, including multi-core configuration, events, PROXY_PASS,SENDFILE/TCP_ configuration, know the time-out and other related configuration and performance impact; I know nginx in addition to Web server, Also can assume proxy server, reverse static server and other configuration; know the basic Nginx configuration tuning; Know how to configure permissions, compile an nginx extension to nginx; know the basic nginx operating principle (Master/worker mechanism, epoll), Know why Nginx performance is better than Apache performance and other knowledge;

3. Mysql/redis:
on the basis of the first stage, there are a number of tips on MySQL development, including regular SQL optimizations (group By/order By/rand Optimizations), and the ability to back up MySQL data in cold and hot, in addition to being able to build MySQL, and to know the impact innodb/ MyISAM configuration options for performance (such as key_buffer/query_cache/sort_buffer/innodb_buffer_pool_size/innodb_flush_log_at_trx_commit, etc.), Also know how many of these options are configured to be appropriate; also know some special configuration options, such as know how to build MySQL master-slave synchronization environment, know the difference between the Binlog_format; know MySQL performance tracing, including Slow_log/explain, Knowledge of basic indexing and processing is also possible, and the principle of understanding basic MySQL architecture (server+ storage engine), knowing the basic Innodb/myisam index storage structure and different (clustered index, B-tree); know the basic INNODB transaction processing mechanism To understand most of the MySQL exception scenarios (or know where to find the processing solution).

4. Redis/memcached:
in most of the medium-sized system will be involved in the cache processing, so be sure to understand the basic cache; know the similarities and differences between Memcached and Redis and the application scenario, can install redis/memcached independently, understand some basic features and limitations of memcahed, such as the largest value values, know PHP with their use, Redis understand the basic work and use, understand the general data types, know what kind of scenarios to apply what type, understand Redis transactions and so on. Principle part, can understand the memory structure of memcached (slab mechanism), Redis understand the common data type underlying implementation of the storage structure (sds/linked list/skiplist/hashtable), and so on, by the way, know the Redis transaction, RDB, AoF and other mechanisms better

5. PHP:
In addition to the first-stage capabilities, installation configuration is free to install PHP and various third-party extensions of the compiled installation configuration; Understand most of the configuration options and implications of PHP-FPM (such as Max_requests/max_children/request_terminate _timeout such as impact performance configuration), know the difference between the mod_php/fastcgi, in PHP has been able to master a variety of basic technology, but also a variety of in-depth PHP, including a deep understanding of PHP object-oriented/spl/syntax aspects of special features such as reflection , in the framework has read at least one of the regular PHP MVC framework Code, know the basic PHP framework internal implementation mechanism and design ideas; in PHP development has been able to skillfully use the conventional design pattern to apply development (abstract Factory/SINGLETON/Observer/Command chain/policy/adapter and other modes) , it is recommended that you develop your own PHP MVC framework to fully liberalize your development, allow yourself to understand the MVC pattern, and enable you to quickly upgrade your Business Project development, familiarize yourself with PHP's various code optimization methods, and familiarize yourself with most of the PHP security issues. Familiar with basic mechanism of PHP execution (Zend Engine/extended basic working mechanism);

6. C + +:
started to dabble in a certain C + + language, be able to write basic C + + code, familiar with the basic C + + syntax (pointers, array operations, strings, general standard APIs) and data structures (linked lists, trees, hashes, queues) have some familiarity with , the basic knowledge of C language development under Linux, it will be simple makefile file writing, can use simple GCC/GDB program to compile simple debugging work, basic network programming have a general understanding. (This is to lay the groundwork for a higher level)

7. Web Front End (this item does not focus on learning, unless you are interested in the front end):
on the basis of the first stage, familiarize yourself with the Basic HTTP protocol (Protocol Code 200/300/400/500, basic HTTP interaction header), allowing you to write a slightly elegant html+css+javascript in depth, Or it can be roughly simple to use some front-end frameworks (such as Jquery/yui/extjs/requirejs/bootstrap), and if conditions permit, you can drill down into JavaScript programming, such as the closure mechanism, DOM processing And go deeper into the jquery source to learn more.

8. System Design:
be able to design most of the medium-sized system Web site architecture, database, basic PHP framework selection, performance testing and processing, etc. can be completed similar to: browser----CDN (Squid), nginx+php----cache database Basic design and maintenance of structure website; capable of supporting the development and maintenance of millions of to tens of thousands of daily traffic basic websites;

Phase III: Advanced PHP programmer

emphasis: In addition to the basic LNMP program, you can also have in-depth learning in a certain direction or field. (depth dimension development)
Objective: In addition to the ability to complete basic PHP business development, but also to solve most of the deep and complex technical problems, and can be independently designed to complete the large-scale system design and development work, oneself can hold into a technical direction independently, in this piece of comparative professional. (such as MySQL, Nginx, PHP, Redis, and so on in any direction in-depth research)

1. Linux:
In addition to the second phase of the ability, under Linux in addition to the general operation and performance monitoring tracking, but also can use a lot of advanced complex commands to complete the work (watch/tcpdump/starce/ldd/ar, etc.); in Shell scripting, has been able to write more complex shell scripts (more than 500 lines) to assist in the completion of a lot of tasks including backup, automated processing, monitoring and other work of the shell, Awk/sed/perl and other applications such as fire pure green, able to manipulate the arbitrary control processing text statistical analysis of various complex formats of data , there is some understanding of the internal mechanism of Linux, the kernel module loading, startup error handling and so on have a basic processing, but also some other related things, such as NFS, Disk Management and so on;

2. Nginx:
in the second stage of the foundation, has been able to operate the nginx very skilled, can be more in-depth operation of nginx, such as monitoring, performance optimization, complex problem processing and so on; looking at personal interests, more aspects can be considered to focus on the Nginx working principle part of the deep learning, Mainly in the reading source, such as the specific master/worker work mechanism, nginx internal event processing, memory management and so on, but also can learn the development of Nginx extension, you can customize some of your own private extensions, but also to nginx+lua a certain degree of understanding, To see if a better model can be combined, the requirement of this stage is an in-depth understanding of the nginx principle, which can be considered as an in-depth professional in the nginx direction.

3. Mysql/redis:
In the second stage of the foundation, in the MySQL application, in addition to the previous basic SQL optimization, but also in the completion of a number of complex operations, such as the import and export of large quantities of data, a large number of online data change table structure or delete index fields and other high-risk operations; In addition to the installation configuration, have been able to deal with more complex MySQL problems, such as the tracing of various problems, master-Slave synchronization delay problem resolution, cross-room synchronization data scheme, MySQL high-availability architecture, etc. are involved in understanding; for MySQL application level, the core key technologies of MySQL are familiar, such as the transaction mechanism (Isolation level , locks, etc.), to trigger, partition and other technologies have a certain understanding and application; For MySQL performance, there are disk optimizations (SAS migration to SSD), Server optimizations (memory, server itself configuration), and other core performance tuning options in addition to the two phase (Innodb_log_buffer_ Size/back_log/table_open_cache/thread_cache_size/innodb_lock_wait_timeout, etc.), connection pooling software selection application, to show Status/show Profile) class operation statements have in-depth understanding, to complete most of the performance problem tracking; MySQL backup technology in-depth familiarity, including disaster recovery, deep understanding of Binlog, hot and cold backup, multi-IDC backup, etc. in the MySQL principle, there is more understanding, For example, the working mechanism of MySQL began to read some of the source code, such as the master-slave Synchronization (replication) technology source learning, or to a storage engine (MYISAM/INNODB/TOKUDB) and so on the source learning understanding, if the conditions allow, You can refer to the CSV engine to develop your own simple storage engine to save some data and enhance your understanding of MySQL, and in this process, if you are interested, you can also consider moving to DBA.

4. Redis/memcached:
in the second stage of the foundation, can be more in-depth application and learning. Because memcached is not particularly complex, it is suggested that the source code can be read, especially the memory management part, to facilitate in-depth understanding; Redis section, you can do more complex data structure of the application (Zset to do the leaderboard sort operations/ Transaction processing is used to ensure atomicity in the use of the second-class scene application and other applications, and more involved in the AOF and other synchronization mechanisms of learning applications, design a highly available Redis application architecture and clusters; It is suggested that we can learn the source of Redis in depth and apply the knowledge accumulated in the second stage. Especially you can read about it, including core event management, memory management, internal core data structure, and so on. If interest permits, you can become a very professional user of Redis.

5. PHP:
as a basic core skill, we need more in-depth learning and application on the basis of the second stage. From the basic code application above, can solve the PHP development encountered 95% of the problem, understand most of the PHP skills, for most of the PHP framework can be quickly used in a day, and understand the pros and cons of various mainstream PHP framework, can quickly facilitate project development to do technology selection; In addition to the general second stage of knowledge, you will learn some of the more biased gate configuration options (PHP auto_prepend_file/auto_append_file), Includes some complex advanced configurations and principles in the extension (such as the memcache.hash_strategy in the memcached extension configuration, apc.mmap_file_mask/apc.slam_defense/in the APC extended configuration Apc.file_update_protection and so on), the working mechanism of PHP, including the PHP-FPM work mechanism (such as PHP-FPM under different configuration machine to open process number calculation and principle), Zend Engine has a basic familiarity (vm/gc/ Stream processing), read the basic PHP kernel source code (or read the related article), the most core data structure of PHP internal mechanism (basic type/array/object) implementation has the understanding, for the core infrastructure (zval/hashtable/ GC) with in-depth learning, ability to perform basic PHP extension development, understanding of some advanced knowledge of extended development (minit/rinit, etc.), familiarity with PHP and apache/nginx different communication interaction details (MOD_PHP/FASTCGI) In addition to developing PHP extensions, consider learning to develop Zend extensions to understand PHP from a lower level.

6. C + +:

7. Web front end (with more energy to understand):
In-depth understanding of the HTTP protocol (including the specific protocol code and the reasons behind the detailed protocol, such as 302 static file cache, 502 is the nginx behind the PHP hang); In addition to the front-end aspects of the various framework application integration capabilities, the front-end of the study if interested can be more in-depth, the manifestation is, You can develop some kind of jquery-like front-end framework, or develop a rich text editor, such as a trivial test of JavaScript skills, the industry is widely used in thousands of PHP with students handwriting Packaging interactive plug-in.

8. Other areas of language learning:
In the basic php/c/c++ language aspect has the fundamental accumulation, the suggestion in the current stage may try to learn the different programming language, sees the personal interest hobby, the script language can learn python/ruby and so on, the functional programming language may try Lisp/haskell/scala/ Erlang and the like, static language can try; "/>

9. Other Professional Direction study:
In this stage, in addition to the basic LNMP skills, will consider a number of other areas of knowledge learning, these are available, look at personal interests and long-term goal direction. At present, the situation can choose more areas, such as cloud computing (distributed storage, distributed computing, virtual machines, etc.), machine learning (data mining, pattern recognition, application to statistics, personalized recommendations), Natural language processing (Chinese word segmentation, etc.), search engine technology, graphic images, speech recognition and so on. In addition to these tall, there are many partial engineering aspects can be learned, such as high-performance systems, mobile development (Android/ios), computer security, embedded systems, hardware and other directions.

10. System Design:
System design on the basis of the second stage, can apply the mastered experience and skills, design a more complex medium and large system, can solve most of the problems of complex systems on the line, complete similar browser----CDN---load balancer, access layer, and so on nginx+php- > Business Cache--database--Complex backend RPC interaction (storage backend, logical back end, anti-cheat backend, external services)--more complex services for back-end Jiangzi, capable of supporting the normal development and maintenance of tens of millions of to hundreds of millions of traffic sites per day.

PHP Skill Tree---The path of the Great God Advanced

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: 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.