This language has been in sight for several years.

  • But what is written on it?
  • And what can you write?
  • Is it worth learning?
  • Or will he disappear soon?

Closed due to the fact that it is necessary to reformulate the question so that you can give an objectively correct answer to the participants of Kromster , ermak0ff , Streletz , PashaPash , Max Mikheyenko 13 Nov '15 at 17:51 .

The question gives rise to endless debates and discussions based not on knowledge, but on opinions. To get an answer, rephrase your question so that it can be given an unambiguously correct answer, or delete the question altogether. If the question can be reformulated according to the rules set out in the certificate , edit it .

  • eight
  • 3
    Quite an interesting review because of which I began to study erlang, and not go: habrahabr.ru/post/145796 - ReinRaus
  • A year ago ... - qnub
  • @grub, erlang for the year has become even more productive and fault tolerant? :) - ReinRaus
  • I defended not because the question is good (it is bad) but in order not to collect new answers. - Nick Volynkin

5 answers 5

What is written on it?

And what can you write?

Anything. In fact, anything, but, because of its advantages, it is very popular for developing server-side (backend).

Is it worth learning?

The question is rhetorical. From the point of view of purchaseability, there is almost no ready-made demand for it, due to youth and undilutedness. So what's the point in it:

  1. For myself, my startup
  2. Sell ​​the finished product
  3. Execute an order if the customer has the advantages of this language (you have to explain / convince)

Or will he disappear soon?

As already mentioned, it cannot disappear, because Open source Those. no one takes away from you what is written on it, the maximum will deteriorate development / support, which is hard to believe, because the language has very significant advantages.

Pros or “why I chose Go”

Performance

On performance for the web (ready-made frameworks), Go loses only Java and C / C ++ and on a par with node.js. At the same time, resource consumption is significantly lower than Java and productivity is much greater than that of Python / Ruby.

Multithreading

At the same time, it has just an awesome multi-threaded model compared to them. So far this is the best I've ever met for multitap / asynchron. At the same time, he also supports classical patterns like mutexes and callbacks.

Simplicity

It is very easy to learn. It seems to me even elementary, especially if there is a basis from Python / JavaScript. There is also a rather entertaining model of inheritance, which, it seems to me, is more transparent than the classical OOP, but a bit unusual at first.

Reliability

This language is compiled and statically typed. What gives the identification of many errors long before the production. For example, such errors in Python are detected only by direct testing and, if there are no tests, then there are a lot of chances to put the system. Here it is eliminated at compile time.

Compilation speed

And finally, one of the most important pieces is that you should not be afraid of typing and compilation. In 145% of cases you do not have to declare the type of a variable in the code - it is automatically set when you assign it a value. It is also not necessary to declare variables in advance.

Well, compilation - the main fad. Compile time is what the main emphasis is on when developing a language. It does not differ from the start time of the interpreted language. Those. a system written in go from uncompiled sources is launched at about the same speed as a system of similar complexity written in an interpreted language.

Total

Those. we have the advantages of two worlds - the compilation / launch speed of the interpreted language and the reliability of the compiled languages. Plus top performance, multi-paradigm (you can write in a functional style), simplicity and low resource consumption.

