24
Wed, Apr
0 New Articles

Using Linux as a Cheap Development System

Typography
  • Smaller Small Medium Big Bigger
  • Default Helvetica Segoe Georgia Times

For many years, having the title AS/400 Software Developer implied that you worked on site with your development machine, since you had to have a terminal to program in CL, RPG, or COBOL. If your equipment was slightly more advanced, you might have had (or may still have) a blazingly fast 9,600 bits per second (bps) dial-up connection available with which you could do your programming from home. That option lost its luster after its third or fourth use because it was too darned slow. Dial-up connectivity quickly became an alternative to driving back to the office after hours to answer job halts or make quick fixes, but it was not used for serious programming.

Even the higher speeds obtainable through Internet connections do little to change the fact that, for traditional AS/400 programming, a connection to the AS/400 is required. And not just any old AS/400 will do: You need one that has the necessary development software loaded on it, such as the Application Development ToolSet/400 (for SEU, SDA, and DFU), the ILE language compilers (you are using the ILE languages, aren’t you?), and possibly SQL tools.

The ultimate solution for working away from the office may be to purchase your own personal AS/400 (PA instead of PC?) loaded with the development tools you
need—or maybe not. A more likely solution may be to reconsider your selection of programming languages and the platform upon which you develop. The people at IBM have made it quite clear in both word and deed that their vision of the AS/400’s future centers around the Java programming language. Numerous articles touting the many benefits of Java as a language have been written already, so I won’t do any (well, much) evangelizing on that topic. Instead, I’ll discuss some of the collateral advantages you’ll derive once you make the switch, not the least of which is the ability to cut the (development) cord to your AS/400 once and for all and give your personal schedule flexibility previously unattainable.

Recent Improvements

Before I get to the heart of the matter, let me review—in no particular order—some of the things that IBM has done to create the “new and improved” AS/400. First, the database has been upgraded from the nameless entity of earlier versions of OS/400 to the DB2 Universal Database (UDB) for AS/400. Along the way, the database has picked up some extremely


powerful capabilities, including the ability to handle binary large objects (BLOBs) such as audio and video data—the stuff of the Internet. You can still access the database via traditional programming languages, but now access is possible via ODBC and Java Database Connectivity (JDBC). Thus, DB2 UDB can serve data to clients running from the same AS/400, a different AS/400, or a completely different platform.

Second, IBM has made a big investment in both the Java language and the AS/400’s Java Virtual Machine (JVM). As a result, the AS/400 has become arguably one of the best Java platforms in existence. So all of the benefits of Java (which I promised not to preach) are available for your development efforts.

Last but not least, IBM recognized early on that TCP/IP was becoming the standard networking protocol, so it acted on that knowledge and added TCP/IP to the AS/400’s arsenal. Successive versions of OS/400 have included an ever-improving TCP/IP suite that is now quite complete. The IBM HTTP Server for AS/400 allows you to deliver Web pages from your AS/400, and the IBM WebSphere Application Server for AS/400 allows you to use Java servlets, JavaServer Pages (JSPs), and Enterprise JavaBeans (EJBs). Together, all of these updates and capabilities have made the AS/400 a reputable Internet server.

I realize that this information regarding AS/400 Web-enablement is old news to most people reading this article, but I mention it to make a point: IBM made these changes to keep the AS/400 viable. The AS/400 isn’t unique in its capacity as an Internet server, and it wasn’t the first one. Many other platforms are quite capable of doing the same job. As an admitted AS/400 bigot, I think you can hardly go wrong using the AS/400 as an Internet server—for production. But for development, I think there are probably better choices, if for no other reason than physical portability.

Development System Requirements

The requirements for a development system, then, are simply that it duplicates the functionality of the AS/400 and, for me (because I buy my own hardware and software), that it’s inexpensive. Because there presumably will be only one client attached to the server at one time, horsepower isn’t a major consideration. So, instead of purchasing a system loaded with the fastest processor(s), biggest small computer system interface (SCSI) hard drives, and more memory than a human has, I use a reconditioned IBM ThinkPad 770 with a whopping 128 MB of RAM; a zippy, 200 MHz Pentium MMX processor; and a 5 GB hard drive. I certainly don’t have any bragging rights with this modest (by today’s standards) laptop computer, but I am very satisfied with it.

To get a reasonable level of performance from this machine, I had to choose for it an operating system that has a reputation for making the best use of resources. If you’ve read any of my other articles, then you already know where I’m heading: Linux. As with Java, I’ll avoid evangelizing on the benefits of this operating system, except to mention the extremely low cost (free). I don’t need to evangelize, because now you can pick up almost any trade magazine (except those emanating from Redmond) and read articles in which someone else does it for me.

