It was a short period when everything had "Flavor Crystals:" chewing gum, deodorant, sports drink, toothpaste, air fresh, anyway. If you had a product, it could be made more convincing with taste crystals. When the term "Cloud" was first created, it merely referred to the idea that computer power on the Internet should be bought and sold as electricity. Gradually, "Cloud" has gained many meanings and become Flavor Crystal in the modern IT world. However, I wonder if Cloud-related technologies (including DevOps and containers) have gained all the attention and no room to discuss other trends. In this post, I thought I should mention some interesting things the Big Nerd Ranch web team is working on.
Trends That Create Server Technology
There are three major trends that push server side innovations: [1
Let's start with a response to the first trend: Facebook recognized the growing importance of users in developing countries by creating the Facebook Lite app for Android. In their writing about Facebook Lite's architecture, they describe a system like:
- Does not use web services, but communicates it over raw TLS.
- Compresses messages in each direction.
- Creates assets before The client requests them if possible.
Thus, Facebook can create a highly responsive user experience over 2G networks.
For twenty years, we have written servers that respond to HTTP requests coming from clients. And now Facebook is writing a server that does not use HTTP ?! And the server does not wait for requests, but pushes things to the client as it thinks the customer might need?! Everything has changed.
Second Trend: Users will collaborate in real time. If a user changes a piece of data while another user views it, the server must change the change to the client. How do we write clients who always listen for new data from the server? How do we write servers that perform bi-directional communication via WebSockets?
Third Trend: The Internet of Things means that billions of new devices get IP addresses and are placed on the Internet. And then they will begin to spy events. Processing and storing these streams leads to great interest in power management technologies (like Apache Kafka) and databases that deal with time series data with grace (like Cassandra).
In the same way as a collaboration application, a thermostat on the Internet requires bidirectional communication with the server. The thermostat sends a flow of temperatures to the server and waits for order from that server.
Learning from gaming companies
Fortunately, engineers who have worked very hard to create servers that can support two-way communication with millions of clients: the massive multiplayer online gaming servers. If you want to know what the future of client / server communication looks like, think of World of Warcraft. Each server will have hundreds of thousands of clients attached. For each user, the server will have an outlet open to the user that enables two-way communication.
In the game server development community, there are two popular approaches to this issue. One approach is to have a thread with a thread that never blocks. The poster child for this approach is Node.js. The second approach is to use a language with very light threads so that each shelf can be monitored by its own thread. The poster child for this approach is Erlang.
At Big Nerd Ranch, we appreciate both approaches. We learn how to write a chat server using Node.js in our book "Front-End Web Development: The Big Nerd Ranch Guide". However, we find Erlang's approach (light strings coordinated using the message going through channels) to be consistently elegant and efficient. Erlangs syntax can be a bit invisible if you have not worked in it before, so we usually work with his cousin Elixir. Erlang / Elixir also comes with OTP, a very mature and sophisticated framework for developing network servers.
How We Can Help
Maybe you're thinking about developing a mobile or networking that requires more sophisticated server smarts than your team feels comfortable to create. Big Nerd Ranch can help.