Whether this is right for you is not for me to decide. It suits me, and I consider it a very good choice for high-load services (and not only).

  • @qnub, good review. - Some serious questions: How are large programs made (many files + own libraries of functions (or classes?) On Go)? How does the build happen when changing one line of code? How to work with "third-party" code (for example, C or C ++)? Interaction with the OS. Is posix supported and to what extent? Debugger programs from multiple processes? Is it possible to dynamically connect the debugger to already running processes? - And on trifles: Do you seriously consider the lack of the need to declare the type of a variable a plus? By the way, can you actually declare variables in Go? - avp
  • 2
    Very significant issues (not for the local limit), asking for a promise in the documentation :)> packages? j.mp/Zv4Vf2 I don’t know about the details of the recompilation, but the compilation is practically instantaneous in principle ...> C / C ++? j.mp/Zv4P7s > POSIX? j.mp/Zv4Qbv > debag ? GDB - j.mp/Zv4OjC Is there no need for a variable declaration? Any abbreviation of scribbling that does not impair the understanding of the source is a plus. And yes, variables can be declared. - qnub
  • @qnub, thanks. I looked out of the way at the introduction ... from your links, interesting. I correctly understood that as a result of programming we get a load module? Is it possible to make it static (independent of .so (. Dll in Windows))? When transferring a non-static module to another machine, what installation efforts are required? Did I understand correctly that you can try to work with your shared lib only through your own C (or did I just not find a dlopen in your links)? Does Go have "portable windows" (widgets of, say, Tk level) for X-Windows and Windows? The real portability of the Linux-Windows? - avp
  • one
    I'm not sure that my competence is already enough to answer these questions. He is more interested in me for server-pollack, and not for application programs, although I know that there are GUI applications on it, at least using GTK. The existing native packages here are golang.org/pkg; a selection of third-party ones is j.mp/15l6YAU here (there are GTK and Qt, but I don’t see Tk, but I can still have it). It is compiled into the native system code in the same way. Here is an example of calling dlls: j.mp/15l8DGE; here is a compilation of the Windows executable under the line: j.mp/15l8OBW - qnub
  • one
    Unfortunately not, I have no such experience. I am doing a service for Google App Engine, and everything is automated there and I don’t even know what is on the server side :) - qnub

But what is written on it?

I wrote two web services on Go, one is still in deep alpha, the second has been doing its job for almost a year now. In both cases, customers are satisfied.

And what can you write?

Almost anything, but still the emphasis is on web applications. In my opinion, Go is ideal for web development when maximum performance and reliability is required. For example, if you need to quickly roll up the homepage for "Vasi Pupkin" Go is clearly not the best choice, write in PHP (It’s the way that was originally intended for Personal H ome P age), but if you need a serious web service where a banal typo in the code may cost your client at XXX $, then it already makes sense to look at Go

Is it worth learning?

I am afraid of the answer to this question, nobody can give you, except you. Try it in business, then you will immediately understand whether it is suitable for you, and for what purposes. Personally, I fell in love with this language at first sight)

Or will he disappear soon?

Go can not disappear, it opensource.

  • @Pavel Vershinin, and the size of the boot module is not too big? I didn’t dare to start Go, after seeing somewhere that the size of HelloWorld is larger than a megabyte. And also, with what you can compare a serious program (I mean a program that manipulates "raw" megabytes of data in different structures (arrays, trees, etc.) in RAM) with C / C ++ or Python / Java. ? - avp
  • 2
    @avp Basis Go packages (Packages), for writing a simple HelloWorld, you at least import (connect to the project) the fmt package, and fmt, in turn, imports a number of packages, and so on. Hence, and not because of the load module, the relatively large weight of such a simple program. In the future, the weight increases very slightly. I can’t answer the second question, because I didn’t make any comparisons myself, look through the habrahabr.ru/hub/go there, there’s a little on this topic. - Pavel Vershinin
  • Absolutely any web service is possible, but a search engine is possible? Shorter service with large loads. By the way, tour.golang.org/#1 online tour learning a language is vanekk1
  • Service with heavy loads needed. - qnub
  • one
    > Go can not disappear, it opensource. I do not like these phrases. Here there will be no one community, books, courses and tools - consider disappeared. And what, that code on the outskirts of the githab is lying around - kandi

I think to add anything to the pluses described above. It is clear that the person who invented the C language, and now working in Google and having invented GO took everything into account and made a really magnificent and simple language. Learning is worth it!

You should not learn if you plan to write home pages in php all your life, if you don’t plan to do anything more difficult with an Internet shop. Just learn and never use too ...

  • four
    @bosom note, the question was asked more than a year ago, it hardly makes sense to engage in necromancy and resurrect long dead (especially considering that the topic has already been exhausted). There are many other, more recent questions at your service, and this one is already a history story - DreamChild

It's also easy to write programs for Android and fly like rockets!

What else is good about it is cross-platform. Wrote once and compile for any. And I on Windows made for Windows and for Linux. Unloaded on Linux and launched without rework ...

Under Android, everything is done by one gomobile utility. Moreover, it can immediately install on the smart, if you connect it with a cord.

    You should look at the list of companies / services using Golang anyway

    • one
      Try to write more detailed answers. Explain what is the basis of your statement? - Nicolas Chabanovsky