Once the basic Linux installation has been completed (in my case, Red Hat Version
6.0), you can concentrate on collecting the other software pieces required to duplicate the functionality of your production system. You’ll need a JVM, a database manager, the JDBC drivers for your database manager, and a Web server. Until recently, your choices for these items were somewhat limited. But as the Linux bandwagon has picked up speed, more options have become available. Surprisingly, IBM has become one of the biggest proponents of Linux and has ported its e-business tools to it. But I’ll get to IBM’s contributions.

Some Assembly Required


To start assembling the development system, you’re going to need a database manager. There are many to choose from. Most distributions of Linux include an open source (read free) database management system (DBMS): PostgreSQL. This DBMS is a good choice because it has most of the features you’d expect in a DBMS and because there is a JDBC driver available for it. Commercial support also is available for those who are interested. For further information on PostgreSQL, including info on the associated JDBC driver, visit the PostgreSQL Global Development Group’s Web site at www.postgresql.org.

If you are developing a Web site and are interested in an extremely fast and lightweight DBMS, then you’d be interested in MySQL. MySQL lacks some of the more sophisticated features you’d expect in a modern DBMS, such as transactions and commitment control, but, in the right application, their absence isn’t a problem. You can find information about MySQL at www.mysql.com; you can get information about the JDBC drivers at the MM MYSQL JDBC DRIVERS site at www.worldserver.com/mm.mysql.

Oracle was the first commercial database to be ported to Linux. There’s not much I can add to what everyone already knows about it, except that, if your company already uses it on one or more of its servers, you can’t go wrong using it on your Linux development platform. Oracle offers an entire suite of e-business software products for the platform that may be of interest. For further information, visit Oracle’s Web site at www.oracle.com.

Saving the best for last (at least in my opinion), I’ll mention IBM’s beloved DB2 UDB for Linux. If you’re planning on emulating the DB2 environment you have on your AS/400, you certainly will want to check out IBM’s offering. This DBMS has the features that you’ve come to associate with its bigger brother, so any software you write should be transplantable to the AS/400 with little or no change.

While I’m on the topics of IBM, DB2, and Linux, I’ll digress a moment and mention that WebSphere, the product you’ll need if you plan on writing any Java servlets, is available too. The combination of WebSphere and DB2 UDB for Linux on your development platform will make you feel right at home if you’re already doing development on your AS/400. At the time of this writing, IBM is offering the free Application Developer’s Kit for Linux, which includes both of these products. For further information, check out the Linux at IBM Web site at www.ibm.com/linux.

All of the databases listed here include command line interfaces, so, once you have your chosen DBMS installed, you can access it just as you would on the AS/400 if you used the the Start SQL (STRSQL) command.

Coffee, Anyone?

All of this cross-platform development would be much more difficult if it were done in any language other than Java. So, assuming that’s the language you plan on using, you’ll need to acquire a JVM and install it on your development machine. There are a few options available to you, but the most likely candidates for your machine come from Sun Microsystems and IBM.

Until recently, Sun, owner of Java, had never produced a JVM for Linux. Instead, it has delegated the job of porting its existing source to the Linux platform to the Blackdown project, a group of programmers who, as they put it, “serve as a bridge between the open source movement and commercial software vendors.” With version
1.2.2, Sun is now producing the JVM for the Intel platform. Blackdown is still producing the non-Intel and older versions of it. The home of the Blackdown project is www.blackdown.org. There, you’ll find the various versions of the JVM as well as links to various Java tools for Linux, which I’ll discuss. Sun’s Java home page is www.java.sun.com.

Once IBM caught Java fever, it produced a JVM of its own. You can find complete information on this JVM at the Java 1.1.8 for Linux Web site at


www.ibm.com/developer/linux/papers/java-118.html. This is an industrial-strength JVM with excellent performance.

In the Java version race, Blackdown is out in front, with Version 1.2.2 available for download; IBM’s latest and greatest is Version 1.1.8. But either would serve well for the type of programming you’d normally be doing away from—but for—your AS/400 server. I have both of these JVMs loaded on my laptop and switch between them as the mood strikes me.

Making It Easy

Everyone knows that real programmers use a command line for interaction with the machine and a context mode editor (such as SEU on the AS/400 or a Vi editor on a Linux/UNIX box) for editing source code. Those mortals who feel that productivity takes precedence over machismo should obtain some type of integrated development environment (IDE). There are many available. If you point your browser once again to the Blackdown site at www.blackdown.org/java-linux/products/javatools.html, you’ll see an extensive list of tools to help you along with development.

Figure 1 shows one of my favorite IDEs. It’s called AnyJ and can be found at the NetComputing home page (www.netcomputing.de). It provides all of the standard features you’d expect in an IDE for an excellent price (again, free).

