pols - documentation · web viewextracting data from sap/r3 – programming in abap/4 7 3.2.3...
Post on 30-Mar-2020
3 Views
Preview:
TRANSCRIPT
- SAP - BAS Technical descriptionPOLS - Documentation
Revision historyVersion Date Changes Name
17.11.06 Initial draft Ajeet Phadnis30.11.06 Reviewed and adjusted Roar Nielsen
0.9 30.11.06 Formatting and restructuring – for review Thor-Chr. L’orange0.95 13.12.06 Updated after walk through together with Jan
Thorsen and Lars OftedalThor-Chr. L’orange
1.0 10.01.07 Version 1.0 Thor-Chr. L’orange
Review and approvalCompany Navn DatoUiO Lars OftedalSSØ Stein Hagen
DistributionCompany Name Action InfoSSØ Stein Hagen Review
ReferencesRef.no. Document name Description
1 POLS - SAP-BAS – Overordnet funksjonell beskrivelse og kjøremønster.doc
Word document
2 POLS - SAP-BAS - xml_schemas.doc
Word document(generated by “xml-spy”)
3 POLS Business Blueprint Document
Word Document
Date: 30.11.06 Version: 0.9 Page 2 of 15
- SAP - BAS Technical descriptionPOLS - Documentation
Table of content1. Introduction.........................................................................................................42. Integration Specifications..................................................................................5
2.1 SAP InfoTypes & Fields..................................................................................................................52.2 SAP – to – BAS information groups / data patterns........................................................................52.3 BAS – to – SAP information groups / data patterns........................................................................5
3. Integration Application Architecture & Implementation..................................63.1 Data Conversion Process...............................................................................................................63.2 Description of SAP to BAS programs.............................................................................................7
3.2.1 Purpose of the BAS to SAP interface....................................................................................73.2.2 Extracting data from SAP/R3 – programming in ABAP/4.......................................................73.2.3 Generating XML file - Java Objects.......................................................................................8
3.3 Description of BAS to SAP programs.............................................................................................83.3.1 Purpose of the BAS to SAP interface....................................................................................83.3.2 Reading XML file - Java Objects............................................................................................93.3.3 Importing data from into SAP/R3 – programming in ABAP/4.................................................93.3.4 Setup of info type 0105, Communication in SAP/R3..............................................................9
4. Infrastructure & Development..........................................................................104.1 Production Infrastructure..............................................................................................................104.2 Development Environments.........................................................................................................114.3 Deployment Environments:..........................................................................................................114.4 Scheduling.................................................................................................................................... 12
5. Testing & Acceptance......................................................................................135.1 Testing of SAP – TO - BAS...........................................................................................................135.2 Testing of BAS – TO – SAP..........................................................................................................135.3 Acceptance................................................................................................................................... 13
Appendix 1: SAP InfoTypes & Fields specifications.........................................14
Date: 30.11.06 Version: 0.9 Page 3 of 15
- SAP - BAS Technical descriptionPOLS - Documentation
POLS - DocumentationThis document contains a technical description of the interfaces between POLS (SAP) and BAS, meant for systems developers. An over all functional description with program scheduling is found in reference document 1). Detailed descriptions of the XML schemas are found in reference 2). Functional details of the relevant data groups exchanged are found in the Business Blueprint document (ref 3)).
1. Introduction
There is a two way online communication between POLS (SAP HR) modules and the BAS systems:
SAP – to - BAS1 BAS - to - SAP
The interfaces are based on generic file & jdbc adapters provided by SAP J2EE engine intrinsically.The SAP inbound & outbound interfaces are a combination of BAPIs & JDOs.In all these cases the interface messaging format is xml files. These xml files are generated and converted to receiver meta data by xml schema and xslt engines. The file adapters at SAP end will fetch these xml files for inbound processing or send them to outbound interceptors.SAP NetWeaver stack is used as integration tool set. External ERP integrations do not go directly to WAS Enterprise as recommended by SAP NetWeaver ESA architecture.
1 BAS machines are Cerebrum at UiO and Sebra at UiB
Date: 30.11.06 Version: 0.9 Page 4 of 15
- SAP - BAS Technical descriptionPOLS - Documentation
2. Integration SpecificationsThe transport communication messages are in xml formatted data patterns abstracted through xml schemas.
2.1 SAP InfoTypes & FieldsThe specifications of list of SAP InfoType - fields are as detailed in Appendix 01.
2.2 SAP – to – BAS information groups / data patternsThe information is grouped in the following XML nodes:
Person Address Person Communication Main Position Auxiliary Positions Roles
Stedkode Stednavn Stedadresse StedKomm StedBruk
Refer to full documentation in ref (2) POLS SAP – BAS UiO_Xml_Schemas.doc.
2.3 BAS – to – SAP information groups / data patternsThe information is grouped in the following XML nodes:
PersonKomm
Refer to full documentation in ref (2) POLS SAP – BAS UiO_Xml_Schemas.doc.
Date: 30.11.06 Version: 0.9 Page 5 of 15
- SAP - BAS Technical descriptionPOLS - Documentation
3. Integration Application Architecture & Implementation
The architecture is as shown in fig:
Fig: POLS – interface integration architectural view.
3.1 Data Conversion Process
1. The conversion of data retrieved from SAP through BAPI in its raw form.2. Java beans invoke BAPIs at a pre scheduled time. (Ref. Document 1 –
Grensesnitt SAP – BAS – SAP - Overordnet beskrivelse og kjøremønster)3. Java beans parse and validate the raw data from sap and submit it to an xml
dom engine, which in turn generates the xml data file.4. The Java application components are deployed on Portal J2EE engine.
Date: 30.11.06 Version: 0.9 Page 6 of 15
SAP Enterprise ABAP WorkbenchWAS / J2ee 6.40
SAP Enterprise Portal Java WorkbenchWAS / J2ee 6.40
\OPAL_CON BASXml file
File AdapterXslt generated outputRFC-JCO
- SAP - BAS Technical descriptionPOLS - Documentation
3.2 Description of SAP to BAS programs
The following figure visualizes the program structure:
3.2.1 Purpose of the BAS to SAP interface
The purpose of this interface is to move employee information (addresses, telephone numbers etc) from SAP to BAS.
3.2.2 Extracting data from SAP/R3 – programming in ABAP/4
Object Name RemarksPackage Y_UIO_INTERFACESABAP/4 program YHR_SAP2BAS_FILE_CREATE Note 1ABAP/4 program YHR_SAP2BAS_FILE_CREATE_PERS Note 2BAPI YHR_UIO_GETDATABYROWTABLE ZZXMLTABTABLE ZZXMLAPPSLOGDATA STRUCTURES YHR_INTERFACE_STRUCTTRANSACTION ZZ_CLEANTABSPROGRAMS ZZCLEANTABS
Note 1YHR_SAP2BAS_FILE_CREATE is the program that extracts data form SAP R/3. It works as follows:
1. The program first formats the results table ZZXMLTAB2. Builds lines of 250 characters in a temporary table.3. Puts these lines into ZZXMLTAB from the internal table
Both ”Persondata” and ”Stedkodedata” are handled in this process. The job has no selection picture as everything is expected to be transferred each night. Therefore it and has to be run as a background program.It is scheduled to run each night, and takes approx 1:05 hour.
Note 2YHR_SAP2BAS_FILE_CREATE_PERS is used for testrun purposes. It contains a selection screen, where “ansattnummer” and “stedcode” can be used to reduce data volume/number of records for on-line testing.
Date: 30.11.06 Version: 0.9 Page 7 of 15
- SAP - BAS Technical descriptionPOLS - Documentation
3.2.3 Generating XML file - Java Objects
Java Class Responsibility RemarksUiO_PopulateBASVals2SAP.java Read bas xml instanceUiO_PopulateSAPVals2Xml.java Read SAP Data and
create xml instanceUiO_PropertyBundle.java Read application
configuration tagsUiO_SAPIntegrationController.java Application ControllerUiO_SAPJCOPoolMgr.java SAP Connection Pool
ProxyUiOPropertyBundle.properties Application configuration
props fileUiO_FTPFiles2Opalcon.java ftp object used by both
SAP –TO-BAS & BAS-TO-SAP interfaces
UiO_SendMailOnFail.java Sends mail on application failure
Entire project uio_proj is located at: 120oslsap22\FTP\uio_projThe sap-to-bas xml file is located at: 120oslsap22\FTP\uio_dataThe xml schema, structure & configuration files are located at : 120oslsap22\FTP\uio_config.Java doc is located at: 120oslsap22\FTP\uio_proj\doc
3.3 Description of BAS to SAP programs
The following figure visualizes the program structure:
3.3.1 Purpose of the BAS to SAP interface
E-mail addresses, which are created and updated in BAS, are sent to SAP.
Date: 30.11.06 Version: 0.9 Page 8 of 15
- SAP - BAS Technical descriptionPOLS - Documentation
3.3.2 Reading XML file - Java Objects
Java Class Responsibility RemarksUiO_PopulateBASVals2SAP.java Read bas xml instanceUiO_FTPFiles2Opalcon.java ftp object used by both SAP –
TO-BAS & BAS-TO-SAP interfaces
UiO_SendMailOnFail.java Sends mail on application failuer
3.3.3 Importing data from into SAP/R3 – programming in ABAP/4
Object Name RemarksPackage Y_UIO_INTERFACESBAPI YHR_UIO_BAS2SAP Note 3
Note 3YHR_UIO_BAS2SAP is a BAPI (“Remote enabled modul) that is called to store and update data in SAP/R3. It works as follows:
1. Check if ”fødselsnummer” match ”ansattnummer”a. If not: A record is put in the error log/table
2. Read data into SAP/R3 and check1. Already existing => ignored.2. New => Create.
If not “start” and “slutt”-date exists in the input: startdato is set to today -1 day sluttdatao is set to 31/12-9999).
All letters are converted to capital lettersTelephone numbers: blanks (mellomrom) and hyphen (bindestrek) are removed.
3.3.4 Setup of info type 0105, Communication in SAP/R3
All data elements handled are set up to enable multiple instances. I.e. the interface does not delete old instances, but add on new instances.
The IMG describe in detail how infotype 0105 is set up.
Date: 30.11.06 Version: 0.9 Page 9 of 15
- SAP - BAS Technical descriptionPOLS - Documentation
4. Infrastructure & Development
4.1 Production Infrastructure The infrastructure availability for integration is as follows:
1. One dedicated production EP Server machine. 2. The machine has access to :
a. SAP R3 enterpriseb. SAP Portalsc. Opal-con
Fig: POLS – Integration infrastructure Portal URL: http://120oslsap22.common.alpharoot.net:50000/irj/portal UiO Portal machine: 120oslsap22.common.alpharoot.net
Date: 30.11.06 Version: 0.9 Page 10 of 15
Firewall 1
Prox
y Se
rver
Web Server
CLUSTER
SAP – R3
EP Server
Dis
patc
hers
Port
al –
J2EE
CLU
STE
R
INTRANET
Firewall 2
User intra-net
User web
Por
tal –
D
evel
opm
ent
wor
ksta
tion
DMZ
Port: 50000Port: (SAP R3) 3600Port: BAS
SAP-BAS XML File
SSØ
- SAP - BAS Technical descriptionPOLS - Documentation
4.2 Development Environments
SAP NetWeaver Developer Studio, SAP's new Eclipse-based development environment for Java Enterprise applications, Web Dynpro applications and Web services. Developing J2EE ApplicationsThe SAP J2EE Engine implements the Enterprise JavaBeans architecture - a technology for developing, assembling, deploying, and managing distributed component-based applications in an Enterprise environment. It also provides Enterprise applications with a uniform persistence layer for accessing data from a database.
Start SAP NetWeaver Developer Studio Open uio_proj in NWDS Modify, enhance the required object Rebuild projectTest – see section 5 Testing
4.3 Deployment Environments:
After rebuilding and testing the project, deployment is done as follows: Use export to generate and to deploy PAR-file. Use upload facility to deploy application.
To deploy applications - use upload in the portal java development.
Date: 30.11.06 Version: 0.9 Page 11 of 15
- SAP - BAS Technical descriptionPOLS - Documentation
Firewalls
Currently SSØ has opened their firewall for -> Machine (name) : Development machine fixed IP: 129.240.236.245 default gateway : 129.240.*.* subnet mask : 255.255.255.0
4.4 Scheduling
1. Logon to relevant EP ServerOpen Task Scheduler window2. Open Task Scheduler window3. Open task run_uio_proj ->schedule4. Change time as desired
EP Server task scheduler invokes run_uio_proj.cmd :5. File Location : 120oslsap22\FTP
Date: 30.11.06 Version: 0.9 Page 12 of 15
- SAP - BAS Technical descriptionPOLS - Documentation
5. Testing & AcceptanceThe test scenario and test case is as follows:
5.1 Testing of SAP – TO - BASNormal Flow Of events:
1. Logon to relevant R3 client2. Run application - YHR_SAP2BAS_FILE_CREATE.3. Logon the portal server machine and navigate to ->java development->Component
Explorer->uio_interface_start4. Verify that a xml file is generated on the server with time stamp (Takes 1:05 hours)5. Verify that the file is sent to opal_con server over ftp protocol.6. Verify that xml files are located on opal_con server at: \\159.216.221.79\opal_con\
SSØ-KRSAND\Universitetene\621\UO01\Filer\sap2bas7. Verify that xml structure & config files are located at: 120oslsap22\FTP\uio_config\ on
EP Server.
Exceptional Flow Of Events:8. Verify that a error message is e-mailed to sapbasfeil@sfso.no9. Verify for ABAP stack errors in R3 – client table : ZZ_XMLAPPSLOG10. Verify for JAVA stack errors in portal log file at : <ep_home>\
<ep_instance>\j2ee\cluster\server0\log\default_trace.trc
5.2 Testing of BAS – TO – SAP Normal Flow Of events:
1. Log on to EP Server as Java Developer/Administrator2. Go the Java Development->component explorer->UiO_Interface_Start3. Start application fetches bas2sap_data.xml file from \\159.216.221.79\opal_con\SSØ-
KRSAND\Universitetene\621\UO01\Filer\bas2sap over ftp.4. Application copies xml file at : 120oslsap22\FTP\bas2sap on EP Server5. Verify that a xml file is located on portal server at : 120oslsap22\FTP\bas2sap. 6. The file is named: bas2sap_data.xml7. Verify that the file is moved to :
\\159.216.221.79\opal_con\SSØ-KRSAND\Universitetene\621\UO01\Filer\bas2sap
Exceptional Flow Of Events:8. Verify that a error message is e-mailed to sapbasfeil@sfso.no9. Verify for ABAP stack errors in R3 – client table : ZZ_XMLAPPSLOG10. Verify for JAVA stack errors in portal log file at : <ep_home>\
<ep_instance>\j2ee\cluster\server0\log\default_trace.trc
5.3 Acceptance
Before deploying changes done on the SAP side to production, do the following: 1. Transfer test data file to a test folder on opal_con (on Cerebrum/UiO or Sebra/UiB)2. Ask Customer to verify and Accept change, before deploying to production
Date: 30.11.06 Version: 0.9 Page 13 of 15
- SAP - BAS Technical descriptionPOLS - Documentation
Appendix 1: SAP InfoTypes & Fields specifications
SAP HR SAP Felt i SAP XML-navnIT 2 Fornavn VORNA PERSON-
Etternavn NACHNMellomnavn MIDNMAnsattnummer PERNRPersonlig tittel YY_TITELFødselsnr. PERID person-
fodselsnummerFødselsdato GBDATKjønn GESCHNasjonalitet NATIOKomm.språk SPRSL
IT 6 Adressetype T591-STEXT fra (0006-ANSSA) ADRESSE-c/o NAME2Gateadresse STRASAdressetillegg LOCATPostnummer PSTLZPoststed ORT01Landkode LAND1Reservasjon COM01 RESERVASJON
IT 105 Alle deltyper T591-STEXT fra (0105-USRTY) PERSKOMM
IT 0001 - B25 HRP1000-SHORT fra P0001-PLANS HOVEDSTILLING- stillingsgruppe-betegnelse
HRP1000-STEXT fra P0001-STELL
- adm / forsk HRP1000-SHORT fra HRP1001-SOBID, OTYPE ’01’, fra P0001-STELL som HRP1001-OBJID relasjon A007
- stillingsprosent HRP1001-PROZT fra PERNR relasjon B008
- MG T501T-PTEXT fra P0001-PERSG, språk O
- professor II HRP1000-SHORT fra HRP1001-SOBID, OTYPE ’02’, fra P0001-STELL som HRP1001-OBJID relasjon A007
- dato fra - til BEGDA - ENDDA- org.enhet HRP1000-SHORT fra P0001-ORGEH
IT 0509 - flere tilsettingsforhold BISTILLING- hovedstilling vs “bistilling”
HRP1000-SHORT fra P0509-PLANS
- stillingsgruppebetegnelse- adm / forsk HRP1000-SHORT fra HRP1001-
SOBID, OTYPE ’01’, fra P0001-STELL som HRP1001-OBJID relasjon A007
Date: 30.11.06 Version: 0.9 Page 14 of 15
- SAP - BAS Technical descriptionPOLS - Documentation
- professor II HRP1000-SHORT fra HRP1001-SOBID, OTYPE ’02’, fra P0001-STELL som HRP1001-OBJID relasjon A007
- stillingsprosent P0509-EMPCT- MG T501T-PTEXT fra P0509-PERSG,
språk O- org.enhet HRP1000-SHORT fra HRP1001-
SOBID fra P0509-PLANS som hrp1001-OBJID relasjon A003
HRP1001 - Personroller HRP1001-RELAT/T777U-SUTXT ROLLER- Stedkode HRP1001-SOBID- Dato fra - til BEGDA - ENDDA
Stedobjekt Stedkode HRP1000-STEXT på alle OTYPE=05 STEDKODE
- Dato fra – til BEGDA - ENDDA- overordnet sted HRP1000-SHORT utledet fra
HRP1001-SOBID fra HRP1000-OBJID, relasjon A002
IT9176 - SAP navn - språk ZSPTXT STEDNAVN- akronym ZAKRON- kortnavn ZNAM20- kortnavn (40) ZNAMES- Langnavn (120) ZNAMEL
IT9158 - stedadresse HRP9158- CNAMESTRASSTRS2PSTLZORT01LAND1ZDISTR
STEDADRESSE
IT9153 - stedkommunikasjon HRP9153- CNAMEYPRIOZVALUE
STEDKOMM
IT9159 - stedkategori HRP9159- ZLEVELZENTER
STEDBRUK
Date: 30.11.06 Version: 0.9 Page 15 of 15
top related