Answer the question
In order to leave comments, you need to log in
Golang and PHP, a tribute to fashion or a necessity?
I see this connection more and more. In the last application thrown to me from HR for a PHP developer, it says directly “Experience or desire to work with Golang”, but I still can’t understand what tasks Go solves so well that it needs to be written in Go, and not in PHP.
Answer the question
In order to leave comments, you need to log in
1. Regular Go code often works much faster than similar php code
2. It’s easier to write microservices in Go, and it’s easier to containerize them (on average)
3. Go out of the box integrates well with devops tools, because they are written in go, often
4. All sorts of companies like Avito and Badoo just get rid of legacy in this way, and retraining an existing command on Go is cheaper than retraining it on C++/Java/C#.
what tasks does Go solve so well that it needs to be written in Go, and not in PHP
If the project has critical places that need to be accelerated, but we run into the speed of the php interpreter, then we take go.
Go is a fairly simple and high-performance language. But the development speed on it is much lower than on php.
Go is usually bundled with other technologies that don't perform well. If you introduce Go at an early stage, then this is most likely unjustified. So, for some - a tribute to fashion, of course.
I see the point in starting to use Go when the project has grown enough and critical places in the performance of the architecture as a whole have appeared. Then you can write a microservice that solves a specific problem.
It is inefficient to write business logic in Go. But if there are some infrastructure tasks, then you can write them with a bang.
The choice in favor of Go is made due to the support of the language by the corporation, the large media support on the Internet, and the ease of learning the basics of the language due to its simplicity. Accordingly, it is easier to find new developers willing to write and train them.
Tasks where speed is needed
Multithreading in thousands of threads
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question