Another slick IDE comes from TogetherSoft (www. togethersoft.com), which takes the concept of an IDE further. With the Together IDE, you create your Java program and Unified Modeling Language (UML) diagrams simultaneously. A change in the source window updates the UML window and vice versa. Figure 2 shows the Together IDE in action. Together is available in a free “whiteboard” edition that is useful for a single developer. It’s also available in a chargeable edition that lets you print the UML diagrams you’ve created, as well as work collaboratively with your colleagues. It is one handy tool.

IBM has ported its flagship product, VisualAge for Java (VAJ), to the Linux platform. I like the tool, but the visual method of programming does take some getting used to. VisualAge differs from some of the other products in that it keeps your code in a repository (really a glorified .zip file), but you can tell VisualAge to export the code to individual code modules. VisualAge comes in a variety of flavors—from a standard edition to an enterprise edition—each with its own capabilities. The enterprise edition is the most sophisticated and provides the ability to work with Enterprise JavaBeans (EJBs).

What a Tangled Web We Serve

To complete your development system, you’ll need a Web server. There is one clear choice: the Apache Web server (www.apache.org). Apache is currently the most widely used HTTP server on the Internet and is included with every distribution of Linux. In fact, many distributions will install it by default. IBM’s WebSphere for Linux product works with Apache, so you’ll be able to tie the two together on your development machine. Better still, you can replace the stock Apache installation with IBM’s HTTP server, which is also included in IBM’s development kit. IBM’s server is based on Apache but has some performance enhancements and extensions, such as SSL.

Close Your Windows but Open Your Doors to Free Software

Building a development platform that you can take with you makes a lot of sense. It enables you to work away from the office (that’s a good thing?) and apart from your AS/400. The openness of the AS/400 and the Internet protocols has made it possible to develop software on disparate platforms—something that’s been the Holy Grail of computing for years.

By selecting Linux as your operating system, you can take advantage of all of the open source tools available. If you take the time to examine the license on a lot of open source software, you’ll note that the products are typically free for most uses—if you’re running Linux. The license is frequently more restrictive, and chargeable, if you choose to


run the software on the “other” operating system. A case in point is the MySQL database. You are basically welcome to use the database for any purpose for yourself or your company. A registration fee is required only if you are going to make money by selling services to someone else. Of course, a registration fee is always required if you’re going to run the database on Windows. The guys from MySQL have explained this disparity in the MySQL mailing list, and their reasoning is simple: They like programming in the Linux environment; they don’t like programming for Windows. Customers asked for a Windows port, so the MySQL people provided it—for a fee.

Admission to the Linux world is cheap, and the results are rewarding. You ought to give it a try!

REFERENCES AND RELATED MATERIALS

• Blackdown Project Java Linux Web site: www.blackdown.org
• Java 1.1.8 for Linux Web site: www.ibm.com/developer/linux/papers/java-118.html
• Linux at IBM Web site: www.ibm.com/linux
• MM MYSQL JDBC DRIVERS Web site: www.worldserver.com/mm.mysql
• MySQL Web site: www.mysql.com
• NetComputing home page: www.netcomputing.de
• PostgreSQL Global Development Group Web site: www.postgresql.org
• TogetherSoft home page: www.togethersoft.com

Using_Linux_as_a_Cheap_Development_System05-00.png 397x397

Figure 1: AnyJ includes the standard features you need in an IDE, and it’s free.


Using_Linux_as_a_Cheap_Development_System06-00.png 395x395

Figure 2: The Together IDE creates Java code and UML diagrams simultaneously.


BLOG COMMENTS POWERED BY DISQUS

LATEST COMMENTS

Support MC Press Online

$0.00 Raised:
$

Book Reviews

