loading...

Node.js – the developer’s Swiss army knife

msedzielewski profile image Mike Sedzielewski Updated on ・8 min read

After reading Anthony's article on how JavaScript is eating the world, I thought I would share our experience with this technology. While Anthony focused on megacorps, I want to show examples of smaller (but fast-growing 🚀) companies from different industries using Node and JS in general. Here's a piece that appeared recently on our blog (you can skip the intro and jump straight to the case studies).

--

Today, 8 years after it was created, the popularity of Node.js is blooming. It’s gone through the Java-community critique, grown a number of big corp early adopters and even made it into space. In this post, I’d like to share two things about this phenomenon; firstly, just how substantial the Node.js growth we’re seeing nowadays is and secondly, how new and noteworthy companies use it to support their business.

Node.js and JavaScript

A part of Node’s fame comes from the outburst of JavaScript popularity. The recent Stack Overflow (a Q&A portal for programmers) survey shows that JavaScript is the most popular programming language according to 64,000 programmers. JavaScript has got to the top mainly because it’s a native technology for the web and the web is eating the world right now. But JavaScript has also become a leading technology elsewhere. Surprisingly, JavaScript tops not only web development, it has also conquered Desktop, Devops, and even Data Engineering too. These charts speak for themselves:




Anyway, the conclusion is that knowing JavaScript, there’s apparently a great chance you will use it in different areas of software development. Moreover, I think that having the same programming language across different projects in an organization is also one way to increase developer productivity.

Let’s come back to data: The Stack Overflow survey confirms what GitHub statistics have already shown; JavaScript beats Java, Python or PHP when it comes to number of actively developed projects on the GitHub platform. It’s worth noting that this is not a yesterday’s fad, this is a trend that has kept showing up for a couple of years already.

Finally, RedMonk, a software consultancy group, has been analyzing software trends since 2010. Last week, they put together an informative chart showing how StackOverflow and GitHub data relate to each other. If JavaScript is a clear winner in both, then this shouldn’t surprise you:

We have to admit it though, part of the JavaScript spike can, in turn, be attributed to Node’s growth. I guess these growths are interwoven somehow, but nobody can really tell the precise correlation here.

Node.js and tooling

The wave of JavaScript popularity has brought dozens of helpful tools and frameworks. Their goal is to increase developer productivity and eventually reduce time to market. In 2016, the Node.js dev workshop has been equipped with a couple of new and interesting tools:

  • FogCreek, a long-standing software company from New York known for building Trello, has launched Glitch. This small yet powerful tool allows rapid Node.js prototyping for developers. The coolest thing about Glitch is that you can code and run and host a full-fledged web application using only your browser! On top of that, 2 or more developers can collaborate on the project real-time (like in Google Docs). This feature is useful for new developers onboarding even if they work remotely. Finally, when your MVP app or microservice skeleton is ready to crystalize, you can export it to GitHub and continue the work in a standard, day to day environment.
  • Zeit’s flagship product, “Now”, wants to short short-circuit the cloud deployment process. Now allows you to host JavaScript websites, applications, and services in the cloud without the complicated cloud provider setup. They take care of source control and application scalability. To make your application run, all you have to do is run a single line of code. How cool is that?
  • Finally, Facebook released a new package manager called Yarn. Its main task is to make accessing JavaScript libraries faster and more secure. Developers around the world have received it well. Even Rails (one of the most popular non-javascript web technologies) has incorporated Yarn into their framework.

As you can see, massive Internet players, software legends, and freshman have all embraced the JavaScript and Node.js world and they continue to commit to it by releasing open source developer tools. But this is just the tip of the iceberg. Literally every day, the community releases dozens of helpful tools. And according to the research we’ve seen above, the JavaScript bandwagon is not going to slow down anytime soon.

Better tooling translates into the growing number of qualified developers. They love new technologies that make them more productive and it’s the increased supply of JavaScript (and Node.js in particular) devs which attracted early majority companies to this technology.

Now, let me present the 5 fast-growing Internet companies who successfully use Node.js in their business.

Node.js in social - Jodel

The Jodel app allows communities to show what's happening in their area in real-time. They started as a campus-centered app, but the geolocated tweet quickly became popular and emerged from the universities. Now, over 5 million people have downloaded the app and the “jodelling” can be heard in 12 countries.

Handling thousands of users and moderating hundreds of locations every day is a key challenge for the Jodel team. Fortunately, Node.js is built for exactly that; with Node.js scalability features, Jodel can consume and broadcast millions of messages every month without spending a ton on infrastructure. Speaking of infrastructure, to streamline application deployment the Jodel team uses Fightplan.js, one of those open source developer tools created and maintained by the very same community we mentioned earlier.

There’s more to it, of course. Using dozens of Node.js libraries and tools to scale their platform, Jodel became a genuine Node.js power user. It certainly wasn’t a goal in itself; the goal was to make millions of people happy about the app’s performance. And it wouldn’t be possible without Node and the community.

Node.js in education - meinUnterricht.de

k.lab, a Berlin-based edtech company, is the leader in the German teaching aids market. Started in 2011, they rolled-out their web platform - meinUnterricht.de - to most of the k-12 teachers in the country. Together with major publishers, k.lab converts traditional, paper-based materials into their digital and interactive counterparts. As if this wasn’t enough, the portal offers tons of quality educational videos too. The platform is used by thousands of teachers who visit meinUnterricht.de to browse its massive set of teaching content every day.

