AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST
-
Upload
ramesh-joshi -
Category
Documents
-
view
234 -
download
0
Transcript of AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST
![Page 1: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/1.jpg)
Three-tier Architecture Objective
To prepare AS/400 developers for Modernization projects
![Page 2: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/2.jpg)
IT 32 years AS/400 21 years
Project Management 18 years
Email [email protected]
Countries India, Belgium, Singapore, UK, US ERPs Mapics, J D Edwards, Macpac, JBA, Prism, Movex, RentalMan
Education Bachelor of Commerce, Diploma in Computer Management
Born 1957
LinkedIn profile http://www.linkedin.com/in/rameshjoshias400consultant
Ramesh Joshi
![Page 3: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/3.jpg)
![Page 4: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/4.jpg)
Overview
1. What is IBM i Application Modernization? 2. Why modernize? 3. How to modernize?
![Page 5: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/5.jpg)
What is Modernization?
![Page 6: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/6.jpg)
What is Modernization?
Modernization = Market
![Page 7: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/7.jpg)
Why should I learn about Modernization?
![Page 8: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/8.jpg)
Why should I learn about Modernization?
Market
![Page 9: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/9.jpg)
Knows about Modernization
Does not know about Modernization
![Page 10: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/10.jpg)
Modernization
![Page 11: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/11.jpg)
![Page 12: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/12.jpg)
![Page 13: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/13.jpg)
![Page 14: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/14.jpg)
![Page 15: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/15.jpg)
![Page 16: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/16.jpg)
![Page 17: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/17.jpg)
![Page 18: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/18.jpg)
![Page 19: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/19.jpg)
![Page 20: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/20.jpg)
![Page 21: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/21.jpg)
![Page 22: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/22.jpg)
How to modernize?
![Page 23: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/23.jpg)
![Page 24: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/24.jpg)
Fruit Information System
![Page 25: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/25.jpg)
![Page 26: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/26.jpg)
![Page 27: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/27.jpg)
Traditional Architecture
(AS/400 Applications)
Three-tier Architecture
(Ideal)
![Page 28: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/28.jpg)
Boy meets girl. Boy and girl both know that their parents won't let them get involved. Neither boy nor girl care, and they arrange to be married in secret. Meanwhile, the cousin of the girl gets in a fight with the boy's best friend and kills him. The boy then kills the girl's cousin in a fit of rage, and as a result is banished from the city. The girl is distraught and seeks to fake her own death so that she can escape home to be with her love. However, the boy is not told of this, and when he returns to town he believes the girl to be dead. Anguished, he poisons himself, only to discover (too late) that his love is not really dead. The girl stabs herself. There is much weeping and gnashing of teeth.
Romeo and Juliet – in 10 sentences!!!
![Page 29: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/29.jpg)
Three-tier Architecture 1. Fruit Information System 2. Traditional Architecture 3. What's wrong with that? 4. Ideal Three-tier Architecture 5. Step-1: M-V-C design 6. Step-2: Exchange Data using Sockets
![Page 30: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/30.jpg)
The Fruit Table
Rules: 1. Fruit Name should not be blank. 2. Purchase Price should be +ve. 3. Retail Price should be +ve. 4. Wholesale Price should be +ve. 5. Wholesale Price should be > Purchase Price. 6. Retail Price should be > Wholesale Price. 7. Fruit Name should be unique.
![Page 31: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/31.jpg)
Traditional Architecture
Library-X PF-SRC-Y Member-FRUITS Type-PF
Compile
![Page 32: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/32.jpg)
![Page 33: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/33.jpg)
Add Fruit
Pgm01 *PGM
2 screens
![Page 34: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/34.jpg)
Change Fruit
Pgm02 *PGM
2 screens
![Page 35: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/35.jpg)
Delete Fruit
Pgm03 *PGM
3 screens
![Page 36: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/36.jpg)
Display Fruit
Pgm04 *PGM
2 screens
![Page 37: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/37.jpg)
List Fruits
Pgm05 *PGM
1 screen (subfile)
![Page 38: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/38.jpg)
Alternatively . . .
![Page 39: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/39.jpg)
Alternatively . . .
![Page 40: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/40.jpg)
Alternatively . . .
![Page 41: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/41.jpg)
PGM01
WW Fruits *PGM
2 screens (subfile & subset)
PGM02
Maintain Fruit *PGM
Call
3 screens
Alternatively . . .
![Page 42: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/42.jpg)
PGM01
WW Fruits *PGM
2 screens (subfile & subset)
PGM02
Maintain Fruit *PGM
Call
3 screens
What's wrong with that?
![Page 43: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/43.jpg)
I want the same functionality using a browser and a mobile phone.
When can you deliver?
![Page 44: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/44.jpg)
None of these programs should access any database table.
Three-tier Architecture
![Page 45: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/45.jpg)
None of these programs should access any database table.
How to implement on IBM i?
![Page 46: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/46.jpg)
Three-tier Architecture 1. Fruit Information System 2. Traditional Architecture 3. What's wrong with that? 4. Ideal Three-tier Architecture 5. Step-1: M-V-C design 6. Step-2: Exchange Data using Sockets
![Page 47: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/47.jpg)
http://www.scottklement.com/
![Page 48: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/48.jpg)
![Page 49: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/49.jpg)
![Page 50: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/50.jpg)
![Page 51: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/51.jpg)
The Fruit Table
Rules: 1. Fruit Name should not be blank. 2. Purchase Price should be +ve. 3. Retail Price should be +ve. 4. Wholesale Price should be +ve. 5. Wholesale Price should be > Purchase Price. 6. Retail Price should be > Wholesale Price. 7. Fruit Name should be unique.
![Page 52: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/52.jpg)
![Page 53: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/53.jpg)
Work with Members Using PDM PUB1
File . . . . . . ESSRC
Library . . . . NEETARJ1 Position to . . . . .
MVC Member Type Text
M DSPFIDS PF Display File Inf. Data Structure
V ES01M MNUDDS
V ES01MQQ MNUCMD
M ES0101 CLLE Create table to store Fruit Information
M ES0102 SQLRPGLE Create table FRUITS
C ES0201 CLLE Add Fruit
C ES0202 SQLRPGLE Add Fruit-Controller
C ES0301 CLLE Change Fruit
C ES0302 SQLRPGLE Change Fruit-Controller
C ES0401 CLLE Delete Fruit
C ES0402 SQLRPGLE Delete Fruit-Controller
C ES0501 CLLE Display Fruit
C ES0502 SQLRPGLE Display Fruit-Controller
C ES0601 CLLE List Fruits
C ES0602 SQLRPGLE List Fruits-Controller
M ES9801 SQLRPGLE Fruit Procedures
ES9801BND BND
ES9801PR SQLRPGLE Fruit Procedures-Prototypes
V ES9901 SQLRPGLE Accept Fruit Name
V ES9901DS DSPF Accept Fruit Name
V ES9902 SQLRPGLE Display/Accept Fruit Information
V ES9902DS DSPF Display/Accept Fruit Information
V ES9903 RPGLE List Fruit Information
V ES9903DS DSPF Simple Subfile Program Example
Bottom
M=Model, V=View, C=Controller
![Page 54: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/54.jpg)
This is not a Production template.
![Page 55: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/55.jpg)
What is missing? 1. Message Handling 2. Pure SQL 3. Example of Header-Detail 4. Stored Procedures 5. Machine Independent Data Exchange 6. Naming Standards 7. Examples of other User Interfaces 8. Example of Result Set
![Page 56: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/56.jpg)
![Page 57: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/57.jpg)
Three-tier Architecture 1. Fruit Information System 2. Traditional Architecture 3. What's wrong with that? 4. Ideal Three-tier Architecture 5. Step-1: M-V-C design 6. Step-2: Exchange Data using Sockets
![Page 58: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/58.jpg)
Modernization Three-tier Architecture
![Page 59: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/59.jpg)
What next?
![Page 60: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/60.jpg)
What next?
You Ramesh + 2015 Batch SEs
![Page 61: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/61.jpg)
Guest blog post by John Kelly, Founding Partner of KOgent Systems, LLC. I started a new software consulting company, KOgent Systems LLC., exactly five years ago today. I was coming from a twenty year consulting career focused primarily on the IBM i. In my previous life, I had worked for two of the largest software tool vendors for the IBM i, and over the previous decade, I had managed an eCommerce solution designed to integrate into all the major ERP systems (i.e., JD Edwards and others). We had implemented 100s of eCommerce projects working within a wide variety of customer markets. The product was well-known in the industry, widely used and the services practice had been profitable under my watch. Now, I was one my own with a new staff. I had to consider which way to go, and what tools and products I would invest in for the transition to a new development platform. I chose ZEND PHP. Why?
![Page 62: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/62.jpg)
1. Platform Independence
Did I want to be free of the IBM i? No. I was raised on the box, and I’ve had too many successes on the platform to cast aspersions on the technology. But we all know all good things come to an end, and I want the freedom to run anywhere. I want the freedom of choice. Zend PHP provides this choice for me.
![Page 63: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/63.jpg)
2. Legacy Integration Let’s face it, most of the software development work that I do is integration work into pre-existing packages, and ERPs. I don’t write from scratch anymore. I extend and improve. I extend the life of the legacy applications by transforming them to run on new devices – mobile or the web. The Zend server open source PHP toolkit for the IBM i provides me with this capability. It provides direct integration for all IBM i objects – RPGILE, CL, C, data areas, etc. There is nothing I can’t touch directly – this makes me happy.
![Page 64: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/64.jpg)
3. MVC Architecture PHP scares some people because they remember the days SQL injections, and unmaintainable code. Back when PHP was a basic scripting language, it was easy to learn and easy to write code in bad form. The IBM i community has a long memory. This has long changed with the introduction of the modern PHP frameworks. The modern Zend Framework 2 architecture is a true enterprise level OO development platform. Its structure promotes highly modular design while supporting large groups of developers. This is a product built for professionals.
![Page 65: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/65.jpg)
4. Enterprise Level Support I wanted an open source product with enterprise level support. I want to be able to tell my customers that the chosen technology has a strong support backbone, which means a long life. I don’t want to be the only guy on the block running Python on the IBM i. Yeah, I’m sure it can be done, and it would be cool, I just don’t want to be the only guy doing it.
![Page 66: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/66.jpg)
5. My Gut Ok, this is the real reason. It felt good. I went with my gut like I always do. I tend to spend a lot of time researching, and analyzing something that my gut told me was the right choice from day one. Remember, this is a blog, I’m allowed to have opinions and back them up with nothing. My gut has never let me down (except for that one time with the redhead in the 8th grade). But otherwise, I tend to go with my gut.
Check back next week when I provide you with some real life examples of how listening to my gut worked out. I will explain how we used Zend PHP to integrate into the IBM i, and SAP running on Linux simultaneously to provide a new B2B site for one of the largest retail chains in the country.
![Page 67: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/67.jpg)
![Page 68: AS400 -Three-tier Architecture - 2015 09 06 - 12.53 IST](https://reader034.fdocuments.in/reader034/viewer/2022050803/58e9220d1a28ab15428b4845/html5/thumbnails/68.jpg)
Questions?