Resource Center

  • SB Profound WC 5536 Have you been wondering about Node.js? Our free Node.js Webinar Series takes you from total beginner to creating a fully-functional IBM i Node.js business application. You can find Part 1 here. In Part 2 of our free Node.js Webinar Series, Brian May teaches you the different tooling options available for writing code, debugging, and using Git for version control. Brian will briefly discuss the different tools available, and demonstrate his preferred setup for Node development on IBM i or any platform. Attend this webinar to learn:

  • SB Profound WP 5539More than ever, there is a demand for IT to deliver innovation. Your IBM i has been an essential part of your business operations for years. However, your organization may struggle to maintain the current system and implement new projects. The thousands of customers we've worked with and surveyed state that expectations regarding the digital footprint and vision of the company are not aligned with the current IT environment.

  • SB HelpSystems ROBOT Generic IBM announced the E1080 servers using the latest Power10 processor in September 2021. The most powerful processor from IBM to date, Power10 is designed to handle the demands of doing business in today’s high-tech atmosphere, including running cloud applications, supporting big data, and managing AI workloads. But what does Power10 mean for your data center? In this recorded webinar, IBMers Dan Sundt and Dylan Boday join IBM Power Champion Tom Huntington for a discussion on why Power10 technology is the right strategic investment if you run IBM i, AIX, or Linux. In this action-packed hour, Tom will share trends from the IBM i and AIX user communities while Dan and Dylan dive into the tech specs for key hardware, including:

  • Magic MarkTRY the one package that solves all your document design and printing challenges on all your platforms. Produce bar code labels, electronic forms, ad hoc reports, and RFID tags – without programming! MarkMagic is the only document design and print solution that combines report writing, WYSIWYG label and forms design, and conditional printing in one integrated product. Make sure your data survives when catastrophe hits. Request your trial now!  Request Now.

  • SB HelpSystems ROBOT GenericForms of ransomware has been around for over 30 years, and with more and more organizations suffering attacks each year, it continues to endure. What has made ransomware such a durable threat and what is the best way to combat it? In order to prevent ransomware, organizations must first understand how it works.

  • SB HelpSystems ROBOT GenericIT security is a top priority for businesses around the world, but most IBM i pros don’t know where to begin—and most cybersecurity experts don’t know IBM i. In this session, Robin Tatam explores the business impact of lax IBM i security, the top vulnerabilities putting IBM i at risk, and the steps you can take to protect your organization. If you’re looking to avoid unexpected downtime or corrupted data, you don’t want to miss this session.

  • SB HelpSystems ROBOT GenericCan you trust all of your users all of the time? A typical end user receives 16 malicious emails each month, but only 17 percent of these phishing campaigns are reported to IT. Once an attack is underway, most organizations won’t discover the breach until six months later. A staggering amount of damage can occur in that time. Despite these risks, 93 percent of organizations are leaving their IBM i systems vulnerable to cybercrime. In this on-demand webinar, IBM i security experts Robin Tatam and Sandi Moore will reveal:

  • FORTRA Disaster protection is vital to every business. Yet, it often consists of patched together procedures that are prone to error. From automatic backups to data encryption to media management, Robot automates the routine (yet often complex) tasks of iSeries backup and recovery, saving you time and money and making the process safer and more reliable. Automate your backups with the Robot Backup and Recovery Solution. Key features include:

  • FORTRAManaging messages on your IBM i can be more than a full-time job if you have to do it manually. Messages need a response and resources must be monitored—often over multiple systems and across platforms. How can you be sure you won’t miss important system events? Automate your message center with the Robot Message Management Solution. Key features include:

  • FORTRAThe thought of printing, distributing, and storing iSeries reports manually may reduce you to tears. Paper and labor costs associated with report generation can spiral out of control. Mountains of paper threaten to swamp your files. Robot automates report bursting, distribution, bundling, and archiving, and offers secure, selective online report viewing. Manage your reports with the Robot Report Management Solution. Key features include:

  • FORTRAFor over 30 years, Robot has been a leader in systems management for IBM i. With batch job creation and scheduling at its core, the Robot Job Scheduling Solution reduces the opportunity for human error and helps you maintain service levels, automating even the biggest, most complex runbooks. Manage your job schedule with the Robot Job Scheduling Solution. Key features include:

  • LANSA Business users want new applications now. Market and regulatory pressures require faster application updates and delivery into production. Your IBM i developers may be approaching retirement, and you see no sure way to fill their positions with experienced developers. In addition, you may be caught between maintaining your existing applications and the uncertainty of moving to something new.

  • LANSAWhen it comes to creating your business applications, there are hundreds of coding platforms and programming languages to choose from. These options range from very complex traditional programming languages to Low-Code platforms where sometimes no traditional coding experience is needed. Download our whitepaper, The Power of Writing Code in a Low-Code Solution, and:

  • LANSASupply Chain is becoming increasingly complex and unpredictable. From raw materials for manufacturing to food supply chains, the journey from source to production to delivery to consumers is marred with inefficiencies, manual processes, shortages, recalls, counterfeits, and scandals. In this webinar, we discuss how:

  • The MC Resource Centers bring you the widest selection of white papers, trial software, and on-demand webcasts for you to choose from. >> Review the list of White Papers, Trial Software or On-Demand Webcast at the MC Press Resource Center. >> Add the items to yru Cart and complet he checkout process and submit

  • Profound Logic Have you been wondering about Node.js? Our free Node.js Webinar Series takes you from total beginner to creating a fully-functional IBM i Node.js business application.

  • SB Profound WC 5536Join us for this hour-long webcast that will explore:

  • Fortra IT managers hoping to find new IBM i talent are discovering that the pool of experienced RPG programmers and operators or administrators with intimate knowledge of the operating system and the applications that run on it is small. This begs the question: How will you manage the platform that supports such a big part of your business? This guide offers strategies and software suggestions to help you plan IT staffing and resources and smooth the transition after your AS/400 talent retires. Read on to learn: