Enhancement framework the new way to enhance your abap systems

5,284 views 49 slides Jul 24, 2014
Slide 1
Slide 1 of 49
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30
Slide 31
31
Slide 32
32
Slide 33
33
Slide 34
34
Slide 35
35
Slide 36
36
Slide 37
37
Slide 38
38
Slide 39
39
Slide 40
40
Slide 41
41
Slide 42
42
Slide 43
43
Slide 44
44
Slide 45
45
Slide 46
46
Slide 47
47
Slide 48
48
Slide 49
49

About This Presentation

No description available for this slideshow.


Slide Content

Enhancement Framework  - The new way to enhance your ABAP systems Oliver J. Mayer Product Manager – SAP NetWeaver


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 2
Learning Objectives As a result of this session, you will be able to:
EUnderstand the fundamental idea of the Enhancement 
Framework and Switch Framework (available in 
SAP NetWeaver 2004s
)
EReduce TCO by using enhancement technologies instead of 
modifications
EEnhance SAP standard objects
EUnderstand how Enhancement definitions are created

Enhancement Framework
Source Code Plugin - Technology  Function Group Enhancement - Technology Class Enhancement - Technology
Kernel-BAdI – Technology Switch Framework SummaryMotivation & Overview

Enhancement Framework
Source Code Plugin - Technology  Function Group Enhancement - Technology Class Enhancement - Technology
Kernel-BAdI – Technology Switch Framework SummaryMotivation & Overview


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 5
Availability
mySAPERP20052005
mySAP SRM
mySAP CRM
mySAP SCM
mySAP PLM
mySAP Business Suite 
20052005
SAP NetWeaver
2004s 2004s
App Server Release
… 4.6c      6.10    6.20     NW04     NW04s


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 6
SAP NetWeaver
User Productivity 
Enablement
Running an 
Enterprise Portal
Enabling User 
Collaboration
Business Task 
Management
Mobilizing 
Business 
Processes
Enterprise 
Knowledge 
Management
Enterprise Search
Data Unification
Master-Data Harmonization
Master-Data Consolidation
Central Master-Data 
Management
Enterprise Data Warehousing
Business Information 
Management
Enterprise Reporting, 
Query, and Analysis
Business Planning and 
Analytical Services
Enterprise Data 
Warehousing
Enterprise Knowledge 
Management
Enterprise Search
Business Event 
Management
Business Activity Monitoring
Business Task Management
End-to-End Process 
Integration
Enabling Application-
to-Application 
Processes
Enabling Business-to-
Business Processes
Business Process 
Management
Enabling Platform 
Interoperability
Business Task 
Management
Custom Development
Developing, Configuring, and Adapting Applications
Enabling Platform Interoperability
Unified Life-Cycle 
Management
Software Life-Cycle Management
SAP NetWeaver Operations
Application 
Governance and 
Security Management
Authentication and Single Sign-On
Integrated User and Access Management
Consolidation
Enabling Platform 
Interoperability
SAP NetWeaver 
Operations
Master-Data 
Consolidation
Enterprise Knowledge 
Management
Enterprise Data 
Warehousing
ESA Design and 
Deployment
Enabling Enterprise Services


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 7
Adapting SAP Software  One of the advantages of SAP software is the 
possibility to adapt the software to own 
requirements and the possibility of keeping 
the adaptations during upgrade.
Ways of adaptation:
ECustomizing
EEnhancement
EModification


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 8
Motivation Reducing TCO 
E
Enhancing objects instead of modifying them
reduces the effort 
for adjustment during SP import or upgrade.
Disadvantages of modifications
ENo support for 
multiple users or projects
ENo support for 
parallel developments
EWill appear much more often in adjustment tools
E
Higher
adjustment 
effort
(during upgrade & SP import)


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 9
Evolution of SAP Enhancement Technology
User 
Exits
Form
routines
Application
Workbench
Kernel
Customer 
Exits
Function
modules
Business 
Transaction 
Events
Industries
Business 
Add Ins
Filters
Classes
Kernel based 
Business 
Add Ins
Enhancement Framework

Enhancement Framework
Source Code Plugin - Technology  Function Group Enhancement - Technology Class Enhancement - Technology
Kernel-BAdI – Technology Switch Framework SummaryMotivation & Overview


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 11
[Simple] Enhancement Spot
Composite Enhancement Spot
[Simple] Enhancement Implementation
Composite Enhancement Implementation
1
n
1
n
n
1
n
1
n       m
Enhancements - Relations
Implementation Definition


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 12
Terminology by Example
Composite Enhancement Spot SAPSAPSAPSAP
Composite Enhancement Spot SD
Composite Enhancement Spot Invoice
Enhancement Spot Pricing
Enhancement Option
Source Code Enhancement FUGR V60A
Enhancement Option
BAdI Definition PRICING_BADI1
Composite Enhancement Implementation Customer Customer Customer Customer
Composite Enhancement Implementation SD
Composite Enhancement Impl. Invoice
Enhancement Impl. Pricing
Enh Impl Element
Source Code Plugin FUGR V60A
Enh Impl Element
BAdI Implementation OIL_PRICING_IMPL1


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 13
Enhancement Browser Search for
EEnhancements possibilities (Definitions –
typically provided by SAP
)
EEnhancement Implementations (
typically done by Customer
)
Integrated into Object Navigator (SE80)

Enhancement Framework
Source Code Plugin - Technology  Function Group Enhancement - Technology Class Enhancement - Technology
Kernel-BAdI – Technology Switch Framework SummaryMotivation & Overview


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 15
Source Code Enhancements Overview Modification-free enhancement of source code Implicit Enhancement Option
EAt common enhancement places, implicit Enhancement options are 
available. Examples:
n
End of Executable Program, Include, Function group,  Dialog module
n
Begin/End of Form routine / Function module / Metho d
n
End of a structure
n
End of Private/Protected/Public Section of a local  class
n
...
Explicit Enhancement Option
EPredefined enhancement options can be defined in source code. 
They are additionally stored inside Enhancement Spots. 


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 16
Implicit Enhancement Options


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 17
Explicit Enhancement Options


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 18
Source Code Plugin Technology - Example PROGRAM p1.
WRITE ‘Hello World’.
ENHANCEMENT-POINT ep1 SPOTS 
s1.
..
..
..
ENHANCEMENT-SECTION ep2 
SPOTS s1.
WRITE ’Original’.
END-ENHANCEMENT-SECTION.
ENHANCEMENT 1.
WRITE ’Hello 
Paris’.
ENDENHANCEMENT.
ENHANCEMENT 2.
WRITE ’Hello 
London’.
ENDENHANCEMENT. ENHANCEMENT 3.
WRITE ’Enhanced’.
ENDENHANCEMENT.


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 19
Editor Modes for Enhancements Use 
Change Mode
for creating enhancement points & 
sections.
Euse button           „Display <-> Change“ to switch  to change 
mode.
Use 
Enhancement Mode
for creating enhancement 
implementations.
Euse button „
Change Enhancements
“ to switch to 
Enhancement mode
Euse button „Display <-> Change“ to leave Enhancement 
mode


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 20
Demo
Demo  Source Code Plugin

Enhancement Framework
Source Code Plugin - Technology  Function Group Enhancement - Technology Class Enhancement - Technology
Kernel-BAdI – Technology Switch Framework SummaryMotivation & Overview


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 22
Function Group Enhancements
Function Group Enhancements allow:
EAdding new optional parameters to existing function modules
Transaction: SE37


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 23
Demo
Demo  Function Group Enhancement

Enhancement Framework
Source Code Plugin - Technology  Function Group Enhancement - Technology Class Enhancement - Technology
Kernel-BAdI – Technology Switch Framework SummaryMotivation & Overview


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 25
Class/Interface Enhancements Class/Interface Enhancements allow addition of:
Eoptional parameters to existing methods 
Emethods
Eevents and event handlers
Ereferences to interfaces
EExits to existing methods
n
Pre-Exit – Called at the beginning of a method
n
Post-Exit – Called at the End of a method
n
Overwrite-Exit – Replaces the original method


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 26
Adding Methods & Parameters
Adding optional parameters to existing methods Adding new methods


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 27
Pre/Post Exits
Method Hugo.
Endmethod.

Call method instance->hugo( ).

Method Pre.

….
Endmethod.
Method Post.
….
….
Endmethod.
Coding.
Coding.
Coding.


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 28
Demo
Demo  Class Enhancement

Enhancement Framework
Source Code Plugin - Technology  Function Group Enhancement - Technology Class Enhancement - Technology
Kernel-BAdI – Technology Switch Framework SummaryMotivation & Overview


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 30
BADIs - Overview What are BAdIs?
EBusiness Add-Ins
Eis an anticipated 
point of extension
– these points act like 
sockets and exist in the original coding
Ehas a 
well-defined interface
in contrast to source code plug-ins 
and is therefore more stable to changes in the original coding
Kernel BAdIs - New Features
EAre 
integrated 
directly 
in the ABAP Language
/Runtime
E
Improved filter
support allows non-character filter types 
(packed, numeric, string) and complex filter conditions
EEnable 
reusable implementation
instances (Stateful BAdI)
EControl of the lifetime of implementations (BAdI-context)
EAllow for 
inheritance
of implementations
ECan be
switched 
by the Switch Framework


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 31
Comparison: Usage of Old BAdIs vs. new BAdIs
With Classic BAdI selecting implementations and issuing calls is 
mixed up 
calls cause DB access calls are redirected over a proxy class
With New BAdI selection occurs when the handle is requested no DB access during runtime Implementations are called directly (without a proxy)
DATA: bd TYPE REF TO if_intf.
DATA: flt TYPE flt.
CALL METHOD cl_exithandler=>
get_instance
EXPORTING
exit_name = `BADI_NAME`
CHANGING
instance = bd.
flt-lang = `D`.
CALL METHOD bd->method
EXPORTING
x = 10
flt_val = flt. 
data bd type ref to badi_name. get badi
bd filters lang = `D`.
call badi
bd->method
exporting x = 10. 
Old BAdIs are more expensive 
than the new ones.
Active implementations are evaluated at compile tim e 
and included in the 
load of the BAdI-handle
.


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 32
Definition Implementation
Package A
Package B
Switch_1
Switch_2
New BADI’s and Enhancement Framework
Simple Enhancement Spot
Spot_1
Simple Enhancement Implementation SEI1 Simple Enhancement Implementation SEI2
BAdI Implementation 1 BAdI Implementation 2 BAdI Implementation 3 BAdI Implementation 4 BAdI Implementation 5
BAdI BADI_A BAdI BADI_B BAdI BADI_C


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 33
Creating BADI in SE80
BADI Definition under Enhancement Spot
BADI Implementation (Creating Filters)


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 34
Demo
Demo Kernel-BAdI


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 35
BAdI Migration (Automatic Migration)
Automatic migration by selecting utilitieshhhhmigration from BAdI 
Builder (se18)
E
Specify Enhancement Spot for BAdI Defintion
E
Specify Enhancement Implementation for BAdI Implementation
aaaano special knowledge necessary
aaaaeffort: 5 minutes per BAdI (with some implementations). The migration 
can be automated.
Automatic migration by selecting utilitieshhhhmigrate
from BAdI Builder (SE18)
■Specify Enhancement Spot for BAdI Definition
■Specify Enhancement Implementation for BAdI 
Implementation
aaaano special knowledge necessary
aaaaeffort: approximately 5 minutes per BAdI.
SE18 -> utilities -> Migrate
ONLY when you have created Custom-BADI “definitions” in old systems


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 36
Performance Comparison
Classic BAdI
Migrated BAdI New BAdI
12-27
x faster as classic BAdI
40-600
x faster as classic BAdI
The more implementations defined,  the 
higher is the improvement on performance
200%-2600% 4000%-60000%

