Free MuleSoft CONNECT Keynote & Expo Pass Available!

Register now+
Nav

PeopleSoft Connector

Premium

The PeopleSoft Connector is a closed source connector that uses the Component Interface (CI) to communicate in real-time with the service. This is a component provided by Oracle’s People Tools.

Prerequisites

This document assumes that you are familiar with Mule, Anypoint Connectors, Anypoint Studio, Mule concepts, elements in a Mule flow, and Global Elements.

You need login credentials to test your connection to your target resource.

To use this connector with Maven, view the pom.xml dependency information in the Dependency Snippets in Anypoint Exchange.

What’s New in this Connector

Reorganized User Interface in the Connector configuration.
The input and output of Operations is JSON.
Fixed date conversion in Save operation.

Component Interfaces (CI)

PeopleSoft’s Component Interfaces are a “one-way”, real-time interface for your PeopleSoft database instance. A component in PeopleSoft is a logical grouping of PeopleSoft pages representing a complete business transaction, such as Employee Onboarding. Component Interfaces expose the underlying APIs used by PeopleSoft Components and, therefore, ensure that validations, defaults, and business logic are preserved from the original definition of those components.

The Component Interfaces allow you to query PeopleSoft for specific records, update data, and create new instances of the records.

Attributes and Architecture

A component interface has the following four main attributes:

PeopleSoft Archtecture

  • Component Interface Name: each component interface requires a unique name. The programs calling a component use the name of the component interface to access properties and methods. 

  • Keys (Get keys, Create keys, and Find keys): keys are special properties containing values that retrieve an instance (get keys) or a list of instances (find keys) of the component interface. You can add, remove, or change keys in PeopleSoft Application Designer. Keys are created automatically when you create a component interface.

  • Get keys: map to fields marked as search keys in the Components Search record.

  • Create keys: generated in CI when the Use tab on the Component Properties dialog allows the Add action.

  • Find keys: map to fields marked as both Alternate Search keys and Search Key in the Component Search Record.

  • Properties and Collections (Fields and Records): properties provide access to both component data and component interface settings. A property can correspond to a field or a scroll (collection). A component interface collection is a special type of property that corresponds to a scroll and contains fields and subordinate scrolls as defined in its underlying component. There are two types of properties:

    • Standard properties are assigned automatically when a component interface is created. 

  • User-defined properties map to record fields on the PeopleSoft component and are displayed in the PeopleSoft Application Designer.

    • Methods: a method is a function that performs a specific task on a component interface at run time. There are two main types of methods: standard and user-defined.

      Standard methods are those that are available for all component interfaces. The following are the standard methods that the connector supports:

      Method Description

      Create

      Add a new instance of the Component Interface to the PeopleSoft database. This is similar to clicking Add and entering the relevant keys through the PeopleSoft Web UI.

      Cancel

      Cancel an instance of the Component Interface. This is equivalent of the Cancel operation in the Web UI when working on a particular component.

      Find

      Search for any instances of the component that match the provided Search Keys. This returns a list of possible matches.

      Get

      Retrieve instances that match the specific keys you provide. This returns a single record or none at all.

      Save

      Save changes made to the component, new, or existing.

      The Save operation tries to update an existing record before creating a new one. For new records, the connector automatically populates the keys with default values provided by the PeopleSoft instance, thereby reducing the need for the user to provide the default key/values pairs.

  • User-defined methods are created in PeopleSoft Application Designer to provide added functionality to the component interface.

To Connect in Design Center

  1. In Design Center, click Set Up > Upload, browse for and select the driver for this connector on your file system, and upload it. Alternatively, search for and select a driver that is already uploaded.

  2. Click a trigger.

  3. To create an HTTP global element for the connector, set these fields:

    Http Listener configuration

    1. Protocol: Protocol selected for the http endpoint, it can be http or https (secure).

    2. Host: IP address where our Mule Application will listen requests.

    3. Port: Port address where our Mule Application will listen requests.

    4. Base Path: path where our Mule Application will listen requests.

  4. Select the plus sign to add a component.

  5. Select the connector as a component.

  6. Configure these fields:

    Trigger options

    Parameter Description

    Configuration Name

    Enter a name for the configuration with which it can be referenced later.

    Application Server

    Enter the URL of the server from where to access the services. It must comply with the form of HOST:PORT. For example: my.host.com:9000.

    Username

    Enter a username to log into the PeopleSoft instance.

    Password

    Enter the corresponding password.

    Domain Connection Password

    Optional. If configured in the PeoplSoft instance, enter the domain connection password.

    Component Interface IDs

    Select the Add button to set the names of your component interfaces and click OK.

Add Libraries for this Connector

  1. Go to the connector’s Global Configuration.

  2. Click Set Up under the message to setup drivers.

  3. Upload and select your libraries.

    library upload

Connect in Anypoint Studio 7

You can use this connector in Anypoint Studio by adding it as a dependency in your Mule application.

Install Connector in Studio

  1. Open your Mule project in Anypoint Studio.

  2. Add the connector as a dependency in the pom.xml file:


          
       
1
2
3
4
5
6
<dependency>
    <groupId>org.mule.connectors</groupId>
    <artifactId>mule-peoplesoft-connector</artifactId>
    <version>3.0.0</version>
    <classifier>mule-plugin</classifier>
</dependency>

Configure in Studio

  1. Drag and drop the connector to the Studio Canvas.

  2. Create the connector configuration, configure the parameters and add the psjoa library.

  3. In the properties editor of the Invoke Operation, configure the remaining parameters:

    Parameter Value

    Display Name

    Name of the operation to display in Studio

    Extension Configuration

    The reference name to the global element you have created.

    Component Name

    The component interface name .

    Operation

    An operation to run over the selected CI.

    The connector configuration should look like the image below:

    Studio image of Configuration screen

Use Case: Studio

Retrieve a Collection of Employee Records

Find Employees Flow

  1. Create a new Mule Project in Anypoint Studio.

  2. Drag a HTTP Listener to the canvas and configure the following parameters:

    Parameter Value

    Display Name

    HTTP

    Extension Configuration

    If no HTTP element has been created yet, click the plus sign to add a new HTTP Listener Configuration, set the Host and Port, and click OK.

    Path

    /find

  3. Drag the PeopleSoft Invoke Operation next to the HTTP endpoint component and configure it according to the steps below:

    1. Add a new PeopleSoft Configuration by clicking the plus sign in the Basic Settings field.

    2. Configure the global element completing required fields with your credentials.

    3. Add the psjoa library.

    4. Add CI_PERSONAL_DATA to the Component interface IDs.

  4. Click Test Connection to confirm that Mule can connect with the PeopleSoft instance. If the connection is successful, click OK to save the configurations. Otherwise, review or correct any incorrect parameters, then test again.

  5. Back in the properties editor of the Invoke Operation, configure the remaining parameters:

    Parameter Value

    Display Name

    Find Employees

    Extension Configuration

    PeopleSoft (the reference name to the global element you have created).

    Component Name

    CI_PERSONAL_DATA (the component interface name that holds the employee data).

    Operation

    Find

    The connector settings should look like:

    DataWeave - Input

  6. Add a Transform Message (Core) element between the HTTP endpoint and the PeopleSoft endpoint to provide the input parameters required by the FIND method. The input fields should be automatically populated:

    DataWeave - Input

    Inside the Transform Message, associate fields with queryParamas. This way, each value can be dynamically set from the URL.

    
                 
              
    1
    2
    3
    4
    5
    6
    7
    8
    9
    
    %dw 2.0
    output application/json
    ---
    {
            KEYPROP_EMPLID: attributes.queryParams.id,
            PROP_NAME: attributes.queryParams.name,
            PROP_LAST_NAME_SRCH: attributes.queryParams.lastname,
            PROP_NAME_AC: attributes.queryParams.nameac
    }
  7. Add other Transform Message after the PeopleSoft element to display the response in the browser:

    
                 
              
    1
    2
    3
    4
    
    %dw 2.0
    output application/json
    ---
    payload
  8. Add a Logger scope after the JSON transformer to print the data that is being passed to the PeopleSoft connector in the Mule Console.

  9. Save and Run as Mule Application. Then, open a web browser and check the response after entering the URL http://localhost:8081/find?id=0004&name=&last_name=&name_ac=. If there are records in your PeopleSoft database whose KEYPROP_EMPLID contains the value "MULE", you should get a JSON collection with those records. Otherwise, you receive an empty collection.


          
       
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
[
    {
    "KEYPROP_EMPLID": "MULE0001",
    "PROP_NAME": "Muley",
    "PROP_LAST_NAME_SRCH": "The Mule",
    "PROP_NAME_AC": ""
    },
    {
    "KEYPROP_EMPLID": "MULE0002",
    "PROP_NAME": "Second Muley",
    "PROP_LAST_NAME_SRCH": "The Backup Mule",
    "PROP_NAME_AC": ""
    },
    ...
]

+ In this example, all input parameters for the FIND operation are optional. If none of them defined (http://localhost:8081/find?id=&name=&last_name=&name_ac=), then PeopleSoft will retrieve the first 300 records available (the maximum limited by the server).

Use Case: XML


         
      
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<?xml version="1.0" encoding="UTF-8"?>

<mule xmlns:ee="http://www.mulesoft.org/schema/mule/ee/core" xmlns:peoplesoft="http://www.mulesoft.org/schema/mule/peoplesoft"
        xmlns:http="http://www.mulesoft.org/schema/mule/http"
        xmlns="http://www.mulesoft.org/schema/mule/core"
        xmlns:doc="http://www.mulesoft.org/schema/mule/documentation" xmlns:spring="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd
http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd
http://www.mulesoft.org/schema/mule/peoplesoft http://www.mulesoft.org/schema/mule/peoplesoft/current/mule-peoplesoft.xsd
http://www.mulesoft.org/schema/mule/ee/core http://www.mulesoft.org/schema/mule/ee/core/current/mule-ee.xsd">
        <http:listener-config name="HTTP_Listener_config" doc:name="HTTP Listener config" doc:id="1fbb684d-badc-45e0-b1a2-3aad0a17596e" >
                <http:listener-connection host="0.0.0.0" port="8081" />
        </http:listener-config>
        <peoplesoft:config name="PeopleSoft_Config" doc:name="PeopleSoft Config" doc:id="d6e17fef-cad6-4c16-859c-a50c5fc06a79" >
                <peoplesoft:connection server="${config.server}" username="${config.username}" password="${config.password}" domainConnectionPassword="${config.domainPassword}" >
                        <peoplesoft:component-interface-ids >
                                <peoplesoft:component-interface-id value="CI_PERSONAL_DATA" />
                        </peoplesoft:component-interface-ids>
                </peoplesoft:connection>
        </peoplesoft:config>
        <flow name="find-employee-flow" doc:id="edfe458a-fc80-43c1-85a9-53fe57d840e1" >
                <http:listener config-ref="HTTP_Listener_config" path="/find" doc:name="Listener" doc:id="d13da911-1079-461f-bb87-180344503920" />
                <ee:transform doc:name="Transform Message" doc:id="915c5ab7-7feb-4fd1-9780-272fe37bf1d8" >
                        <ee:message >
                                <ee:set-payload ><![CDATA[%dw 2.0
output application/json
---
{
        KEYPROP_EMPLID: attributes.queryParams.id,
        PROP_NAME: attributes.queryParams.name,
        PROP_LAST_NAME_SRCH: attributes.queryParams.lastname,
        PROP_NAME_AC: attributes.queryParams.nameac
}]]></ee:set-payload>
                        </ee:message>
                </ee:transform>
                <peoplesoft:invoke-operation config-ref="PeopleSoft_Config" component="CI_PERSONAL_DATA" operation="Find" doc:name="Find Employees" doc:id="21f9f83b-5d26-45e7-9d13-47650f973394" />
                <ee:transform doc:name="Transform Message" doc:id="2664a502-6980-4349-94d2-1ffb8b01a959" >
                        <ee:message >
                                <ee:set-payload ><![CDATA[%dw 2.0
output application/json
---
payload]]></ee:set-payload>
                        </ee:message>
                </ee:transform>
                <logger level="INFO" doc:name="Logger" doc:id="28fd6c17-7af2-4dd9-a8ed-c8d0cf1991af" message="#[payload]"/>
        </flow>
        <flow name="peoplesoft_demoFlow" doc:id="59bba5f0-5e29-4a3b-b6b2-5559367171b6" >
                <http:listener config-ref="HTTP_Listener_config" path="/save" doc:name="Listener" doc:id="51aaa3a1-8117-4af2-b3cc-ff1514984598" />
                <ee:transform doc:name="Transform Message" doc:id="a065721e-54c3-429d-99d2-e46b647c5976" >
                        <ee:message >
                                <ee:set-payload ><![CDATA[%dw 2.0
output application/java
---
{
}]]></ee:set-payload>
                        </ee:message>
                </ee:transform>
                <peoplesoft:invoke-operation config-ref="PeopleSoft_Config" component="CI_PERSONAL_DATA" operation="Save" doc:name="Invoke Operation" doc:id="23e23e82-677f-44f8-9feb-a068cea31a0c" />
        </flow>
</mule>

See Also