In Search of the Perfect UI PDF Print E-mail
Programming - Web Languages
Written by Chris Smith   
Friday, 15 January 2010 00:00

Experts wrestle over the best way for RPG programmers to build Web apps as one uncovers a nifty new JavaScript tool.

 

The enthusiasm that PHP has elicited in the IBM i community among those who have embraced a new language for Web development warms the heart, but not everyone is convinced that PHP is enterprise-ready.

 

PHP in the IBM community is being supported strongly by Zend Technologies and Business Computer Design (BCD) and, to some extent, IBM, though Big Blue seems to favor EGL as a more suitable language for business applications. RPG programmers who thought they could easily learn Java and start developing for the Web a few years back were in large measure frustrated by the inherent challenges.

 

The apparent ease with which a beginner can start programming in PHP combined with the support that IBM has lent to Zend by facilitating PHP running on IBM i through bundling Zend Core with new machines is a veritable Pied Piper when it comes to leading RPG programmers to a new land. But how far can one go with PHP, and is it really "enterprise-ready" as Zend would have us believe?

 

Author Joe Pluta dissects the issues facing business application developers who want to create Web apps in his article in last Wednesday's MC iApplication Designer, "Scripting Languages on i: The Good, the Bad, the Ugly." Pluta addresses the problem of creating dynamic Web pages and weighs the various approaches one can take. He concludes that learning one language such as PHP isn't going to cut it. Nothing short of learning both PHP (or another scripting language) and JavaScript will get you where you want to go. The notable exception? If you have time to learn only one language, learn EGL. Says Pluta: "With EGL, you learn a single syntax and the EGL tool generates the appropriate code, be it HTML for the thin-client pages or Java for the server-side code or JavaScript for the client-side."

 

There you go. So why is PHP so much more popular today than EGL? One might ask, why is today's hot new restaurant tomorrow's shuttered storefront? People are lemmings, and we all move together in a group. Didn't you know? It's safer.

 

I was amused recently by RPG/Java developer Aaron Bartell's (www.krengeltech.com) challenging Mike Pavlak, Solutions Consultant at Zend Technologies, in a post in IBM Systems Magazine. Bartell, whose mind is a churning volcano of inquisitive thought, politely asks Craig Johnson, the product manager for IBM i, if he could provide the research supporting Zend's claim that PHP is "enterprise ready." Pavlak steps in to answer the post by saying, "Of course PHP is enterprise ready!" but then explains that developers must use the right tool for the right job, and nothing could replace our "beloved" RPG as an enterprise-class language for its "efficiency and scalability." Pavlak also makes the point that there are PHP developers and then there are PHP developers (something we have found to be true at MC Press Online, by the way, since our site is based on Joomla components written in PHP). "The hobbyist PHP developer does not an enterprise developer make," notes Pavlak. There are many "best practices wrapped up in frameworks, templating systems and bound parameters" that may need to be employed when undertaking an enterprise-level project done in PHP. Still unconvinced, Bartell acknowledges he hasn't yet arrived at that level with PHP but vows to keep an open mind.

 

It's clear that RPG programmers are today looking for the way to the Promised Land that seems to have passed them by with the explosion in Web-based content and applications. I think of thought-leaders like Bartell, Pluta, and Pavlak as veritable Charlton Hestons, the Ten Commandments in one hand, a wooden staff in the other. "Follow me. We'll find a way out of this wilderness eventually!" (Let's just hope it doesn't take 40 years!)

 

The point of this article, though, is to give credit where credit is due and to highlight a possible gem that Bartell has uncovered in the form of Ext JS. Last month, Bartell wrote the following in a December IBM Systems Magazine article, "Exploring RPG and Ext JS": "I've long been in search of the next solid UI that RPG programmers can safely adopt and count on to serve us for the next 10 to 15 years. The IT industry as a whole seems to be suffering from a UI identity crisis—nobody can find the right approach that works well in many situations."

 

What he has come up with as a result of his search is a set of out-of-the box UI components that can be used to create rich Internet applications. He notes that components include input boxes, buttons, grids of data, tabbed panes etc. Begun in 2006 by Jack Slocum as a set of extension utilities for the Yahoo User Interface (YUI), Ext is a client-side JavaScript framework for building Web applications. Slocum and colleagues formed a company in 2007, and Ext is now dual licensed under GPL and commercial license. The Ext JS products page shows the many UI components that Ext JS supports.

 

A trial version of Ext JS can be downloaded free from www.extjs.com. Ext JS is a supporter of open-source software, and its open-source version of Ext JS is an appropriate option if you are creating an open-source application with a license compatible with the GNU GPL license v3. Commercial license fees of as little as $329 per year for a single developer are available, and enterprise licenses range up to $27,239.


Chris Smith
About the Author:

Chris Smith is the Senior News Editor at MC Press Online and is responsible for the news content on the company's Web site. Chris has been writing about the IBM midrange industry since 1992 when he signed on with Duke Communications as West Coast Editor of News 3x/400. With a bachelor's from the University of California at Berkeley, where he majored in English and minored in Journalism, and a master's in Journalism from the University of Colorado, Boulder, Chris later studied computer programming and AS/400 operations at Long Beach City College. An award-winning writer with two Maggie Awards, four business books, and a collection of poetry to his credit, Chris began his newspaper career as a reporter in northern California, later worked as night city editor for the Rocky Mountain News in Denver, and went on to edit a national cable television trade magazine. He was Communications Manager for McDonnell Douglas Corp. in Long Beach, Calif., before it merged with Boeing, and oversaw implementation of the company's first IBM desktop publishing system there. An editor for MC Press Online since 2007, Chris has authored some 300 articles on a broad range of topics surrounding the IBM midrange platform that have appeared in the company's five industry-leading newsletters. He can be reached at csmith@mcpressonline.com.

Read More >>
Last Updated on Friday, 15 January 2010 00:00
 
rdunn61
What I find always missing from conversations regarding browser UI\'s for the I5 is the freeware CGIDEV2 [url>www.easy400.net. Comes in a COBOL version also! Using the worlds best buniness language (RPG) to easily build browser based interfaces always made sense to me.CGIDEV2 will run blazzingly fast on the smallest as/400/isesies or i5 that exist. Systems that could not even install, much less run, PHP or Java/EGL for hardware or software reasons. Add to this the fact that you already have the in house expertise (RPG) on the most difficult part of browser based development, the host system language, and you have a winner. What needs to be learned is the "client side" (HTML, CSS and Javascript). This technology would need to be learned no matter which host programming language you choose. While not easy, is definitely easier than having to learn HTML,CSS,Javascript AND a new host based language/framework,etc..! There are those who say use the best tool for the job. To them I say do you need PHP,Java/EGL,.Net, or WHATEVER, to call RPG programs, modules and procedures that you trust to do the "real" work? If RPG is the best language to run your business, why is RPG not good enough to read and parse browser input? How does introducing new host based languages for a specific task, like building web sites make sense when you have no expertise in that area and no money for traning? If you think that one of these "fiat" languages is going to do a better job at decreasing your backlog than the best business language ever developed, I have some bad news for you.
mpavlak
You are an enigma wrapped in a contradiction! You complain that no one talks about the free ware. Hello? Are you aware that both PHP and EGL are no-charge solutions and that RPG is not? PHP does not require a Web Application Server and EGL will run perfectly well under IAS or Tomcat, from what I understand. I am by no means an expert at EGL so I will let my esteemed colleagues speak up about that. I am really not interested in getting into a religious war about programming languages. This has been done to death and will get everyone nowhere quick! Instead we should focus on the advantages and learn a bit about the technologies before calling names. But, maybe more telling, the number of kids coming out of school with Java and .Net talent. Not too many kids enrolled in the RPG classes, these days. One of the most common comments I keep hearing from IT management is that they fear the large number of RPG pros that are retiring vs. the small number who are coming in the door and the sucking noise they hear is their technological relevance flying away. I am doing what I can to increase the number of IBM i classes out there by teaching online classes at SystemiNetwork and the local community college. To paraphrase the great communicator (Trevor Perry) "quit bitching and start doing". Then there is IBM\'s completely mixed messaging about IBM i as a solution. Our precious OS seems to wander aimlessly among the POWER systems shuffle searching for someone to take it in. Take a look at the latest copy of IBM System Magazine, POWER Systems Edition. The only feature article that mentions IBM i in any significance talks about how the "grape" company moved off the i platform to Linux! So, with that said, should I share with you the number of RPG developers I know who are worried about their jobs? I just did a tour of user groups in the Pacific Northwest and discovered that learning a new technology like PHP is called "job insurance". When they off-shore your job and you need to put food on the table, who cares what language you are programing. The reality is whether your skills can deliver the goods in demand. And with 1/3 of the Internet running PHP, wouldn\'t you agree that there may be some security in learning this "Fiat" language? (btw:Fiat is capitalized unless you are referring to a command or decree.) I do not believe that the RPG jobs are going to disappear all that quickly. While I do not live in fear of "the hatchet" I do still respect it. The growth of RPG in the US is not what it was. We used to fill three sections of RPG at the local community college. Now we are lucky to run the class online with a handful of students. The PHP class ran with 24 open positions and completely filled!. I can\'t speak for the other languages, but PHP runs quite nicely on old hardware. I have been working on it with machines as old as a 270. And the folks at [url>www.WMCPA.org are running their new site in PHP on an old 800 series machine. Regards, Mike
rdunn61
Mike- The radical idea behind my post is that if you are introducing a paradigm shift in something (say, web verses green screen development) and you approach it knowing something, it is better than approaching it knowing nothing. I have read nothing to shake my belief in that statement. Some nit-picky stuff: 1). For all practical, statistical purposes, RPG (AS/4000/iSeries/I5 variety) has never been taught in college (number of collages with IT degrees verses the number of colleges with IT degrees that have a AS/4000/iSeries/I5 program). Management cares about cost (supply and demand) and it stands to reason that if you have hundreds of thousands of Java/PHP/,Net developers, you can get them cheaper than a more limited number of RPG centric people. More interest in RPG education would be a function of IBM selling more boxes and IBM\'s commitment to the language, not the other way around. I have concerns on both these points. 2). All software has prerequisites of some kind. I do stand by my facts that CGIDEV2 will run on more versions of AS/4000/iSeries/I5 than Zend/PHP/JAVA/EGL (V4R4 is the earliest, though I\'m sure someone on the forum could get you a copy of CGIDEV2 that works on older releases!). I am not criticizing Zend for not being able to run on as many versions of the AS/4000/iSeries/I5 as CGIDEV2. I\'m just stating the fact CGIDEV2 is a viable solution for those who\'s hardware/software (for whatever reason) do not meet the minimum requirements of PHP/Java. Regards, -Bob
J.Pluta
Hi Robert! As Mike points out, EGL doesn\'t require WebSphere. In fact, it doesn\'t even require a web application server like Tomcat or IAS; it runs perfectly fine using just the i\'s HTTP server (although there\'s a lot more infrastructure available when you go to a J2EE server like Tomcat or WebSphere). EGL is a great language; it\'s free and it\'s very business-oriented. If I were you, I\'d take a look at EGL Community Edition to see what\'s up before you ignore it out of hand. I can tell you this: while you can probably use CGIDEV2 to create a thin client application, you\'ll never be able to do a rich client with it. You can create one or two Rich UI pages, but the sheer amount of work required to create a fully interactive Web 2.0 application with jut a scripting language like CGIDEV2 is out of the reach of even the most skilled i programmers, mostly because you have to use CGIDEV2 to write dynamic JavaScript code. Not for the faint of heart!
rdunn61
Hi Joe- Good to hear from you. As a matter of fact, I thought this topic would garner your attention sooner. Mike beat you by 2 days! In my copious free time, am evaluating some different web technologies available on i5. I have to be able to give clients the skinny on these technologies and why I think they would or would not for for their current situation. EGL is on my hit list. I am stuck on V5R4, hopefully that won\'t be a problem. As far as javascript, or any client side scripting language for that matter, I am afraid we (host language developers) are all in the same boat. Javascript is after all a programming language with many libraries, frameworks and even object orientation . Your mentioning of a rich user interface in EGL immediately got my attention. After all, it is all about the interface! Cutting procedural javascript code is not too difficult and even dynamically loading javascript arrays is bearable, but I am really looking for ways to hide some of the complexity of client side coding from the host language developer. It will be interesting to see how EGL handles that. -Bob
mpavlak
Bob, I wonder where you got your info from on RPG being taught in college. I personally have taught RPG classes for REAL college credit in a REAL college degree. The classes would fill each semester for the full time instructors and they would ask me and a few other folks in the area to pick up an extra run of the class as adjunct faculty. It was a great time and many of my students have very interesting and diverse careers. Some still in RPG and others have moved into other roles like Project Management or Networking. But that is only around Chicago. I know of MANY colleges around the country that have or had RPG curricula. Current popularity isn\'t what it once was. But is that because of the lack of need or the perception of the lack of need. My point is that employers are still looking to implement solutions over technologies. But when that solutions in not present they need to choose a technology and roll their own. having choices is AWESOME. I won\'t argue about the backward compatibility of RPG-CGI. If that works, good luck and God bless! But I have many customers express to me their concerns about their RPG staff retiring in the next few years with no one in sight to fill the role. Absorbing a new technology like PHP gives the concerned RPG\'ers a few more years in IT and the IT manager an opportunity to marry the yougsters with the veteran RPG devleopers to insure a new transition. Heck, we were even approached by a couple of customers to put together a class called RPG for the PHP programmer! Have fun! Mike
efnkay
It\'s good to know that RPG still is involved in some educational offerings though I\'m not sure if the school I attended still offers it. That\'s back in Michigan. That could be a flag for indication right there. I wonder how the job market looks to those currently enrolled or considering enrollment in RPG and related classes? I know when I took and finished similar course work over 20 (but less than 30) years ago...You couldn\'t walk outside without tripping over an RPG and/or COBOL job (to a lesser extent) in the IBM midrange arena. Like fishing for bluegills...You could use dandelion stems and still catch a bucket full of fish. Nowadays it seems it would be more like ice-fishing. Endless waiting in the freezing cold while watching and waiting for a flag to pop-up or a bobber to dip in the water. Good luck to those out there and trying...!!!
nandelin15
It recently struck me to see the extent to which ExtJS has become a common denominator among commercial and open-source RPG toolkits. Valence, IceCap, Atrium, RPGui, & PowerExt are based largely on ExtJS. I also recently added support within my toolkit to read JSON input and generate JSON output. That\'s not so say that ExtJS is the perfect UI - just to say that it seems to be - becoming a common denominator. Nathan.
Please login to make comments.
User Rating: / 2
PoorBest 
   MC-STORE.COM