Blog

Top 10 server-side programming languages in 2020s

EBS Integrator
Jul 27, 2020,

As previously discussed, choosing the right programming language is essential yet not critical for success in IT. Since almost every server-side language shares the logic behind creating software, programmers can jump from one to another. Given proper documentation and countless energy-drink-filled nights, of course. Businesses, on the other hand, must be more careful about committing because switching to a different language will bite financially. Nevertheless, the elitism in all of us wants to pick the best from the best, an ultimate decision. So in this article, we are going after server-side scripting options like dogs on a hunt.

Diving right in

For starters, we will turn our attention to the PYPL website, which is an overview of programming languages’ popularity and ranks them according to share and trend.

At the time of writing, there are 28 programming languages on the list and that is a little beyond our scope of web-enabled-focused languages. They all serve their purpose so with tears in eyes and under cold DevOps gazes we will have to do some culling.

PYPL Server-Side stats

Swift and Objective-C represent technologies aimed at developing software in the Apple ecosystem. Next on our list are the fancy tools for data scientists: R, MatLab, Julia. Analyzing and processing big data chunks is useful and some back-end tools might benefit from being written in these languages. However, writing your site’s logic in MatLab is probably going to drive your server-side developers crazy.

Can’t have lists without some exception to them, and in our case it’s Node.js. As you may have already noticed, it’s not on the PYPL’s table. Even so, we will feature it in our comparison chart due to it encompassing Javascript, TypeScript and weekly-flavoured frameworks.

Isn’t Java the same as JavaScript? Now, except teaching you how to ruin relationships with your dev team, we will treat Kotlin as a standalone  as a result of its capability of reducing the amount of code to at least 20% while maintaining the same performance and capabilities.

The last to experience the wrath of our axe is Rust. This one won’t make it because it serves a very niche purpose in memory-optimization while keeping the same JVM performance coupled with mediocre building speed.

So if we could kindly shave on that 10 in the title, and put in a bold 8: PHP, Python, Node(Javascript & Typescript), Java(Scala), Kotlin, Ruby, Go, C#.

server-side

 Popularity and Server-Side community

Ruling on the most popular Server-Side language is not entirely an exact science. However, in our attempt to light an objective ray on the matter we will consider different standard factors, which act as guidelines for both devs and businesspersons.

Popularity and Community go hand in hand being a measure of how well-received the technology coupled with the possible support you can expect when running into issues. This is why we’ll make use of multiple sources, to compile an objective ruling. StackOverflow will allow us to view the relative size of the community, while PYPL will draw a rough line of overall share and trend.

Here is a snapshot of StackOverflow’s search result. We can view the number of questions asked per day, week, and how many posts there are so far.

server-side

Python seems to be leading the popularity tab. Here are a few reasons why Python is experiencing  booming growth:

  • Universities are foregoing C and moving to Python
  • It’s “easier” to pick up than other languages
  • Non-techies involved with data science prefer it

Node’s community size may be inaccurate since there is no way to discern pure JavaScript questions from those intended for framework issues. Also, don’t forget we’re talking about a runtime environment so don’t go around telling people you code in Node.

Java and PHP seem to be on a downward spiral and their communities display tendencies of shrinking. However, Java is an undisputed champion in the enterprise ecosystem that hasn’t announced retirement plans yet.

Personnel availability

Many forego freelancers, be it bad reputation or history, as they pass the brain-ball around in corporate meetings and are deciding if Bob is cool enough to develop for the company. However, it is not unheard of companies trying to salvage unplanned errors in production by taking in nerds the night before the big day. Moreover, it’s worth noticing that freelancers can convert into permanent employees, although the rate is not quite explicit yet.

The biggest gathering place for freelancing is Upwork. Using available filters we can check how many developers, limited by registered accounts on the site, are available for a specific category. Another point to consider is the $10k+ mark which transcends from gig to job.

For a rough idea on permanent jobs, we will use Stack overflow Jobs, the gentleman job listing board for techies around the globe. With all the data streams sorted out, here is how it all looks divided into columns and rows.

