An overview of RPG Open Access and IBM i’s Native Graphical User Interface

White Paper

This is a preliminary document and may be changed substantially prior to final commercial release of the software described herein. The information contained in this document represents the current view of Profound Logic Software on the issues discussed as of the date of publication. Because Profound Logic must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Profound Logic, and Profound Logic cannot guarantee the accuracy of any information presented after the date of publication. This White Paper is for informational purposes only. Profound Logic Software makes no warranties, express, implied, or statutory, as to the information in this document. Complying with all applicable copyright laws is the responsibility of the user. Without limiting the rights under copyright, no part of this document may be reproduced, stored in or introduced into a retrieval system, or transmitted in any form or by any means (electronic, mechanical, photocopying, recording, or otherwise), or for any purpose, without the express written permission of Profound Logic Software, Inc. Profound Logic may have patents, patent applications, trademarks, copyrights, or other intellectual property rights covering subject matter in this document. Regardless of any prior verbal or written agreement, the furnishing of this document does not give you any license to these patents, trademarks, copyrights, or other intellectual property. © 2010 Profound Logic Software, Inc. All rights reserved. Profound UI, RPGsp, RPG-Alive, RPG-Alive GUI, Genie, Atrium, the Profound UI logo are either registered trademarks or trademarks of Profound Logic Software in the United States and/or other countries. All other trademarks are property of their respective owners. INTRODUCTION ...... 3

CHARACTERISTICS OF AN IDEAL NATIVE USER INTERFACE...... 4

OVERVIEW OF RPG OPEN ACCESS...... 7

OVERVIEW OF PROFOUND UI – THE NATIVE USER INTERFACE FOR IBM I ...... 8

RPG DEVELOPMENT WITH PROFOUND UI ...... 10

VISUAL DESIGNER OVERVIEW...... 11

DEVELOPMENT TOOL CHOICES ...... 13

CHANGE MANAGEMENT CONSIDERATIONS ...... 14

PERFORMANCE...... 14

LICENSING AND I/OS VERSION SUPPORT...... 15

THE COMPANY BEHIND PROFOUND UI...... 16

SUMMARY AND HOW TO GET STARTED...... 16

2 An Overview of RPG Open Access and IBM i's Native Graphical User Interface Introduction

The IBM i has been used by hundreds of thousands of businesses and millions of users all over the world. Its integrated database design provides unique advantages for hosting a wide array of business applications. The IBM i server differentiates itself from other types of servers in terms of simplicity, stability, and low cost of operations.

The system inherently supports a number of general purpose languages, such as Java and ++, and also provides RPG, a strong specialized business language that is tightly integrated with the system’s database. This combination is ideal for delivering stable database-driven business-centric applications.

However, with all of its excellent qualities, the IBM i has often been criticized for lacking a native graphical user interface. While the system has long supported numerous ways to serve browser applications by using technologies such as CGI and J2EE, none of these methods had the integrated nature that the IBM i is known for. This meant that creating business applications with a robust graphical user interface required multiple teams of people with various technical skills. It meant a vast learning curve for RPG developers and ultimately required quite a bit of effort and a large monetary investment to get projects off the ground.

Fortunately, these days are finally behind us. Today, the IBM i server offers a very sophisticated user interface solution, which by and large surpasses other systems in terms of presentation, coherence, performance, and ease of implementation.

This white paper introduces the system’s RPG Open Access feature that makes this possible, and most importantly the new integrated Rich User Interface technology – Profound UI. It explains how the long-awaited capability to create great looking and easy to use browser applications natively from RPG and other IBM i languages has come about, and gives insight on how to best utilize this with your existing infrastructure and applications.

3 An Overview of RPG Open Access and IBM i's Native Graphical User Interface Characteristics of an Ideal Native User Interface

We all know the IBM i as a sophisticated business server that can support many users and process many transactions. But what does sophisticated server technology have to do with a client-side user interface?

At first glance, it may seem that there is little correlation. After all, the code that renders a rich user interface runs on the client (i.e. the browser), not the server. But as developers embark on building Rich UI’s for their applications, they quickly realize that linking the user interface to business data and processes on the back-end is often more intricate than designing the user interface itself. Therefore, it is critical to have a meaningful system, or framework, that connects the UI to the server.

The best UI framework is one that is native and integrates tightly with the back-end. It should not require elaborate API, multiple sets of unrelated programming languages, or complicated configuration steps. No matter how sophisticated the capabilities of a user interface solution may be, it must be easy and natural for the typical business application developer to work with.

Ideally, developers would concentrate on delivering real value by implementing business logic. They would not worry about the technical details of HTTP protocols, session persistence, cross-browser compatibility, DOM scripting, character set conversions, data encoding, or parameter escaping. Likewise, they would be able to build great looking interfaces without intricate knowledge of browser technologies, such as JavaScript, HTML, XML, AJAX, and JSON. A good framework would take care of all the technical details automatically.

To deliver this functionality, an ideal framework must have the following characteristics:

 Broad Library of User Interface Components. Modern browser interfaces today are typically built from premade widgets, or graphical user interface components. This insulates the developer from manual HTML and JavaScript coding. A good framework will include an extensive library of widgets, including grids, dialogs, charts, tab panels, menus, date pickers, spinners, and more. Preferably, these user interface components will work seamlessly with resources on the server. For the IBM i, it means taking into account certain system values, and interfacing easily with DB2 database files, message files, IFS resources, and other types of objects on the system.

 Integrated Set of Development Tools. Developers rely on tools to check source in and out, edit code, design screens, debug programs, and more. A good framework will maximize productivity by ensuring that these tools work seamlessly with each other. On the IBM i platform, this also means compatibility with any tools that may already be in place to create and maintain current applications, including IDE’s like Rational Developer for i (RDi) and legacy tools such as PDM and SEU.

4 An Overview of RPG Open Access and IBM i's Native Graphical User Interface  Extensible Platform. An extensible platform keeps the user interface framework open and gives it ultimate flexibility. It allows developers and ISV’s to customize existing widgets or create brand new widgets of their own. This ensures that developers never hit any limitations in their efforts to create functional applications.

 Inherent Statefulness. Given the stateless nature of browser communications, a system for application persistence, or statefulness, is necessary. Without such a system, the developer has to do a lot of manual work to ensure relevant data is accessible as users navigate throughout the application. For IBM i developers, an ideal system is one that allows the typical “Execute Format (ExFmt)” style of top-down business application programming. Preferably, it would support multi- level program call stacks, local data areas, subfile processing, overlays, and any other features may already be familiar with from green-screen concepts.

 Anonymous and User-based Sessions. While Internet applications are anonymous in nature, a great number of browser applications are also deployed internally. An ideal platform will provide inherent support for both anonymous and user-based sessions. On the IBM i, user-based sessions should support existing user profiles and automatically inherit all user profile authorities, as well as allow transparent access to user profile information from RPG and other languages. Preferably, the platform will also have built-in capabilities to organize applications into a standardized portal interface with single sign-on capabilities.

 Inherent Cross-Browser Support. A good UI framework must support all popular browsers, such as Internet Explorer, Firefox, Chrome, Opera, and Safari, without additional effort from developers.

 Tuned Performance. Business applications often deal with large sets of data and many simultaneous users. A lot of consideration has to go into making an application perform well. For instance, loading many thousands of records into a browser window may bring the user’s PC to a halt, unless paging or virtual rendering of records is implemented. A good user interface platform will include these options automatically, and be architected in a way that scales gracefully as additional programs and users are added.

 Informative Error Handling. When errors or problems occur, a good framework will provide useful error and recovery information for both end-users and system administrators. Handling errors gracefully, rather than displaying minimal messages like “Internal Server Error”, provides crucial feedback to help build reliable applications.

 Internationalization and Localization. User interface frameworks should inherently recognize different languages and regional differences. Good frameworks will ship with different locale options to support internationalization, and work closely with localization settings and system values stored on the server.

5 An Overview of RPG Open Access and IBM i's Native Graphical User Interface  Built-in Validation Mechanisms. Form and input validation is one of the most common tasks when building Web applications; however, a browser client, on its own, cannot not distinguish between various data types, such as character fields, decimals, and different date/time formats. In its place, a good user interface platform should enforce type-based validation by automatically applying appropriate key filters and displaying appropriate validation messages. This should happen without manual programming by application developers. There should also be easy codeless ways to specify other kinds of client-side validation, such as ranges, value lists, and comparisons, as well as a consistent method of integrating server-side backend validation with user interface components.

 Level Checking. Level or signature checking is the key to creating stable and error-free applications. It automatically detects incompatibilities between the user interface and back-end programs when user interface fields change or new fields are added. This capability is expected for IBM i, where traditionally the integrity and reliability of programs is maintained through an object-based architecture.

 Visual Point-and-Click Development. Codeless visual design tools can dramatically increase productivity over manual user interface programming. For business application development, a robust visual designer is essential. It enables developers to build applications rapidly, and allows them to promptly respond to changing user requirements as they maintain these applications.

In many operating environments, at least some of these features are available. But it’s not that common to find an environment where the user interface platform addresses all of the issues presented. Fortunately, on the IBM i, a closely integrated rich user interface platform now exists. It’s a platform that carries all of the characteristics described above.

6 An Overview of RPG Open Access and IBM i's Native Graphical User Interface Overview of RPG Open Access

RPG Open Access is a key feature that made a native graphical user interface on the IBM i possible. It was introduced by IBM in April of 2010 as a way to allow the RPG language to work with a variety of devices and interfaces. The feature is available on operating systems 6.1 and higher.

Open Access allows RPG’s input and output operations to communicate with browsers, mobile devices, or other technologies through specialized handlers. There may be different handlers for each purpose: a graphical UI, web services, accessing remote data, etc. As a result, the same RPG operations that in the past were limited to working with green-screen interfaces only, can now be extended to a rich user interface.

RPG Open Access Handlers are closely integrated with the RPG language. For example, a rich user interface can allow developers to load records into a rich grid component using RPG’s standard Write operation, treating the grid like an RPG subfile. This type of tight integration means a virtually non-existent learning curve for RPG developers. It also provides a clear path for modernizing legacy applications to a graphical user interface.

To start using a rich user interface handler, developers simply specify the Handler() keyword when defining a file or device in an RPG program. This new keyword creates a new world of possibilities for RPG – specifically, the possibility of a completely native graphical user interface. In the sections that follow, you will find more insight on how a rich graphical user interface is delivered on the IBM i with RPG Open Access.

7 An Overview of RPG Open Access and IBM i's Native Graphical User Interface Overview of Profound UI – the Native User Interface for IBM i

Profound UI is a high-performance user interface platform for the IBM i. It enables customers to rapidly create connected applications that deliver the highest quality, rich user experiences regardless of project complexity or organization size.

This is achieved by allowing developers to create native IBM i objects, known as Rich Display Files, which fully support a robust browser interface. Rich Display Files are maintained through Profound UI’s versatile visual design tool. They take advantage of IBM i's object-based architecture, well-known for its high level of system integrity and reliability, while delivering a capable graphical user interface.

Depending on the organization’s goals and future direction, there are 2 distinct paths for utilizing Profound UI:

1. Building rich user interfaces for new and existing RPG applications. Rich display files can completely replace green-screen display files with this option. RPG programs are then compiled over these new display objects, which have complete versatility in regards to the presentation layer of your applications.

2. Modernizing 5250 output with a rich user interface. This is a low effort modernization option that is most appropriate for applications where source code is not available, or development resources are tight. It allows developers to modernize output from green-screen RPG or COBOL applications on-the-fly without touching the original source code.

8 An Overview of RPG Open Access and IBM i's Native Graphical User Interface On-the-fly Modernization with Profound UI’s Genie module

The platform ships with a number of components that make these options possible. The most notable components are outlined below:

 Client-side user interface framework with over a hundred widgets (graphical controls) packaged in

 Backend server to provide statefulness, call stack support, informative error handling, subfile processing, locales, session handling, overlays, library lists, and virtually all other features that RPG programmers are already familiar with from traditional green-screen concepts

 Automated green-screen DDS to Rich UI conversion process

 Web-enablement module for on-the-fly modernization

 Full-featured Visual Designer for creating new user interfaces or enhancing 5250 output

 Web-based Framework to tie programs together

Businesses have the choice to deploy just some or all of these components to modernize and/or create their applications.

9 An Overview of RPG Open Access and IBM i's Native Graphical User Interface RPG Development with Profound UI

In the past, if an RPG was to learn about Web application development, it may have taken years to become fully proficient. But with Profound UI and its native approach, there is virtually no learning curve.

When working with Profound UI, RPG developers write programs using the same top- down approach they have always used, and any RPG operations that deal with displays are automatically understood by Profound UI and rendered in a capable rich user interface.

Profound UI provides a native RPG Open Access Handler that supports all RPG screen- related operations (ExFmt, Read, Write, Chain, ReadC, etc.) on systems running 6.1 or higher.

For prior releases (V5R3 and V5R4), this same support is provided with Profound UI’s RPG Preprocessor Module. The preprocessor supports all screen-related operations in RPG by automatically inserting direct calls to Profound UI before handing the source code to the RPG compiler, thus making the RPG Open Access functionality available on prior releases.

10 An Overview of RPG Open Access and IBM i's Native Graphical User Interface Visual Designer Overview

Profound UI ships with a very powerful visual design tool, which allows anyone (even if knowledge of JavaScript and HTML is non-existent) to create professional looking browser interfaces in a point and click manner. Using the visual designer, developers drag and drop components onto the user interface, size them, edit their content as well as appearance inline, and modify their properties visually in order to create Rich Display Files.

Profound UI Visual Designer

Similar to traditional display files, Rich Display Files are organized into separate record formats to represent different screens, window dialogs, and/or subfile grids. Each record format can contain a number of GUI widgets, or controls.

There are more than 125 types of cross-browser rich widgets already prepackaged with the designer. These include all of the most common graphical components business application developers require, including editable grids, dialogs, charts, tab panels, menus, date pickers, spinners, dropdowns, list boxes, links, buttons, and more. In addition, the platform is extensible allowing web developers and ISV’s to create their own widgets or enhance existing ones using JavaScript API.

Each widget is configurable with hundreds of properties. These encompass not only the things you would expect from a Rich Web User Interface, but also the appropriate equivalents of traditional IBM i concepts, for instance, assigning an Error Message Id

11 An Overview of RPG Open Access and IBM i's Native Graphical User Interface and a Message File to an input field on the screen, or specifying subfile size, clear, delete, and initialize properties on a grid component.

The Profound UI graphical user framework was built from the ground-up specifically for business applications on the IBM i. It is not based on generic Web frameworks like jQuery, ExtJS or Dojo. Unfortunately, generic frameworks do not fit the IBM i / RPG paradigm and are not easy to use for most RPG developers or anyone who has not had a lot of exposure to JavaScript. Instead, Profound UI provides a much more capable framework for business application development. With Profound UI, programmers no longer have to familiarize themselves with the low level complexities of Web 2.0 technologies. There is no need to be an expert in JavaScript, AJAX, or DHTML.

An important aspect of Profound UI is direct binding to program fields and database files. All widgets and their properties can be tied directly to fields in your backend programs. The concept is similar to display file fields and indicators in traditional green-screen application design. It allows RPG programs to easily populate the user interface with server data, as well as control the appearance of the interface through server-side code. In addition, widgets can be linked directly to DB2 database files on the i. For example, a customer dropdown can automatically be linked to the customer master file, or be configured as a database-driven auto complete field. The user interface platform takes care of loading the data, and there is no additional code that has to be added to your backend program.

Auto-Complete field created with no coding

12 An Overview of RPG Open Access and IBM i's Native Graphical User Interface Development Tool Choices

Profound UI brings a great deal of flexibility for choosing your set of development tools, and provides tight integration with popular tools available on the IBM i.

One of the most important aspects of Profound UI is its rich user interface designer. This visual design tool is an IBM i server hosted program, and can be accessed using any browser on any desktop platform. In addition, it integrates seamlessly with IBM’s Rational Developer for i (RDi).

For RPG code editing, Profound UI supports development through a variety of programming environments, including:

 Rational Developer for i (RDi). IBM’s eclipse-based integrated development environment for creating RPG and CL programs.

 PDM and SEU. Legacy set of programming tools on the IBM i.

 RPGsp. Profound Logic’s Rapid RPG-CGI Web Application and AJAX Development Tool.

 RPG-Alive GUI. Free RPG editor provided to all Profound UI licensed users.

The preprocessor option, required for V5R3 and V5R4 systems, is tightly integrated with the development tools mentioned above for correct compilation and compile-time error reporting. On releases 6.1 and above, with IBM’s RPG Open Access feature in place, any editing or debugging tool that supports native RPG will be fully compatible with Profound UI.

13 An Overview of RPG Open Access and IBM i's Native Graphical User Interface Change Management Considerations