Enhancement Framework
Source Code Plugin - Technology  Function Group Enhancement - Technology Class Enhancement - Technology
Kernel-BAdI – Technology Switch Framework SummaryMotivation & Overview


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 38
Goal of Switch Framework: Control visibility of repository objects at runtime through 
switches
The Switch Framework can be used to
ESwitch on industry solutions / Enterprise Add-ons
EDevelop new functions without affecting existing ones
EEnhance delivered systems at partner and customer site in the 
context of the enhancement framework with own functions
Switch Framework - Motivation Benefits:
EIndustry Solutions are available with every release and SP without delay (i.e. 
timely provision of legal requirements), 
CRT’s* are no longer necessary for add-on systems
EIndustry Solutions can be enriched by generic functions from other industries
ESynchronization of release cycles and planning
* CRT – Conflict Resolution Transport


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 39
Switchable Objects Switchable Objects… …by package assignment
EAppends, SI-, CI-includes for structures in DDIC
EFixed value appends to domains
ESecondary Indexes
EAppend Search Helps
EEnhancement Implementations 
ESwitch Business Configuration Sets ( Switch BC-Sets)
…by direct assignment
EScreen elements & Flow logic
EMenu entries & functions
EIMG nodes
ECustomizing


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 40
Direct Assignment: Examples
Screen Painter: Modules
Screen Painter: Field elements
Menu Painter: Function codes


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 41
Switch 
Switch
ERepository Object
ECalculated states: 
ON, OFF, STANDBY
ETransaction 
SFW1
Business Function Set
Business Function
Switch
m
n
m
n


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 42
Business Function 
Business Function
ERepresents a piece of 
business functionality
EContains switches
ETransaction 
SFW2
Business Function Set
Business Function
Switch
m
n
m
n


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 43
Business Function Set 
Business Function Set
EPool of business functions
ERepresents e.g. one industry 
solution
EMax. 1 can be active
ETransaction 
SFW3
to create 
BFS
EUse Transaction 
SFW5
to 
activate a BFS. 
Business Function Set
Business Function
Switch
m
n
m
n
SFW3SFW5


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 44
Switch Framework: Architecture
 Bus Fct Set 3
 Bus Fct F1
 Bus Fct F2
 Bus Fct F4
 Bus Fct Set 2
 Bus Fct F1
 Bus Fct F2
 Bus Fct F4
 Bus Fct Set 1
 Bus Fct F1
 Bus Fct F2
 Bus Fct F4
 
eeee
 
eeee
eeee
Switch 1
eeee
Switch 2
eeee
Switch 3 Switch 4
Screen 1 Element 1 Element 2
Package
IMG-nodes
Most objects are switched via the 
assignment of their package to a switch, 
e.g.
- DDIC objects (e.g. appends)
-Enhancements
-Transactions
-BC-Sets
Objects with no direct package relation 
are directly assigned to a switch, e.g.
-Screen elements
-Menu entries
-IMG nodes
Package

Enhancement Framework
Source Code Plugin - Technology  Function Group Enhancement - Technology Class Enhancement - Technology
Kernel-BAdI – Technology Switch Framework SummaryMotivation & Overview


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 46
Summary E
The Enhancement Framework offers new possibilities to 
extend the SAP Standard instead of modifying it. 
E
Source Code
PlugIns
E
Function Group
Enhancements
E
Class
Enhancements
E
New BAdIs
E
The new 
BAdIs are more flexible and faster
than the 
classic ones.
E
The Enhancements offered by 
Enhancement Framework
and some other object types can be 
switched by the 
Switch Framework
as part of a Business Function Set e.g. 
an industry solution. 


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 47
Further Information
aaaa
Help Portal http://help.sap.com
E
Documentation ESAP Netweaver (04s) 
E
Application Platform 
E
ABAP technology 
E
ABAP Workbench 
E
Enhancement Framework
aaaa
OKP / RKT Learning Maps Internal SAP:  
http://intranet.sap.com/rkt-netweaver
EConsulting ESAP NW 04s ECreating Business Applications using ABAP
Ramp-up customers: 
Send mail to [email protected]
aaaa
SDN http://sdn.sap.com


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 48
Q&A
Questions?


