Usecase: Here, We will see the logic steps and implementation how we can call BI reports based on lookups config file stored in S3 bucket and update the OIC lookups like supplier sites,Source Legal entites, GL Source, BU Ledgers etc.
Config file is a csv file where each line contains BI report paths to fetch the look up values.
Logic steps:
From Main Integration , named : OIC_Lookups_Update_D
- Take a body scope and assign globals
- Call child integration to get the config file from AWS S3 bucket. (https://soalicious.blogspot.com/2023/11/oic-get-files-from-aws-s3-rest-service.html)
- Loop over the config files
- Decode base64 to file reference
- Read file reference
- Loop over each lookup config record
- Call BI report using SOAP adapter and pass the absolute report path name.(https://soalicious.blogspot.com/2021/05/oic-invoke-erp-bi-report.html)
- Call child integration to store the BI lookup response to S3 bucket (https://soalicious.blogspot.com/2023/12/oic-create-resuable-integration-to.html)
- Call child integration and get the files (https://soalicious.blogspot.com/2023/11/oic-get-files-from-aws-s3-rest-service.html)
- Loop over the files
- For each file, call child integration to update the OIC lookup. (https://soalicious.blogspot.com/2023/11/oic-import-replace-lookup-take-base64.html)