server-side

Note that there is no distinction between positions (junior, medium, senior). If you are currently looking for a job don’t tell the interviewee our graph recommended you. Otherwise, Java, Node, and Kotlin seem plausible for picking up an easy job. As far as freelancing goes – the newer languages Node, Kotlin, Ruby, Golang are fine.

Support for serverless and containers

Microservice architectures have made quite the appearance in the industry and quickly picked up popularity. If this is your first time hearing the term, we suggest reading our introduction to software architecture. We went in detail about the “outer layer” of web-enabled software there.

The two infrastructure options that allow you to implement microservices are serverless and containers. In a nutshell, serverless is deploying your software on the cloud where the vendor takes care of hardware resources. At the opposite, containers promote independent bundles, with a thought-out communication layer, that can be deployed at will. Should your single-page application or online shop involve designing with microservices in mind? See out our stack of nerds has to tell you about microservices and cloud models.

There is not a single definition able to capture the idea behind Microservices. Nevertheless, for my sake and yours; it’s a software development technique that envisions an application as a system of coupled services.

It opposes the monolithic structure where services are tightly interwoven. The benefits of dividing an application are as follows:

  • Modularity – Makes the elements of an application easier to understand, develop, test and is the main argument against monolithic design.
  • Scalability – Elements are independent, therefore, you can deploy them without interfering or causing needless trouble. It also allows separate monitoring and elimination of outside noise
  • Integration – This one is tough but focuses on upgrading legacy systems. In layman’s’ terms, old stuff made to appear as new stuff.
  • Distributed development – Enables parallelism in developing, deploying and scaling of services.

What’s all this FaaS about?

At the time of writing, Serverless is about Lambda functions from AWS, and cloud functions from Google and Azure. It is also quite interesting that the different products support only a handful of languages:

  • Amazon Lambda functions – Node, Python, Ruby, Java, Go, C#.
  • Lambda Edge – Node and Python
  • Google Cloud Functions – Node, Python Go
  • Microsoft Azure Functions – C#, Node, Java, Python
  • Kotlin uses the JVM (Java Virtual Machine) to run code, so even though not explicitly stated, it’s supports JVM and shares the same bed as Java.

Will it Serverless?

Node and Python seem to enjoy their presence in every serverless option, so if you are keen on a loosely coupled system their names should start appearing in your meetings. Now, containerization is the other cool trend we have mentioned and for that, we are using Docker Hub, the cool kids’ hang out place or a repository for Docker containers. In a few clicks and furious keystrokes, a few snapshots, and a table later we can finally announce the rankings for microservices support.

Node and Python seem to enjoy their presence in every serverless option, so if you are keen on a loosely coupled system their names should start appearing in your meetings. Now, containerization is the other cool trend we have mentioned and for that, we are using Docker Hub, the cool kids’ hang out place or a repository for Docker containers. In a few clicks and furious keystrokes, a few snapshots, and a table later we can finally announce the rankings for microservices support.

If you are eyeing a specific serverless vendor and their product, then you must pick what languages it supports. But if your meetings end up not being able to choose one, the perfect answer would be Python and Node as they enjoy the biggest share of support across this type of service. Other good choices are PHP and Go, however, they will see more success in Docker since serverless support is somewhat limited.

Performance – vroom, vroom

The first thing that greeds for your eye’s attention is performance, however, this stat is often alluring and deceiving. Basic search engine queries such as is X language fast will result in heavy opinionated results thanks to machine logic and SEO practices. In theory, a fast language uses fewer resources yet outputs the same or greater result – measured in ms. We will use CPU load as a parameter for comparing our languages.

Benchmarksgame

“Always look at the source code.

Maybe programs contributed to the project as part of a concerted language advocacy and marketing strategy, benefit from more programmer hours spent on program optimization.”

Before you get hasty with switching your entire stack to a different language just because a benchmark website has some cool graphs. Stop! Speed is important, but most users do not push the language to its limiting factors. Bad implementations never work in your favour to squeeze the last drop of juice. There are a lot of factors involving performance, thus when you choose your stack you need to consider how well they balance out.

