Directory APIs provides many options to access, modify Directory objects. One can find many real-life use cases where manual efforts can be reduced with their use. It can be used for reporting purpose or to automate Mass Configuration Changes.
In this blog I am taking a case and its walkthrough. These 2 blogs will cover logic building and data parsing technique(JAXB) to create such a project.
In this part 1 have discussed, basic understanding of the operations used and the logic construction.
Coding part for the NWDS standalone application please refer Part 2.
To check available list of api’s goto <PI host:port>/wsnavigator . This is a snapshot of some available api for PI 7.31.
WSNavigator.png
Available operations can be checked and tested here.For e.g. below are IntegratedConfiguration & ChangeList API operations. I will be using these 2 API’s in walkthrough to create directory objects through NWDS.
ICO and Changelist API.png
Use Case: Swtich Business System for ICO
There could be real life scenarios to switch particular Business System wherever its used in a PI box. It could be used in n number of ICO’s either as Sender or as Receiver component. While switching Business Component mostly other parameters like Channel names etc remain same(we will be assuming same for this example)
To carry out such changes one only need component name. Using directory api we can automate all such object(ICO) changes.
Input:
List of Existing Business System/Service List of To Business System/Service
BC_1 BC_2
ECCCLNT100 ECCCLNT200
Based on whether component is Receiver or Sender the operations will be different.
  • Business Component is Receiver : change() operation can be used to change Receiver Component(s) in existing ICO
  • Business Component is Sender : Sender information of ICO cannot be changed ICO. In this case new ICO has to be created using create() operation.
In both the cases required list of ICO’s can be read, parsed and Component can be modified using directory api.
 
Informal description of Steps:
Manually create new Business System and Channels

For new Business System objects like Sender interface, Sender/Receiver Channel, Receiver Interface etc all names remains same
Case1: Business Component is Sender
  1. Use ICO-Query operation to check available ICO objects for a particular Business System
    Input: List of From/To Business Systems
    Output: List<MessageHeaderID>.MessageHeaderID comprises of Sender, Interface and Namespace
    ICO Query-RequestResponse.PNG
  2. Use ICO-ReadOperation to read Configuration data of above ICO query output list
    Input: List<MessageHeaderID>
    Output: IntegratedConfiguration information in JAX-WS tree.
    List<RestrictedIntegratedConfiguration>
    Parse through the Change Business System name in Inbound Processing and MessageHeader section. Create ICO objects using parsed data.
    ICO Read-RequestResponse.png
  3. Changelist-Create option to provide a Logical desription to Changelist ID (Optional)
  4. ICO-Create operation to create all ICO’s for new Sender Component.
    Input: List<RestrictedIntegratedConfiguration>
    Output: Objects created in Integration Directory.
    ICO Create-Request.png

Case 2: Business Component is Receiver

  1. Use ICO-query operation to find all available ICO’s.
  2. ICO-read to fetch all information and find where Component is Receiver.
  3. Use ICO-change operation to change appropriate Receiver information.

Output – Created ICO for new Business System

ChangeList.png

At last Manually Review and Activate objects in Changelist. This can also be automated using Changelist-Activate operation.

Coding part(standalone NWDS project) of Case1 is explained in Part 2
To report this post you need to login first.

7 Comments

You must be Logged on to comment or reply to a post.

  1. Soundarya Kavuri

    Hi Arpil,

    I am trying to retrive the objects of ICO into an excel. I am successfully able to retrive the Sendercomponent ID , sender interface and sender channel. But i am unable to retrive the Receiver component information , outbound processing details. Which is the method used to retrive the receivers?? Could you please give the method used to retrive the receiver details in ICO using NWDS.

    Thanks,

    Soundarya

    (0) 
  2. Soundarya Kavuri

    I have used

    Receivers rs= listreadOut.get(i).getReceivers();  to get the Receivers list of a particular ICO. but I was not able to retrive the Rcv component ID details. Could you please guide me as to how to retrive the Receiver components using NWDS from IntegratedConfiguration WSDL.

    Thanks,

    Soundarya

    (0) 

Leave a Reply