Benefits of Golang for Enterprise Systems

Source: Internet
Author: User
Tags coding standards
This is a creation in Article, where the information may have evolved or changed.

Http://www.brendaningram.com/blog/4-brendans-blog/19-12-benefits-of-golang-for-enterprise-systems

Benefits of Golang for Enterprise Systems


the Go programming Language (commonly known as Golang, and for the purposes of this article referring to version 1.2 or NE WER) was conceived by Google in late, and released in November 2009. Go was created primarily as a systems programming language. That's to say this Go is not currently designed for creating desktop user interfaces.

In the world of programming languages, Go is relatively new. However, in the few short years it had been in the public domain, it had rapidly grown in popularity as organisations Redi Scover the benefits of a lightweight, highly performing, and fun programming language. As part of my day-to-day role I has been evaluating golang as a potential replacement to some of our existing Microsoft s Tack applications.

These is the key benefits that Go provides in an enterprise environment:

1. An overview of the Go programming Language

Hint:as you is embarking on your own journey to the fun Land of Go, use the term ' Golang ' when you are doing Internet Searches. Search phrases such as "go Syntax" or "Go examples" don ' t bring back targetted results as well as "Golang syntax" or "Gola ng examples "et cetera.

2. C Level Performance

Golang is within a close margin of the performance level of C code (which are itself an extremely high performance language ). It is certainly closer to the performance of native languages than other enterprise level languages such as Java, Scala, E Rlang et al. Again, keep in mind, it statement applies to go1.2-earlier versions of Go had very minimal optimisation within the Compiler. The current version is very fast, and it'll only get faster as the language gets more mature.

"Go is like a better C, from the guys so didn ' t bring you C + +"-ikai Lan

3. Fast Compilation

The Golang compiler is designed to compile programs very quickly. Extremely large programs with massively high LOC counts compile seemingly instantly-afterall,golang were designed by Goog Le to solve Google problems, and Google have big problems! At Google, code and CPU cores is both measured in the millions. My own proof of concept tests has shown that Go programs compile with impressive speed. In fact, it had been said that Go programs compile so quickly then the language can almost be treated as a runtime INTERPR eted language.

4. Multi Platform

The Golang compiler allows you and compile executables for multiple platforms out of the box. In a enterprise environment that have its environments pretty well fixed in place, there isn ' t much benefit in this, Howev Er it does offer enterprise a level of the future proofing. For example, hardware are currently Windows based, however we can build these new systems in Go and we continue to EV Aluate whether we'll move to Linux. If The decision is made-to-move to Linux, no extra are required other than compiling the program into Linux executable S.

5. Unit Testing & Benchmarking

These is first class citizens and core elements of the Go programming language. Check outmy Recent post about Golang benchmarking for a practical example of what useful these features are.

6. Concurrency supported at Language level

Concurrency is the ability to execute multiple computations simultaneuously. In today's modern multicore and high-load computing environment, concurrency is a critical language feature, and one in WH Ich languages such as Java struggle immensely.

Google has summed things up nicely with their motto: "Don ' t communicate by sharing memory, share memory by communicating. "

7. Code Style-gofmt

GOFMT formats Go programs.

It doesn ' t get much simpler than that! Check out Google's page about gofmt , and Google's gofmt blog post that shows a few practical examples. In reality, what's this means was that your code was always nicely formatted, and coding standards can be easily maintained th Roughout the organisation.

8. Built-in documentation-godoc

Godoc extracts and generates documentation for GO programs

Again, just like the rest of Go, it doesn ' t get any simpler. Communicating the purpose of API ' s and programs within an organisation are important. When you need to communicate to 3rd parties, it's critical. godoc Creates a structured documentation resource that can share internally, or externally. Check outgodoc.org for some documentation examples.

9. Garbage Collection

In C and C + +, programmers spend a lot of time and energy on allocating and freeing memory. The designers of Go wanted to remove this complication, and ensure Go programmers could concentrate on more productive TAS Ks. As such, they implemented garbage collection.

As a developer, this is a very good thing. Sure, garbage collection comes with its own set of issues, but those is dealt with by the language implementer while the Programmer is free to reap the other many benefits of Go.

Comprehensive Standard Library

This was a massive factor for any organisation or individual looking to take on a new language. The Go standard library isvery comprehensive. Check out the list of packages in Go. Standard library functionality includes important things like compression, cryptography, numerous data structures, SQL DRI ver, JSON and XML parsing, templating, networking, and a lot more.

A. Fun Language, Shallow learning Curve

Good programmers'll always be good programmers. They'll is able to learn pretty much any language. Personally, it ' s been a long time since I did any C programming, however I had been a C # programmer for years (started With the beta versions), and has dabbled with various other languages along the.

Over the short period of 2 weeks, I went from zero knowledge of Go, to writing an MVC style Web application featuring rout ING, templating, authentication, reading records from a database (RETHINKDB), entering data to a form and saving it back Into the database, and a few other little niceties. In addition, in those 2 weeks I had to refresh my knowledge of Linux (I do all this on a Debian VMS running in VirtualBox) , and also had to start from scratch with RETHINKDB. You can ' t argue with productivity like that!

After Go, programming in anything else seems as difficult as balancing the state of California ' s budget. "-charles Thomp Son

One of the most useful books I has found to learn go is the the the the-to go:a thorough Introduction to the Go programming Lang Uage-best of all, it's only about $3.00 on your kindle!

Numerous Enterprise case studies

The more I am in the Go, the more impressed I am. These benefits is just the highlights. There is many more benefits that I-could list, but if I do that, this article would never finish. Instead, which has a read of these case studies from organisations that really know what the they ' re talking about:

Iron.io

In retrospect, it is a great decision to choose Go as it's allowed us to build great products, to grow and scale, and at Tract grade A talent. "-read Case Study

Bitly.com

"We identified early on this Go had all the makings of a language that could supersede some of the places We would had TR Aditionally turned to C and some of the places where we wanted to move away from Python. "-read Case Study

Torbit.com

"We process over 6 billion performance metrics a day and we goal are to keep our customers ' data safe forever."-read case Study

Conformal.com

In summary, Go makes hacking fun again by doing away with intellectual masturbation and terrible, terrible tools. It compiles super fast and runs at native speeds. Any C expert can pick it up through the course of a few weeks and with its awesome data representation features I believe we Could rewrite a product such as Cyphertite in 25% as many lines of code. "-read Case Study

That's just my selection of 4 case studies about the benefits of Go. If you is interested in reading further, many more case studies can is found at ' The case for Go '.

Related Article

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.