Home >Backend Development >PHP Problem >What are the PHP microservice frameworks?

What are the PHP microservice frameworks?

(*-*)浩
(*-*)浩Original
2019-07-31 14:36:0720287browse

Tars is a high-performance RPC development framework based on the name service using the Tars protocol. It is also equipped with an integrated service management platform to help individuals or enterprises quickly build their own stable and reliable distribution in the form of microservices. application.

What are the PHP microservice frameworks?

Tars is an open source project that summarizes the results of many years of practice in Tencent’s internal microservice architecture TAF (Total Application Framework) . (Recommended learning: PHP video tutorial)

The name Tars comes from the interstellar robot Tars. Tars in the movie has a very friendly way of interaction, anyone who comes into contact with it for the first time You can easily communicate with it, and at the same time, you can complete all tasks entrusted to you with greater efficiency than expected on complex terrains such as outer space and alien planets. Tars, which has a similar design concept, is also a framework that takes into account ease of use, high performance, and service governance. It aims to make development simpler, focus on business logic, make operations more efficient, and keep everything under control.

Currently, this framework is running on more than 100 businesses and more than 16,000 servers within Tencent.

PHP-msf is a PHP microservice framework developed by Carema360. I have not actually used it yet, but the microservice frameworks on the market either recommend the Spring system or go/node. Since I wanted to use PHP to develop microservices, I searched for PHP's microservice framework and discovered php-msf.

php-msf's documentation is very sparse, just a brief introduction. However, if you are familiar with the PHP development framework of MVC, you only need to be proficient in the API, and there is nothing else.

As a microservice framework, it must be related to Docker, and I think php-msf has done a good job in this regard, and has its own Docker image list to pull, saving you the trouble of configuring the environment yourself. .

swoft is a high-performance PHP microservice framework based on swoole coroutine 2.x, with built-in http server. The framework is fully coroutine implemented, and its performance is better than the traditional php-fpm mode.

Before swoole, PHP has always been "lauded" as the best language in the world. After swoole was born, php became the best language in the universe...

swoft is a high-performance coroutine full-stack framework based on swoole. After reading the introduction on swoft's official website, I instantly felt that it was an awesome and sparkling framework.

If you want to use swoole, if you build a framework by hand, the time cost is too high, and you have no confidence in the quality of your own code (well, this is the main reason...), if you combine swoole with the popular The combination of frameworks, such as laravel, yii2, and thinkphp, will encounter many pitfalls, and these frameworks appear to be too cumbersome. On balance, swoft, a framework designed specifically for swoole, is very suitable for lazy people. The disadvantage of using swoft is that not many people currently use this framework. Basically, apart from official documents, there are no other learning resources, and no open source projects based on swoft have been found.

For more PHP related technical articles, please visit the PHP Graphic Tutorial column to learn!

The above is the detailed content of What are the PHP microservice frameworks?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn