SAP NetWeaver 7.0 - Application Server architecture 1. Introduction The purpose of this document is to explain what components are part of the SAP NetWeaver Application Server and to explain in details how SAP NetWeaver Application Server ABAP (ABAP is for differentiating from JAVA stack) works. 2. SAP Products SAP offers a number of products for companies of all sizes: SAP Business One for small companies SAP Business ByDesign for small and midsize companies that want to use an ondemand solution SAP Business All-in-One for small and midsize companies SAP Business Suite for midsize and big companies SAP Business Suite consist of a number of modular enterprise software products that support end-to-end company processes. These software products depend on an application platform called SAP NetWeaver wich supports open standards and is interoperable with the most important technologies such as Java and.net. With Release 6.40, this platform taken the name of SAP NetWeaver Application Server, with the ability to include both the ABAP stack/database and the Java stack/database in one system. Also it is able to process HTTP requests directly from the Internet or to send them as HTTP client requests to the Internet (before this an Internet Transaction Server ITS was required). The SAP kernel was enchanced to include a process known as the Internet Communication Manager (ICM) to achieve this functionality.
3. A multitier client-server system An SAP system is a multitier client-server system. The individual software components are arranged in tiers and functions to improve performance and to provide high scalability: - Database layer: a central database system that consist of the DBMS and the database itself. The database contains the master data for ABAP application programs. It also contains the control and customizing data for the application and the SAP NetWeaver Application Server. The development objects (programs, screen definitions, menus, function modules, and so on) are all stored in a special part of the database known as the Repository. These object are therefore also referred to as Repository objects. - Application layer: consist of one or more ABAP application servers (each one are an instance of the Application Server ABAP) and a message server. Each application server contains a set of services used to run the SAP NetWeaver AS. The message server provides for communication between the application servers and the load balancing within them. Each instance has exactly one dispatcher, at least two dialog work processes, and is identified by the system ID (SID) and the instance number. - Presentation layer: is the interface between the SAP system and its users also referred to as the SAP GUI for entering and displaying data. Another option is through a web browser that also can be used in the presentation layer. The presentation layer sends the user s input to the application server and receives data for display from it. While SAP GUI component is running, it remains linked to a user s terminal session in the AS ABAP.
4. User-Oriented View From a user s perspective, the SAP system is not seen as sytems or servers, but as components that appear as a window on a screen (thanks to the presentation layer). To connect or log on to the SAP system, a user must start an SAP GUI utility called SAP Logon. The user chooses one of the available SAP system listed in SAP Logon, and the program connects to the message server of the AS ABAP in the selected SAP system. The message server obtains the address of a suitable ABAP application server. SAP Logon starts an SAP GUI connected to that application server within an user session, and then SAP Logon is then no longer required for this connection. Each window within the SAP GUI represents a session or mode. As you run applications in a session, they may call or trigger more windows (Such as dialog boxes and graphic windows). These additional windows are not independent: they belong to the session from which they were called, and can be modal (original window is not ready for input) or amodal. You can open other SAP GUIs by using SAP Logon. Each SAP GUI is totally independent from others. 5. ABAP Application Server structure The following picture shows the structure of an ABAP application server:
The number of work processes and their types are determined at the startup of the AS ABAP. Each ABAP application server contains a dispatcher, a gateway and shared memory. Work Process Work processes are components that execute an application. For a dialog work process, each executes one dialog step. Each work process is linked to a memory area that contains the context of the executing application. After the work process completes the dialog step, the link to the user and the program context is removed, which frees it for another user. There exist a number of work processes reserved for a debugger exclusive mode use. This means that the new debugger can hold one of these wp for all the duration of the debugging, to prevent database inconsistences. But this will be discussed in the next guide! Dispatcher The dispatcher provides the link between the work process and the user logged onto the application server. It receives requests from an SAP GUI or web browser and directs the request to a free work process. Once the work process completes the dialog step, the resulting screen output is returned to the appropriate user before the link is released. Gateway Its purpose is to communicate with other ABAP application servers within this system, externally with other SAP systems, or externally with non-sap systems. Local buffering of data in the shsared memory of the ABAP application server reduces the number of database reads required. Each work process has a single dedicated channel with the database layer. Therefore, a work process can only make database changes within a single database logical unit of work (LUW). 6. Structure of a Work Process Within a work process, the screen processor executes the screen flow logic (user interaction). It ensures that the field contents are transferred from the screen to the flow logic modules, and tells the ABAP processor wich module should be processed next. The processing logic of an application program is written in ABAP and the ABAP processor within the work process
executes the code and communicates with the database interface. The database interface establishes the connections between the work process and the database, and execute the database operations. There are two different ways of accessing SAP database tables: Native SQL and Open SQL using ABAP. Open SQL statements are a subset of standard SQL that is fully integrated in ABAP and allow you to access data irrespective of the database system. Open SQL consists of the Data Manipulation Language (DML) part of standard SQL. The tasks of the Data Definition Language (DDL) and Data Control Language (DCL) parts of standard SQL are performed in the AS ABAP by the ABAP Dictionary and the authorization system. 7. Types of work processes The following diagram shows again the structure of an ABAP application server, but this time, includes the various possible work process types:
Dialog Work Process Dialog work processes deal with requests from an active user to execute dialog steps. Update Work Process Update work processes execute database update requests. Update requests are part of an SAP LUW that bundle the database operations resulting from the dialog in a database LUW for processing in the background. Background Work Process Background work processes process programs that can be executed without user interaction (background jobs). Enqueue Work Process The enqueue work process administers a lock table in the shared memory area. The lock table contains the logical database locks for NetWeaver AS ABAP and is an important part of the SAP LUW concept. In NW AS, you may only have one lock table. You may therefore also only have one ABAP application server with enqueue work processes. Normally, a single enqueue work process is sufficient to perform the required tasks. Spool Work Process The spool work process passes sequential datasets to a printer or to optical archiving. Each ABAP application server may contain only one spool work process. Ing. Alessandro Iannacci SAP NW Consultant Techedge - Premium Global Player