FLIR Systems is the world's largest commercial company specializing in the design and production of thermal imaging cameras, components and imaging sensors. Based in Wilsonville, Oregon, United States, and founded in 1978. The company makes thermal cameras and components for a wide variety of commercial and government applications ( Ref: Wikipedia)
They use Commerce v3 as their shopping cart engine. Flir internally uses SAP as ERP & CRM application. End users buy Flir thermal cameras from Commerce v3 shopping cart application. These web orders needs to updated in to SAP system. Flir employees process the order which were available in SAP system. They will update the web order status & shipping tracking ID details in SAP system. As well as, they have to update the same information in Commerce v3 admin panel. So that, end user's can track their purchased item's shipping status in shopping cart web site.
Flir employees were doing below 2 tasks to keep both systems(SAP & Commerce v3) in sync
These are the manual tasks, So it is time consuming & error-prone. Flir spent lot of time & resources to handle these operations. They would like to automate these process & that task was assigned to MitrahSoft team.
As a feasibility study, MitrahSoft team checked "is there any web hooks available in Commerce v3?". So that we could call a web page to collect new web order details. Unfortunately there is no web hooks available in Commerce v3. Further more study on Commerce v3 platform provide us SOAP API options in Commerce v3. We have decided to use Commerce v3 SOAP API methods to update the new web orders in to SAP system in regular interval using Railo scheduled tasks.
SAP developers from Flir team wrote two simple programs. First one will watch a particular folder in SAP server, is there any new flat CSV file placed into this folder, that program will read & place a web order in to SAP system. Second program will create flat CSV file, whenever web order's shipping details were updated.
We wrote 2 schedule tasks in CFML, We used Railo as our CFML engine.
First scheduled task will call "Order Export" Commerce v3 SOAP API method & create flat CSV file for each & every web order. These files needs to be SFTPed into SAP server. As per Flir security standards, SAP server allows only SFTP connection from set of allowed IP addresses. Railo does not support sftp using CFFTP
tag. If you try to use secure attribute in CFFTP
tag, You will get "Attribute secure is not allowed for tag cfftp" error. There is a official ticket created 2 years back & it is not implemented in Railo. So we used custom tag called cfssh created by Denny Valliant.
Second schedule task will fetch flat CSV files (which will have shipping details of web orders) from SAP server & call "Order Status Update" Commerce v3 SOAP API method. This allows us to update shipping status and add tracking codes for orders in Commerce v3.
Using these 2 scheduled tasks, we have removed unwanted / redundant manual tasks to move data between SAP & Commerce v3, It saved lot of resource, reduce the data error into 0%.