To process and deliver this number of documents, k.lab chose Node.js. The primary use case of their Node-based platform is to keep content workflow alive. This includes: copyrights processing, optimizing content for multiple devices, uploading it to the cloud and finally handling users’ downloads. Also, k.lab uses the Node-based web server - express.js - to run the meinUnterricht website. Its role is to provide teachers with content according to their subscription plan.

Such a complex application needs to talk to large numbers of 3rd party tools like search engines or subscription platforms. Fortunately, connecting Node to other services is easy because vendors gladly provide plugins for one of the most popular technologies.

Node.js in ecommerce - Grover

2 years ago, Michael Cassau, the founder of Grover, went on a journey to revolutionize the way we buy electronics. His platform enables you to rent a device. You hear me right. You can rent the newest iPhone or drone, pay for it as you go, and return it if you don’t need it anymore.

Although the business sounds simple, it’s not. It requires exchanging information between different systems like CRM, marketing automation, customer verification, stock management, shipping, reporting, and more. Nowadays, e-commerce services use REST APIs and JSON as the primary format for data exchange. Because JSON (JavaScript Object Notation) is a native format for Node.js, it handles all the data processing seamlessly for Grover.

You can see that even the top CRM and e-commerce players like Salesforce or MailChimp support Node.js integration with dedicated software development kits. And this allows you to glue different systems to build a turnkey solution much faster.

Node.js in big data & image processing - ShareIQ

As you can see in the Stack Overflow survey, JavaScript also leads the Data Engineering category. ShareIQ is a good example of how JS has made it to the top there. Their mission is to give marketers full control of their visual marketing investment. How do they achieve that?

ShareIQ developed unique technology to recognize brand property in images scattered all over the Internet. They crawl and analyze millions of websites to learn how the marketing assets of their clients are used. The main goal of this analysis is to find influencers and reduce fraud.

Crawling, processing, and creating insights out of billions of images requires ultimate performance. The ShareIQ team has proven that Node.js is once again a perfect fit for such a use case.

Node.js in APIs - Voucherify

When reviewing the Grover case, we mentioned that their platforms talks to several marketing automation tools. Voucherify is one of them. The team behind Voucherify wants to empower marketing teams with a promotional infrastructure which so far was reserved only to massive e-commerce players. They do this by providing the dashboard and REST API to help you build and automate coupon, gift card, and referral campaigns.

There are 2 challenges: The first one is to map and automate the coupon lifecycle. This consists of generating unique codes, distributing them through various marketing channels like email or SMS, accepting redemptions from multiple customer touch points online and offline, and finally calculating the return on investment. The scale brings the second one. When you process millions of codes, you’d better have a performant system. Otherwise, the end customers will soon get disappointed when their codes don’t work at the checkout.

Voucherify uses Node.js, because Node.js, as we’ve learned from the previous sections, helps with both issues.

Summary

The cases I have put together show that Node.js can be used successfully in a number of different business domains. But what is it that makes me think these companies really are happy about Node.js? Well, Jodel, k.lab, Grover, ShareIQ, and Voucherify all happen to be our clients and we’ve seen how they go about all this behind the scenes.

Posted on by:

Discussion

markdown guide
 

It's very yellow header. I agree that node is great and become very mature in the last couple of years, but it's definitely not a Swiss's army knife. Event-driven programming is a great idea for i/o bound operations which is almost all of the api's. But single execution thread and dynamic nature shoots you in the foot in case of heavy cpu bound operations. Of course you can write a c++ module for node, but either way you gonna get more suitable instrument for this (some multithreaded stuff, like go, rust, c# or java). Machine learning and data science also struggles due to lack of tooling (AFAIK every non-data-scientific language sucks besides python).

 

I think the comparison to a swiss army knife is rather apt. It has multiple uses, but in quite many cases, it will only be a more or less poorly performing drop-in replacement for the real tools of the trade.

What I like about JavaScript is how it is developing as a language, a community and and an ecosystem. Sure, we won't see it in real-time-critical applications soon, but that's fine for now. Eventually, computers will become so fast that it won't make a difference anymore.

By the way, you can actually do multithreading in JS, in the browser either using Workers or WebGL and in node.js using childProcess.fork().

 

Agreed! I quite like C# with .NET core for data science as I can get it to scale nicely on Linux docker containers or Hadoop clusters.

I found when writing my specifically odd types of dynamic neural nets in JS is that JavaScript's difficulty with number precision and dates always left me uncertain that I wasn't losing data.

I'm keen to try compiling C# to wasm.

 

Node is great for automation in tooling, but definitely has its quirks. It's great for APIs if you outputting JSON, but it's still your worst choice for RDBMS databases. Golang also dealing with asynchronous code much better. Even with async/await, still not easy to manage async code, never will. I don't have experience with Java, C#, etc., but seriously, just look at goroutines, why other languages f*cking with us when we have to write asynchronous code!? And you will have to write async code in Node.js, a lot. And you will screw it up, just like anyone else.

My favourite one when a well known package author gave me a "solution" for executing it's function asynchronously and taking screenshots to files one by one. His promise example didn't worked. Then I thinkered a little bit and rewrote it with async/await. Of course, his answer was, he just gave me "directions" how to write such code, his example not meant to work... :)

Even the goddamn package authors (which package using promises under the hood) don't know how to write asynchronous code properly in Node.js. I don't know, too. It's a mess. Save yourself some seizures and look at another languages as well.

Modern re-thought languages like the Golang takes away this problem from you.

 
 

It’s gone through the Java-community critique
I stopped reading here.