This post contains content about Now 1.0 – Learn about the latest version, Now 2.0.
Now 2.0 - Upgrade Available
Thursday, August 18th 2016 (about 3 years ago)

COBOL in the cloud

Olli Vanhoja (@OVanhoja)

A few days ago we announced support for Dockerfile compilation. In practical terms, it means that Now became a universal platform with support for the three primary compilation targets of the Internet:

  • Static site hosting (now-serve)
  • JavaScript frontends / Node.js apps (package.json)
  • Linux containers (Dockerfile)

When architecting your backends, microservices have emerged as one of the most popular design patterns in recent times. Now fully embraces this.

For example, you can separate API endpoints into discrete deployments, as opposed to one large API monolith. Later, you can run now alias to give each deployment a friendly subdomain.

Perhaps one of the most interesting benefits of the microservice architecture is that you can iterate and refactor them in isolation.

The main reason for this is that the API contract is configured by the networking protocol instead of classes or functions in your code.

Since Now serves your deployments' traffic automatically over HTTP/2 with SSL, you're free to even supplant programming languages over time.

Today we decided to provide some, you could say, "unusual evidence" for this claim. We deployed a small service in COBOL, a programming language first conceived in the 1950s:

We made its source code public and we are also inaugurating a Github Organization dedicated to examples apps you can deploy to our cloud: Now Examples.

Oh and, by the way, we found that configuring routes with one of the available webframeworks was actually not that bad ヽ(´ー`)ノ! Take a look at config.cbl:

move "/"                           to routing-pattern(1).
move "indexweb"                    to routing-destiny(1).

move "/showsum/%value1/%value2"    to routing-pattern(2).
move "showsum"                     to routing-destiny(2).

move "/showname/%value"            to routing-pattern(3).
move "showname"                    to routing-destiny(3).

Enjoy deploying the past, present and future into the timeless clouds!