SAP AG 2006, Enhancement Framework, Oliver J. Mayer / 49
E
No part of this publication may be reproduced or tr ansmitted in any form or for any purpose without th e express permission of SAP AG. The information 
contained herein may be changed without prior notic e.
E
Some software products marketed by SAP AG and its distributors contain proprietary software components  of other software vendors.
E
Microsoft, Windows, Outlook, and PowerPoint are registered trademarks of Microsoft Corporation. 
E
IBM, DB2, DB2 Universal Database, OS/2, Parallel Sysplex, MVS/ESA, AIX, S/390, AS/400, OS/390, OS/400, iSeries, pSeries, xSeries, zSeries, z/OS, AFP, 
Intelligent Miner, WebSphere, Netfinity, Tivoli, an d Informix are trademarks or registered trademarks  of IBM Corporation.
E
Oracle is a registered trademark of Oracle Corporat ion.
E
UNIX, X/Open, OSF/1, and Motif are registered trade marks of the Open Group.
E
Citrix, ICA, Program Neighborhood, MetaFrame, WinFrame, VideoFrame, and MultiWin are trademarks or registered trademarks of Citrix Systems, Inc.
E
HTML, XML, XHTML and W3C are trademarks or registered trademarks of W3C®, World Wide Web Consortium, Massachusetts Institute of Technology. 
E
Java is a registered trademark of Sun Microsystems,  Inc.
E
JavaScript is a registered trademark of Sun Microsy stems, Inc., used under license for technology inve nted and implemented by Netscape. 
E
MaxDB is a trademark of MySQL AB, Sweden.
E
SAP, R/3, mySAP, mySAP.com, xApps, xApp, SAP NetWeaver, and other SAP products and services mentioned herein as well as their respective logos are 
trademarks or registered trademarks of SAP AG in Germany and in several other countries all over the w orld. All other product and service names mentioned  
are the trademarks of their respective companies. D ata contained in this document serves informational  purposes only. National product specifications may  vary.
E
The information in this document is proprietary to  SAP. No part of this document may be reproduced, copied, or transmitted in any form or for any purpose  
without the express prior written permission of SAP  AG.
E
This document is a preliminary version and not subj ect to your license agreement or any other agreemen t with SAP. This document contains only intended 
strategies, developments, and functionalities of th e SAP® product and is not intended to be binding upo n SAP to any particular course of business, product  
strategy, and/or development. Please note that this  document is subject to change and may be changed by SAP at any time without notice.
E
SAP assumes no responsibility for errors or omissio ns in this document. SAP does not warrant the accur acy or completeness of the information, text, graphi cs, 
links, or other items contained within this materia l. This document is provided without a warranty of  any kind, either express or implied, including but  not limited 
to the implied warranties of merchantability, fitne ss for a particular purpose, or non-infringement.
E
SAP shall have no liability for damages of any kind  including without limitation direct, special, indi rect, or consequential damages that may result from  the use of 
these materials. This limitation shall not apply in  cases of intent or gross negligence.
E
The statutory liability for personal injury and def ective products is not affected. SAP has no control  over the information that you may access through th e use of 
hot links contained in these materials and does not  endorse your use of third-party Web pages nor provi de any warranty whatsoever relating to third-party  Web 
pages.
Copyright 2006 SAP AG. All Rights Reserved
Tags