Integral Code Extension Framework R18.3
Integral Code Extension Framework R18.3
Version 3.0
Dated 2017-12-07
DXC’s Integral
DXC has prepared this document in good faith. Many factors outside DXC’s current knowledge or control
affect the recipient’s needs and project plans and errors in the document will be corrected by DXC. The
responsibility lies with the recipient to evaluate the document for applicability.
The information in the document is proprietary, confidential and an unpublished work and is provided
upon recipient’s covenant to keep such information confidential. Personal data supplied in this document
may not be used for any purpose other than for which it was supplied. Personal Data may not be
transferred to other parties without the prior consent of DXC. In no event may this information be
supplied to third parties without DXC’s consent.
REVISION HISTORY
Page 2 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
TABLE OF CONTENTS
1 INTRODUCTION ................................................................................................................ 6
1.1 SCOPE.......................................................................................................................................... 7
Page 5 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
1 INTRODUCTION
As we have decided to do all the development in single code base, there is requirement on how
would customer do their own development without impacting our Integral BASE. Currently we
don’t have such ability in Integral.
Code Extension approach provides a way to customer to do their own development in customer
package. Overall, there are two aspects of code extension approach:
1. Development in customer package using Code Extension Service Package
2. Development in customer package using Code Extension Service Package and Code
Extension Points
Customer may also want to develop new batches, which requires creating new Bxxxx
programs in Integral. For new batches, customer will create new Bxxxx programs in
customer package.
For DB operation (in both online transaction and batches), customer will create
service/DAO in either Integral Base (DAO is created using DAO guideline in Integral
Base and Service over DAO will be created in Code Extension Service Package) or
Customer package itself, depending upon conditions described later in document. As
Code Extension Service Package is part of Integral BASE, project development team
from DXC will create service/DAO for customer here.
As far as existing transaction modification is concerned, customer will come to DXC first.
DXC project team will provide code extension points to customer. In this scenario,
existing Pxxxx programs will be extended in customer package using inheritance along
with other required files. In parent Pxxxx programs, we will define injection points (i.e.
default methods), where customer wants to inject code. In extended Pxxxs programs,
they will override those methods to inject customer specific code.
Similarly, when customer wants to inject their own developed functionality in Integral,
they will come to DXC first to provide proper code injection points. For example,
customer wants to call an external work flow system when there is an error in issuing a
Page 6 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
NB policy. At present, we do not have such capability, but a customer may ask for that.
So, we need to define extension points in Integral base for the same. The normal
injection code supplied in Integral base is normally a default method. Customer can
then inject their own code to such extension point to replace such default method to
carry out whatever processing customer required.
1.1 SCOPE
This document covers how customer can do development in customer package using Code
Extension Service Package and Code Extension Points.
[Link]
[Link] [Link]
CustomerAAApp CustomerAAWeb
[Link] [Link]
Other Jars
Page 7 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Page 8 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
CSCIntegralExtension Repo
IntegralAF Extension
IntegralFSUExtension
IntegralLifeExtension IntegralGroupExtension
IntegralPNCExtension
Page 9 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
This packages is divided into five packages as described in previous section. Technical
details are as follows
3.1 INTEGRALAFEXTENSION
This package contains IAF (IntegralAdminFramework) specific services.
Page 10 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
3.2 INTEGRALFSUEXTENSION
This package contains FSU specific services. It also contains AppLocator, which is talked
about in detail later.
3.2.3 AppLocator
In Integral Java, for programs to be called, their locations are to be stored in *.path files.
For example, for CSCLifeAsiaApp, there is [Link] and
[Link]. Similarly, customers will be required to have their own XXXXAppLocator
and [Link] files. AppLocator will work as an interface between customer package
and Integral.
It has one method
- locate()
Page 11 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
This method will take customer package .path file as InputStream and add customer
specific programs locations to existing list, so that customer specific programs can
be called.
3.3 INTEGRALLIFEEXTENSION
This package contains Life specific services.
3.4 INTEGRALPOLISYEXTENSION
This package contains Polisy specific services.
3.5 INTEGRALGROUPEXTENSION
This package contains Group specific services.
Page 13 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
[Link]
[Link]
As discussed previously, we will have jar and war modules for each customer. Suppose if
customer is CustomerAA, modules would be:
4.1 CUSTOMERAAAPP
This package contains:
- Pxxxx, SxxxxScreenVars, Sxxxxscreen, Sxxxxprotect, [Link] required for new screen
- Extended Pxxxx, SxxxxScreenVars, Sxxxxscreen and Sxxxxprotect; and [Link] for
modifying existing transaction.
- DAO and Service layer for customer specific database tables and existing database tables
(if customer changes structure of existing database tables)
- Customer specific xxxxAppLocator i.e. CustomerAAAppLocator.
Note: [Link] files customer should put in one folder in src/main/resources in customer
specific jar package and they should define this folder name in <SubFolders> tag at first place in
[Link]. Reason for this is, Integral finds [Link] files in folders in <SubFolders> tag
in the order in which they are defined.
Page 14 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
In our reference implementation, we have put [Link] files in customeraa folder and defined it
in <SubFolders> tag at first place in [Link]
[Link] configuration
<SubFolders>customeraa/fsu/life/iaf/diary/common</SubFolders>
CustomerAAApp snapshot
1. [Link]
This XML contains beans for framework related beans like applicator for customer i.e.
CustomerAAAppLocator. In this spring configuration, we imported integral-life-
[Link] from IntegralLifeExtension.
Page 15 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
2. [Link]
This XML contains beans for new DAOs generated for customer table. In this spring
configuration, we imported [Link].
3. [Link]
This XML contains beans for new services generated for customer tables. In this spring
configuration, we imported [Link].
Note: In reference implementation, we created different xml files for spring configuration i.e.
[Link], [Link], [Link] and used ‘import
resource’ concept to link them. This is to avoid putting all the bean definitions in single xml file.
Every Life, PNC and Group customer should import integral-life-services (from
IntegralLifeExtension), integral-polisy-services (from IntegralPolisyExtension) and integral-
group-services (from IntegralGroupExtension) respectively. In reference example, customerAA-
[Link] is first xml in hierarchy, so it imports integral-life-services.
Page 16 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
[Link] [Link]
[Link]
[Link] [Link]
[Link]
[Link] [Link]
[Link]
[Link]
[Link]
[Link]
Page 17 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
[Link]
[Link]
4.2 CUSTOMERAAWEB
It contains
- Customer developed JSP files for new and existing transactions.
- Customer specific [Link]
- Customer specific [Link]
- Customer specific resource bundles (properties files)
For customer war module, concept of war overlay is used using maven. At runtime during
maven build, Integral BASE war (CSCLifeAsiaWeb in our case) will explode into Customer war
i.e. CustomerAAWeb. This war will be deployed as final war.
Page 18 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
5 IMPORTANT GUIDELINES
So far we discussed about the structure of Code Extension Service Package and
customer package. By referring previous section 4, customer can create packages they
need. This section talks about what other things customer needs to take care of after
creating customer specific package.
Page 19 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Page 20 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Page 21 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Page 22 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
CustomerAAApp
Page 23 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
1. SmartTableService
It has two methods
- getSmartTablebyName()
This method reads a smart table based on smart table name. For example, T3642.
- getSmartTableItem()
This method read a specific item from a smart table.
2. ClientService
It has one method
- readClientData()
This method returns client details based on client number
Page 24 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
6.2 CUSTOMERAAAPP
As a part of implementation, a transaction is created – Client Employment Details. In this
transaction user can
- Create Employment Details
- Modify Employment Details
- Inquire Employment Details
DAO and Services for customer specific table CLEMPPF are created:
- DAO: [Link], [Link], [Link]
- Service: [Link], [Link]
6.3 CUSTOMERAAWEB
It contains two JSP files for Client Employment Details transaction – [Link] and
[Link].
Note: Smart table setups and user authorization is same as we currently do in Integral.
Page 25 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Page 26 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Page 27 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Page 28 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Page 29 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Kindly refer following GitHub location for see the code details:
Customer Package
[Link]
Page 30 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
7.1.1 CSCFsuApp
[Link]
[Link]
Page 31 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
7.1.2 IntegralFsuExtension
[Link]
[Link]
Page 32 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
7.1.3 CustomerAAApp
New Programs
[Link]
This program implementation could be found at following GitHub location:
[Link]
Modified Files
[Link]
Batch Definition
Attached herewith is batch definition.
IJTI-183 - Batch
[Link]
Page 33 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
For modifying existing screen, we will use Code Extension Points approach, which is part of
Code Extension framework approach.
Every screen in Integral has following files:
1. [Link]
2. [Link]
3. [Link]
4. [Link]
5. [Link]
6. [Link]
7. [Link]
8. [Link]
8.2 STEPS
For our reference implementation, we have modified Sr203 screen (Bulk Receipts). We
will explain steps using Sr203 screen as reference.
Page 34 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Old Code
Page 35 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
New Code
Page 36 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Old Code
Page 37 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
New Code
Page 38 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
First two points are straightforward; we will show code snapshots for third point.
[Link] write()
Old Code
Page 39 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
New Code
[Link] update()
Old Code
New Code
[Link] readNextChangedRecord()
Old Code
Page 40 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
New Code
[Link] chain()
Old Code
New Code
[Link] set1stScreenRow()
Old Code
New Code
Page 41 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
[Link] setNextScreenRow()
Old Code
New Code
[Link] clearFormatting()
Old Code
New Code
[Link]
New Code
[Link]
New Code
Remarks:
1. Sometimes, it could be required to get some variables from base Pxxxx in customer
extended programs. For those, we can create getters and setters in Pxxxx programs.
2. Code change showed in snapshot above is always required. Apart from this, when
customer requirement will come to modify existing transaction/screen, TA should
Page 43 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
properly define code extension points in Pxxxx programs, which will be overridden in
extended Pxxxxyyy programs in customer package to inject customer specific
implementation.
Where,
@Component: This name should be Integral BASE Pxxxx program
@Scope: it should be prototype
@Lazy: it should be lazy initialization
Page 44 of 45
Integral Code Extension Framework: DXC’s Integral
Integral Code Extension Framework Version 3.0
Page 45 of 45
Integral Code Extension Framework: DXC’s Integral