THE NETREXX language for the Java VM has been let go by IBM today to a third party, and it means one of Java´s hidden gems will surely go forth and multiply. NetRexx is the work of former IBMer Mike Cowlishaw (MFC hereinafter), and the last incarnation of the Rexx family of languages. It mixes the simplicity of the traditional "Rexx" scripting language -MFC´s first implementation-, with the multi-platform capabilities of Java.
Software created with NetRexx run on top of the Java virtual machine on any capable OS without recompiling. Cowlishaw calls it in his seminal book TNL "a new human-oriented programming language", and once you read some sample NetRexx source code, you will realize why. NetRexx has developed since its origins in 1997 a small but loyal base of programmers and enthusiasts. However, IBM kept it under the radar, and as a "Freeware" download, neglected for years in some dark corner of Big Blue´s global web maze.
After yesterday´s announcement, it will be developed going forward by the Rexx Language Association -RexxLA hereinafter-, and released under the ICU License, a similar license to the MIT, which includes additional clauses about documentation and promotion.
René Vincent Jansen, the current president of the RexxLA, says that NetRexx "enables the programmer to use everything that is in the Java platform." and calls it "an undeservedly unknown programming language". Today, he added that IBM’s move "has secured the future of NetRexx, our favorite computer language, and enables us to do work on it to keep it up to date whenever this seems necessary. " He added that the code will be made available shortly on the www.netrexx.org web site operated by the RexxLA.
NetRexx: Son of Rexx, meets Java
The Rexx language journey began in the late 1970s to early 1980s and it involved boring mainframes. The Whackypedia dubs the Rexx language "a precursor to TCL and Python", and this early incantation of Rexx is what is nowadays referred to as "Classic Rexx". An Open-Source version of Classic Rexx by a third party is dubbed "Regina Rexx".
But what brought Rexx to the masses was IBM’s first 32-bit OS/2 version 2.0 released in 1992, where it was the OS’s built-in scripting language. As the popularity of IBM´s 32-bit desktop OS contender grew – thanks to IBM’s OS/2 2.1, and peaking with Warp 3.0 by mid 1994, so did the popularity of Rexx.
Before Rexx for OS/2, there was a quite popular Rexx implementation for the Commodore Amiga, which CBM dubbed "ARexx" (Amiga Rexx). Both the OS/2 and Amiga versions expanded Rexx outside its niche market of IBMers working with mainframes -some of that mainframe Rexx user and fan base, surprisingly, still exists.
MFC´s object-oriented flavor of Rexx, dubbed "Object Rexx" and formerly a commercial product by IBM, was released as open source back in 2005. Yet, it never attracted the same following as traditional Rexx, perhaps because object-oriented programming made it lose some of its simplicity, readability and in MFC’s words the "human centric" design.
With the impending release of open-source NetRexx, the code hackers among you might want to learn more about it. I suggest getting a copy of Mike Cowlishaw’s book. As the inventor of the language, also authored the most didactic introduction to programming NetRexx, with the aptly titled "The NetRexx Language", which can still be found for purchase in good old fashioned dead tree format in the US and also in Blighty. People who want to get into the language might want to also grab IBM´s RedBook on the language over here.
Some NetRexx hidden tricks
If you think that NetRexx is only useful for developing Java byte code applications without actually learning the Java programming language, you’re wrong. NetRexx can do many tricks, including using it for scripting in the context of Java applications. Rony G. Flatscher, a NetRexx enthusiast from Austria, wrote:
"It has been possible for many years already to employ NetRexx, Regina, Object Rexx and ooRexx for scripting in the context of Java applications. And in a "two-way" bridge."
He points us towards Big Blue’s open source "Bean Scripting Framework (BSF)" now developed at the Apache Software Foundation. He adds that scripting support for Regina Rexx -the most popular open source version of "Classic" Rexx-, ooRexx and any other Rexx-SAA-compliant Rexx interpreter was added with "BSF4Rexx".
A work-in-progress implementation of NetRexx as a scripting engine under Sun´s ="Sun JSR223 Specification" href="http://java.sun.com/developer/technicalArticles/J2SE/Desktop/scripting/" target="_blank">JSR223 specification, which was developed by Kermit Kiser, can be found "as is" over here (ZIP file download). But I suggest you start with the basics before trying heavy hacking.
But wait, there’s more
Finally, for those lazy enough not to learn NetRexx, there exists a "Classic Rexx" to NetRexx translator. Dubbed "Rexx2Nrx" this utility and run-time takes Rexx source code and translates it to NetRexx as far as possible. Rexx subroutines/functions are translated to proper NetRexx/Java classes and methods. It is developed by another Austrian named Thomas Schneider, and you can find it here.
While the popular Oracle NetBeans IDE does not -yet- support NetRexx, someone from the NetRexx community will surely fill the gap soon. In the meantime, there is a very nice "NetRexx Plug-in for jEdit", the popular Java-based general purpose text (and programmer’s) editor. Need to create simple GUI (Swing) apps? It’s possible too.
Not excited yet? How about if I told you that it’s even possible to write Android apps with NetRexx? NetRexx enthusiast David Requena has even talked about the possibility of getting NetRexx code working on Blackberries, after the open source version is delivered by the RexxLA.
So, why is NetRexx special?
Languages like JRuby and Jython are successful because they bring simplicity for programmers along with the power of the "run anywhere" Java virtual machine, and accessing the powerful Java APIs. NetRexx adds human-centric design and readability to the mix. Plus, after some uncertainty after Oracle’s acquisition of Sun Microsystems, the waters have settled and Java´s future looks brighter than ever: Apple joining Oracle’s OpenJDK open-source Java project, JDK 7 soon to be released, JDK8 in the works, and the Oracle Netbeans open source IDE being heavily invested on. The icing on the cake is that Java’s arch-rival architecture Mono -Novell’s .NET clone is up in the air after the Attachmate acquisition, and faces an uncertain future on its own.
People in the know around the Rexx family of languages share this view of the Java VM as one of Rexx lifesavers, and have been expressing it for a long time. For instance, take Mike Hughes, a NetRexx enthusiast, who wrote:
"Back on OS/2, I used Rexx and Object Rexx extensively, and now I make regular use of NetRexx, any time I want to write a little tool for my own use. NetRexx is by far the best of the Rexx language’s iterations, IMO. It takes some getting used to, if you’re really set on the older languages, but the advantage of being able to easily integrate Java libraries is just overwhelming. Making extensions for Rexx in C and trying to get them portable in any way was a nightmare. If Rexx is going to survive, NetRexx is its best hope."
For one, this scribbler hopes that now that it has been set free from IBM’s neglect, the Open Source NetRexx can bring lots of human beings to the popular Java software platform, without the hassle and learning curve of the namesake language.