InfoQ

News

Programming languages in future systems

Posted by Niclas Nilsson on Jan 03, 2008 07:42 PM

Community
Architecture
Topics
Domain Specific Languages,
Dynamic Languages,
Programming
Tags
CLR,
JVM

The trend seems to be clear; in the next few years there will an increase in adoption of new programming languages. Not primarily to replace the ones we currently use, but to mix languages and use the right language for the problem.

But what is the right language for a particular problem? In a recent blog post, JRuby developer Ola Bini dives into the topic from a new angle. Multi-lingual programming, also known as polyglot programming, has been covered earlier by InfoQ, but Bini describes the phenomenon in the context of how we may build future systems; which types of languages we may use - and for what.

Bini describes three different layers and the languages, or rather language types, that fits into these layers. No, not the classical presentation, business, and data layers; Bini slices the world differently:

  • a stable layer - not much application functionality, built with static languages
  • a dynamic layer - a lot of application functionality, built with dynamic languages
  • a domain layer - a lot of application functionality, built with domain specific languages

Bini describes the stable layer:

The first layer is what I called the stable layer. It’s not a very large part of the application in terms of functionality. But it’s the part that everything else builds on top off, and is as such a very important part of it. This layer is the layer where static type safety will really help.

The dynamic layer is where most of the application functionality exists:

The second layer is the dynamic layer. This is where maybe half the application code resides. The language types here are predominantly dynamic, strongly typed languages […]

Also considering the dynamic layer, he adds:

It’s a nice and productive place to be, and obviously, with my fascination for JVM languages, I believe that it’s the interplay between this layer and the stable layer that is really powerful.

In the domain layer, Bini bets on the emergent DSL movement.

The third layer is the domain layer. It should be implemented in DSL’s, one or many depending on the needs of the system. In most cases it’s probably enough to implement it as an internal DSL within the dynamic layer, and in those cases the second and third layer are not as easily distinguishable. But in some cases it’s warranted to have an external DSL that can be interacted with. A typical example might be something like a rules engine (like Drools).

David N. Welton wrote a response to Bini’s post, where he describes his doubts about this evolution:

I’m dubious, and wonder what he would consider to be the underlying sociological and economic factors driving this change. Programming languages are, in the end, about people in all their weirdness, so to understand where languages are going to go, you have to consider those human factors […]

Welton refers to an article he wrote a couple of years ago that analyzes the economics of programming languages. In the article, Welton finds that since most language implementations are free today, the only way to get better economics using a new language is if it makes the code:

  • easier to write - more people can use it
  • more efficient - saving resources
  • higher quality - less bug fixing
  • more productive - lets you do complex things easily

Ola Bini wraps up by explaining that he does not believe in the next big language, even within one layer:

But I need to make one thing clear - I don’t believe there will be a winner at any of these layers. In fact, I think it would be a clearly bad thing if any one language won at any layer. That means, I’m seeing a future where we have Jython and JRuby and Rhino and several other languages coexisting at the same layer. There doesn’t need to be any rivalry or language wars.

Bini has done big contributions to make mixing languages on virtual machine level possible by his work on JRuby, and many other have done the same for other languages. On the other big virtual machine platform, Microsoft prepared for multiple languages from the start by providing VB.NET, C# and C++ implementations for the Common Language Runtime. Recently, they also released the Dynamic Language Runtime, on top of which IronPython and IronRuby is built, which emphasizes that .NET is a multi-language platform.

But the article still leaves interesting questions:

  • Is Ola Bini’s view of different layers and languages the way the future will play out?
  • What are the pros and cons of mixing languages within one virtual machine?
  • Are other potential ways of mixing languages a better choice? (Examples could be service oriented applications where each service is implemented in the most suitable language, or in the case of a restful web application; slice it vertically into many small applications at url level.)

In short, how will future systems utilize programming languages?

2 comments

Reply

Great coverage. by Abhay Bakshi Posted Jan 4, 2008 3:33 PM
http://www.dzone.com/links/programming_languages_in_future_systems.html by Abhay Bakshi Posted Jan 4, 2008 3:39 PM
  1. Back to top

    Great coverage.

    Jan 4, 2008 3:33 PM by Abhay Bakshi

    This is a great coverage of the topic by Niclas Nilsson. I expect a lot of discussion with all the intelligent, visionary, and experienced programmers to gather here and comment. It looks like my comments are the first ones on this thread. But, I encourage a lot of feedback coming from many industry leaders. Wake up, guys!! My experience has been limited to one language Java, and C++ from way past. I've been also using Java-based frameworks a whole lot. But, regarding topics such as CLR, JVM, DSL, I expect multiple comments pouring in at this thread from multiple leaders in the industry. Best regards, Abhay

  2. A lot of interest in this thread is seen at: http://www.dzone.com/links/programming_languages_in_future_systems.html

Exclusive Content

Intentional Software - Democratizing Software Creation

Business users doing programming? Simonyi and Kolk presents how Intentional Software offers a radical new software approach that separates business knowledge from software engineering knowledge.

Getting Started with Grails

Jason Rudolph discusses Java/Grails integration, Grails plugins, creating a Grails sample application, Grails app structure, data querying and persistence, validation, controllers and tag libraries.

Creating Product Owner Success

The Scrum Product Owner role is powerful, valuable and challenging to implement. It brings healthier relationships between customers and developers, and competitive advantage - if you do it right.

Book Excerpt and Interview: Effective Java, Second Edition

Effective Java, Second Edition by Joshua Bloch is an updated version of the classic first edition, which won a 2001 Jolt Award. InfoQ asked Bloch questions about the areas that the new edition covers.

Tapestry for Nonbelievers

A new article by I. Drobiazko and R. Zubairov introduces v. 5 of the Apache Tapestry component-oriented web framework. The tutorial shows how to create a component and covers IoC in Tapestry and Ajax.

Pete Lacey on REST and Web Services

In this interview, Burton Group consultant Pete Lacey talks to Stefan Tilkov about his disillusionment with SOAP, his opinion on REST, and addresses some of the perceived shortcomings REST vs. WS-*.

Business Natural Languages Development in Ruby

Jay Fields presents his concept of Business Natural Languages - a type of Domain Specific Languages geared towards being readable by domain experts.

Distributed Version Control Systems: A Not-So-Quick Guide Through

Adoption and interest for Distributed Version Control Systems is constantly rising. We will introduce the concept of DVCS and have a look at 3 actors in the area: git, Mercurial and Bazaar.