Server-side Front-Runners

A newly released framework might address a specific issue, but its implementation might result in dependency issues or time wasted in learning the documentation. So, take these results with a grain of salt and understand that each side’s fanboys will arduously defend their preferred language as they have offset drawbacks with a bucket of subjective benefits.

Java, C#, Go and Kotlin represent the top contenders and provide almost the same level of performance across the board.

Server-side Catch-uppers

As we move down the list, Node.js is approximately 40% slower than Golang which sounds impactful, yet does not stop daily questions on Stackoverflow. Nodejs does a 50/50 on multithreading – the ability to run concurrent executions. Nodejs is multithreaded, however, the code runs in a single thread. The limitation is not of Node.js itself per se, but more of how the JavaScript engine V8 does things. There are ways to achieve multithreading, but they require some workaround code. Golang, on the other hand, comes with multithreading support right out of the box, so there is a plus.

Server-side Third-placers

Next in the sight of our overseer tower is PHP which lags, two times slower, behind Node and 3 times when compared to the top dogs. Hey, but Facebook is fast and I have heard it’s built on PHP? Well, initially it was, till due to speed and security concerns they have created Hack. A “better version” of PHP if we may say. Under the hood, it is a giant C wrapper for PHP.

Look who shows up last: Ruby and Python. What the heck? Python is the most popular language but walks with a cane in hand. Speed, my friends, is not black/white.

First, there is a certain point where any increase in speed of executions becomes irrelevant or imperceivably by the user. For example, if you were to implement original Python code in C it would run 200x faster. It is grandiose in numbers, but the result is just a simple decimal shave on the second or third spot. Can you sense the difference between 0.1 and 0.0005 seconds?

Second, as far as web apps go, there are different types of tasks and resources they require. Network bound tasks – HTTP requests – do not depend heavily on the language. For CPU bound, databases are among requests which take up the most time. A speedup can also occur if the database or queries themselves get a optimization boost. The DB engines use their own language and interact through common protocols.

Third, Python is crippled by the Python Global Interpreter Lock (GIL), which functions similar to a lock; only one thread is allowed to work the Python Interpreter. If you execute single-threaded programs you are lucky. However, if you are CPU bound or run multi-threaded code you will have to run some workarounds.

Server-side Compiling vs Interpreting

Last, there is the argument of compiled versus interpreted languages:

“Code Compiling” does not execute the code. It creates a binary version after which it can run countless times with no need for recompiling. There is less overhead as opposed to interpreting code.

“Code Interpreting” compiles the code line by line and executes it on the fly.

We can conclude that compiled languages are faster. At least at execution time as those skip the compilation requirement, after the first run. However, the code re-compiles each time a change occurs.

Third-party integrations

GitHub will serve as our tool to assess how capable a language is when it comes to integrating third-party software. A quick “sdk” suffix at the end of each language does the trick.

A software development kit (SDK) is a collection of tools written in another language, which comes as an installable package. Think of it as a library functioning as an API used to interface a particular programming language. They are often implemented for ultra-specific tasks and where switching to another language gains a lot of speed.

SDKs often include licenses, so a GPL- licensed SDK will be unsuitable for free software development.

Now to put everything in a proper way:

All in all, when it comes to how well a language displays integration capabilities; PHP and Java lead the charge. It is also possible to argue that a great SDK library excels in enterprise applications due to enhanced performance and optimization options.

To sum up

What constitutes the best server-side programming language? Well, I would be damned if in a thousand years every developer under the sky will voice the same name. Knowing, down the line, that you have made the “right” decision is exhilarating. And it is only right if you have taken into consideration all the factors at play before you proceed with the software.

In the benchmark section, Python came last in terms of performance… But that is not an impasse for EBS Integrator to develop Python projects. This is the same case for other businesses which have their needs and only certain languages can satisfy that itch. We believe that the compiled table will serve as a guide for your venture into the programming industry.

Now, where is that like, share, and subscribe application that we were working on, boys?