Application change management is an important part of the development process for many IBM i shops. Unfortunately, whenever companies start adopting Web technologies, their procedures for saving source code, compiling programs, and promoting files can change drastically. This means the IT department will often need to invest additional funds and technical resources in order to acquire new change management tools and establish new processes. The complexity of managing Web application development alongside traditional IBM i development can be overwhelming. . But with Profound UI’s native approach, your current change management practices can be completely preserved. The way you store and compile application source does not have to change. Profound UI allows developers to save source in standard RPGLE, CL, and DDS source members, and compile user interface objects and programs using standard IBM i commands, such as CRTDSPF and CRTBNDRPG. As before, you can setup separate libraries for development, testing, and production, or reuse the libraries you have already. This provides full compatibility with any existing change management environments, including home grown systems and green-screen tools. Performance

When building Profound UI, Profound Logic Software invested a lot into optimizing performance. In general, Profound UI applications performed with speeds comparable to that of text-based green-screen interfaces, when testing displays with similar functionality. However, unlike green-screen applications, Profound UI does not utilize interactive CPW, which can be limited on some IBM i machines.

Profound UI intentionally offloads much of the processing to the browser itself, therefore distributing the load to the many end-user PC’s and putting less strain on the server. This allows applications to scale gracefully when more users are added.

As users navigate throughout the application, Profound UI uses AJAX and DHTML (dynamic HTML) to repaint application content, rather than reloading entire pages of information at every step. Furthermore, the data and screen layout information is packaged into a format that is much more compact than direct HTML output.

Profound UI also deploys virtual rendering techniques, which send to the browser only visible portions of the data on a page, rather than rendering everything at once. This provides for superb performance when utilizing data grid components with large result sets. For instance, a load-all subfile grid with 9,999 records will load and display on the screen within a sub second response time on a typical IBM i machine with 500 CPW or more, whereas with many other web frameworks, either the backend or the browser client would grind to a halt trying to load that many records at one time.

14 An Overview of RPG Open Access and IBM i's Native Graphical User Interface Once grid data is loaded, users can immediately scroll through the entire list without any delay, whereas even on a text-based green-screen interface, paging to the bottom of the list may take a fair amount of time.

Licensing and i/OS Version Support

Profound UI can be installed on i operating systems V5R3 and above, and is licensed in separate modules. Organizations may not require all modules, and certainly do not have to acquire all of the modules at one time. To use Profound UI with RPG, a license for IBM’s RPG Open Access product must also be obtained.

Fortunately, the initial license costs required to start developing applications with Profound UI and RPG Open Access are quite minimal. Actual costs will vary depending on the processor group and processor feature of your IBM i system. Organizations can receive a detailed quotation by providing their system information to Profound Logic Software.

For operating system releases where RPG Open Access is not available, Profound UI offers the RPG Preprocessor Module to provide the functionality of RPG Open Access.

15 An Overview of RPG Open Access and IBM i's Native Graphical User Interface The Company behind Profound UI

Profound UI was developed by Profound Logic Software, an advanced IBM business partner with a long history of innovation on the IBM i. The company is well known for its developer productivity and modernization tools: RPG-Alive, RPGsp, Genie, Atrium, and iData.

Profound Logic Software was the first to introduce a hybrid compiler for RPG and HTML, allowing IBM i shops to reuse existing skills and code for building Web applications. Profound Logic also launched the first Visual Debugger for RPG-based Web Development. Over the years, the team at Profound Logic developed a variety of green- screen conversion and modernization technologies, and continues to refine these technologies to this day.

At a time when AJAX development was primarily done from scratch, Profound Logic created a cross-browser AJAX library for the IBM i. The library was later extended into the first browser-based Visual Designer for web-enabling RPG applications.

This type of innovation has allowed Profound Logic to flourish and gain prominent customers such as Nintendo, Walt Disney World, Nike, Pepsi, FedEx, Volvo, Sony, General Electric, Warner Brothers, and many more. Over the past 10 years, the company has serviced thousands of customers and facilitated the modernization of many millions of lines of legacy RPG code.

Today, Profound Logic fully embraces the next era of the IBM i – an era where the user interface is native to the system. The company has worked closely with IBM to help define how RPG Open Access will be delivered, and much of the company’s &D efforts of the past 10 years have been repurposed to create a sophisticated user interface for IBM i application development.

Summary and How to Get Started

RPG Open Access and Profound UI finally deliver the long-awaited native graphical user interface IBM i users have been asking for. Today, creating rich user interfaces on the IBM i is easy and natural.

There are many resources to get you started. Log in to your Profound UI account to download a functional trial of Profound UI with a comprehensive samples library, and explore our video tutorials, live demo area, and the Profound UI community forum.

16 An Overview of RPG Open Access and IBM i's Native Graphical User Interface