Friday, March 24, 2017

#555 ICS 17.1.3 FTP adapter and File Staging

We all know and love the ftp adapter, but what is file staging?

Here is a simple example - processing an order contained in a zip file, residing on an ftp server somewhere out there in the wide beyond.

I create an Orchestration -

I add an ftp adapter to retrieve my order which is in a zip file -

The zip is in the /In directory on my, or should I say, Angelo's,  ftp server.

Here is the ftp adapter configuration in my Orchestration -

I can delete the superfluous map activity -

resulting in ...

So what have we done here? We have downloaded the zip file to a "virtual" file system in ICS.

In the next activity, we will read the file from that location.

Stage File Action configuration -

the result -

I now invoke the ftp adapter to write the order to the /Out directory.

Configured as follows -

I do the mapping -

I check my /In directory -

I check my /Out directory -

I activate the Orchestration -

I submit via the menu -

I check the ICS monitor -

I check the ftp server /Out directory -

Granted, a very simple example, but you can extrapolate from this to create complex batch file integrations from and to Fusion HCM and ERP.

Wednesday, March 22, 2017

#554 ICS 17.1.3 --> using FOR loop

A simple example here - we will iterate thru incidents retrieved from service cloud.

Here are the incidents in Service cloud for our customer - Hare of the Dog Pub.

The For Each loop -
allows repeated steps to be performed and multiple invokes to be made within the loop.

Now to the implementation -
Here I use the Orchestration pattern in ICS.

I will use a REST interface to trigger the process.
Parameter is simple the orgName.

Then the following ROQL query to retrieve the unresolved incidents for a particular customer.

Select Incident from Incident Where = '&orgName' and StatusWithType.Status.Name = 'Unresolved'

My orchestration now looks like this -

I map as follows -

I then add the For Loop -

I call the For Each - LoopOverUnresolvedIncidents,  and drag the Incident onto the Repeating Element and name the current element name CurrentIncident.

I have created a process in PCS, that will allow a CSR to process the unresolved incidents -

I will call this from the loop -

First, I create the WSDL based SOAP connection in ICS -

I then leverage it in the orchestration -

I do the mapping, leveraging CurrentIncident -

I map the final process response -

I activate and test -