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 - order.zip.


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 -
































Granted, a very simple example, but you can extrapolate from this to create batch file integrations with 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 Organization.name = '&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 -


Thursday, February 23, 2017

#553 ICS 17.1.3 --> Lifecycle management - Test 2 Production

To begin with, how do I create Dev, Test and Production environments in ICS?

Let's take a simple example of a customer who needs to integrate Sales and Service Cloud.
This is currently their only requirement in respect of ICS.

So they need 2 connections * 3 for the different environments.
Therefore all they need to do is purchase 6 connections and then create 3 instances,
each with two connections.

ICS user management can keep the users separated between the environments.

So now to a simple example of Test 2 Production.

Let's begin with the following integrations -















As a best practice, put related integrations into the same package -









This allows me to export/import the integrations as a unit.
The 2 integrations above include a REST and a RightNow adapter.

The export will include the Connections and the complete Integrations.
Once imported the connections need to be updated with the Security & Endpoint information.
Just imagine, you are moving from Test to Production - these values will be different.
However, if the connections already exist in the Production system, then they will be used.

So what are the steps?

1. Export from Test











2. Import into Production










3. Configure the Connections (if necessary)

4. Activate the Integrations


Steps 1 and 2 can also be done via the REST API.


























Export

GET /icsapis/v2/packages/{packagename}/archive
In my case,
https://myICS/icsapis/v2/packages/CreateContactPackage/archive

Test in Postman -








I then unzip the file -














Import

POST /icsapis/v2/packages/{packagename}/archive
In my case,
https://myICS/icsapis/v2/packages/CreateContactPackage/archive