A blog containing development tips I have learned through the years as a PeopleSoft developer.

Friday, January 25, 2013

How to Configure and Use Integration Broker

Integration Broker has become a critical service for PeopleSoft applications. If you are new to Integration Broker or are having trouble with Integration Broker configuration, then take a look at this new Integration Broker course published by my friends at CGI consulting. The course consists of an 84 page instructional PDF and a couple of source files. The course covers everything from configuration to using SoapUI. Here are some highlights:

Setting up Integration Broker

Publishing a CI based service

Testing a web service (CI or otherwise) with SoapUI

Calling a service from PeopleCode

Application Class PeopleCode handlers

Routing transformations

JDeveloper XSLT Mapper

App Engine Service Operation handlers

And much, much more

One item I noticed that is NOT covered is creating custom listeners and targets using the Integration Broker SDK. Not to worry, though because I cover creating custom targets in my book PeopleTools Tips & Techniques.

The CGI Integration Broker course is a great read. I recommend downloading and saving a copy for future reference.

155 comments:

Jim, I am sending through the IB form data from a pdf document. It comes in OK and I can process it, but the gateway is sending a response back with a content header text/xml; charset = UTF-8 and abobe is barking at it saying it cannot process this content type. Do you know of a way I can override this to say application/pdf. When I change HEADER properties on my node it still seems to pass text/xml; charset = UTF-8.

@JCook, I have had the same frustration. I spoke with Integration Broker development about this a few years ago. In PeopleTools 8.52 REST services you will see a drop-down to select the response Content-Type, but it is limited to just the items in the list.

The work-around I have employed is to change the response header in my Apache httpd reverse proxy (everyone should use a reverse proxy). I use mod_headers to update the content-type header. You can use the Location and LocationMatch directives to match your Integration Broker URL.

If you don't have a reverse proxy, then you can write a ServletFilter and register it with your PeopleSoft web server using a URL mapping that matches your Integration Broker URL.

Subject: How to use PeopleSoft Campus Solution Delivered Web Services??

Jim, I’m new to PeopleSoft and getting multiple issues during the testing of PeopleSoft Campus Solution delivered web services (like SSR_COURSE, SSR_ENROLLEMENT …). I had tested these web services by soapUI and getting following errors: Any help in this regards would be greatly appreciated.

@Imran, did you look at errorLog.html or msgLog.html? These files exist in the PSIGW web app's directory in your weblogic (or websphere) PeopleSoft domain directory. You can configure the log level in the integrationGateway.properties file or online in the Domain advanced configuration page. This Post tells you how to change the log level.

I am testing a CI based web service using SoapUI. The CI is based on a delivered component. When I test the CI through app designer in 2-tier and 3-tier mode it is working fine. But when I expose the same CI as a web service, I get an error message (Error Saving Component Interface). I have given all the necessary permissions to the user to access the CI. Am I missing something?

@Narender, you might want to look in the app server log and also increase your IB log level and look at the msgLog.html and errorLog.html to see if there is more information regarding the error. The app server log should show why it can't save. It may have to do with data, and not security.

So I configured the IB on both the systems CS 9.0 and HR 9.1 Local gateways, Local nodes and remote nodes, we often get the boomerang issues once in a week or once in two weeks, not sure how to fix this, Currently we are doing the following to fix it, we set up a notification, text message to cell phone and an email, we'll receive if we see a bunch of messages are transferring between the systems. And then we inactivate the Service operation and cancel the message that causes the boomerang issue, and activate the service operation.

Is there any better solution that i can follow, the solution that oracle gave in the document in the Feature Pack 4, has lot of configuration has to be done, So i am looking for a better solution,

@Afjal, I am familiar with the CS/HR split, but I am not familiar with a boomerang issue. Messages coming into an Integration Gateway/Integration Broker instance are routed based on configuration. Normally, for each service operation, you will have a system of record (the publisher) and a subscriber. In the subscriber system, you will have an inbound routing. In the publisher system, you will have an outbound routing. The publisher should NOT have an inbound routing. The subscriber should NOT have an outbound routing.

It is possible to have routings that send from one node to another, with no local subscription. This is common in a hub/spoke model, but it sounds like you are using a point-to-point model. If you have any hub/spoke node to node routings, then this may be causing your problem because it sounds like you intended to configure for point to point.

It really sounds like a routing configuration issue. Make sure only have the necessary routings configured. You shouldn't have any to local or local to local routings unless specifically identified by you or the configuration documents (for example, HR uses local to local routings to subscribe to worker and personnel messages).

Each database has their own Local Gateway & Local nodes configured as per the oracle documentation, and I configured the IB for some of the service operations to go the messages both directions (As per Oracle terminology its called Subscriber Only model, We call as bidirectional), from CS to HR and HR to CS in the routing definitions., I am sure I did inactivated all the other Routing's are inactivated in the Routing Definitions. Only Routing's active are CS to HR and HR to CS.Thank You

That is what I thought. For each service operation, a node should either be a publisher or a subscriber, not both. A node can be a publisher and a subscriber, but each service operation should be one or the other. It should not be both with the same service operation and the same nodes. You can configure it this way, but it is not a best practice.

Think of it this way, which system is the system of record for the PERSON_BASIC_SYNC message? It should be HCM, right? If that is the case, then HCM will ONLY have publish (outbound) routings for the PERSON_BASIC_SYNC service operation and every other system will only have inbound/subscribing routings for that same service operation.

Another common example is USER_PROFILE. If you allow each node to maintain and publish USER_PROFILE changes, then each node will be a publisher and a subscriber. You can do this, but it is not recommended. The best practice is to make one node the system of record and have publish (outbound) routings only. All other nodes have subscription (inbound) routings only.

I have created an App package based webservice and exposed it to 3rd party. this service and its service operations utilizes rowset based messages. Request message consists of emplid whereas response message comprises of compensation and other critical data.As a part of SOAP request, authentication headers have been taken care as well. My 1st part of job is done. Now I am supposed to implement security via digital certificates or encryption on the response which is going back to 3rd party in webservice soap response. Can you help me with the steps i need to follow to implement the same? I tried going through peoplebooks but could not find a sure shot solution for the same query.

@Anuj did you see this PeopleBook entry? It is quite lengthy, so it will be a bit much to repeat here in the comments. After you start on this, if you have specific questions about any of the steps, you may want to ask the question in the PeopleSoft General Discussion OTN forum where several people can help answer your questions.

Hi Jim, I need some guidance on how to proceed with an Integration Broker - JMS Connector issue that I am facing with.I am trying to integrate Peoplesoft with a third party factory system through IBM MQs. JMS Target Connector is configured properly and I am able to send out messages succesfully. But the issue is Peoplesoft has a delivered bug wherein "Correlation ID does not match" error is occuring upon receipt of response messages. When I checked with Oracle, this seems to be a delivered bug (Bug 16012124)which has been internally fixed and to be delivered in 8.54. As we are still in Tools 8.51, we have to do our own fix on this.Issue:- For outgoing synchronous JMS messages, Peoplesoft sets Correlation ID = Transaction ID. The third party sends the same ID back as correlation ID. But PS expects the Message ID in the correlation ID and hence throws the error.PS is wrongly sending the Transaction ID in place of the Message ID which is the delivered bug.I am not able to identify the exact portion where the Correlation ID is getting set in the IB connector. Would you be able to help me with it?

As Oracle failed to provide us the solution, we thought we could modify JMSTargetConnector java file. We were able to locate the .class file at location /sandisk/appselm2/peoplesoft/elmdev03/webserv/ELMDEV03/applications/peoplesoft/PSIGW.war/WEB-INF/classes/com/peoplesoft/pt/integrationgateway/targetconnector/; we decompiled it and saved the file as JMSTargetConnector.java and saved it at the same location. We found out that the correlation id exception was occuring due to code:if (!objectMessageJMSCorrelationID.equals(msgJMSMessageID)) { throw new ExternalApplicationException("JMSTargetConnector:ExternalApplicationException. Correlation ID does not match.", new MessageCatalogEntry(10624), null); }

We modified the code to suite our requirement.

Now the question we are facing is how to compile the .java file. Whenver we try to compile we get many class not found excpetion. Please let me know if our approach is correct. If yes what steps we need to follow when modifying a devliverd java connector class as we are doing. If not what alternate solutions we may have. Need urgent help. Thanks in advance, Stefy Baby

@Stefy, for the record, I'm probably supposed to tell you not to decompile someone else's code ;). But the fact is, I've been in your position and done the exact same thing. The key difference, though, was that I renamed my source file so the generated connector had a new name. I suggest you do the same. That way your connector will still exist after the next upgrade.

Yes, you can compile target connectors. You just need to setup your compile environment to include all of the required jars and class files. This PeopleBook entry will help you prepare your environment for compilation. At the end, it also tells you how to install Target Connectors. Basically, you just copy them into the same folder as the one you found. After that, go into your gateway settings online and click the Load Connectors button. This should bring in your new connector. Once loaded, though, you have to restart your web server each time you change your target connector.

I had a doubt related with CI based webservice. Please do help me with it.

Actually I am creating a webservice using CI. I created a response message , a request message and used the handler 'Create' which was already was created by default when CI was created.But when i run it through SoapUI, it gives error "Integration Broker Sync Handler: OnRequest for message ABC could not run to completion on node QE_LOCAL. (158,974). Can you please tel me hjow to resolve.Or does it happen as Im using wrong handler. Basically what needs to be written in the handler function if i want to create my own method?Thanks in advance,Shobha

I have developing a synchronous message for integrating with third party system which runs on .NET.

I have create my request message using Part rowset & container message and for response message, I have created schema using jdeveloper.

When the external system sends a response, I am able to parse it and do internal processing. But when I send the response, the external system is receiving it as null. I have also tested my message using SoapUI. When I send a request the response comes back with proper SOAP wrapping which is well formed.

When I validate the response message, it shows an error like below

line -1: Missing message part with name [{http://xmlns.oracle.com/Enterprise/FSCM/schema/NQ_CUSTOMER_CREATE_RESP.V1}NQ_CUSTOMER_CREATE_RESP]

Hi Jim, We have a requirement to send the terminated employee id's from PS HRMS to SUN IM. For this we have decided to place the java class file in PS web server. So whenever an employee is terminated we will invoke the class file which in turn triggers workflow in SUN IM. Also we have to capture every transaction (to check whether it is success or failure) through IB. Could you please provide us some inputs on invoking the class file through IB.

@Vinusaravanan, if you create an Integration Broker custom target connector, then placing your class files on the web server makes sense. The PeopleSoft IB SDK tells you where to place the connector and how to write it. My book also has a chapter showing how to create a custom target connector.

The alternative, that might be easier, is to put the class files in your app server classpath and use GetJavaObject and CreateJavaClass in your PeopleCode request handler. You may have to create a local-to-local routing for this.

@Jim I was able to rectify the previous issue.I have one more issue with my another Synchronous web service. I have created a Rowset base request and response messages and trying to provide the Web Service to 3rd party system.While testing the service Operation I am getting an error This method can only be used by nonrowset-based messages. (2,852)]

So is there a restriction to use Row Set base messages for Synchronous type of operation? What else could be the issue.

Hi Jim,Can you provide some info on the best practice for PS IB namespace selection? It is my understanding, perhaps incorrect, that the sole purpose of the namespace is to disambiguate XML tags so that using the same tag name as someone else does not cause a collision. If this is the case, should not the namespaces in the Service Configuration component be set using the local institution's URL?Jim RowanSCU

@Jim, your understanding of XML namespaces is correct. Whether you change the namespace, or keep it the generic PeopleSoft/Oracle namespace depends on how you define ambiguous. For example, all PeopleSoft customer institutions have personal data, oprid data, depts, etc. The contents may differ, the definitions of these terms may differ, but the structure will remain the same. PeopleSoft's understanding of the data will remain the same.

The only time where I can see it being a concern is when two separate institutions share data and have an XML structure that is similar, but slightly different. For example, one is using person/name to be employee, and another is using person/name to be student and the root of the document is identical, so the context doesn't distinguish between the two.

Thank you for your wonderful posts. I am trying to process a data upload where I am trying to publish the messages through PeopleSoft over Integration Broker asynchronously in an Application Engine. The whole point is to be able to send several messages and consume them in the same node. Before I send the messages, I am storing the data on a table (say T1) to store all the field values in the upload file.

While consuming I am trying to expose each message to the Component Interface and the exceptions are logged onto the same table T1. Let's say for each transaction we are flagging the table field (say Processed_flag ='Y').

I need a mechanism where I could just wait for all the asynchronous messages to complete. I am thinking of checking the T1 table, if there are any rows on the T1 table where Processed_flag is 'N', just make the thread sleep for more time. While all the messages are not processed keep it sleeping and don't let the application engine complete.

The only benefit I can get is I don't have to wait for multiple instances at once or does not have to make the synchronous call. The whole idea is to use the component by different transactions ( as if it was used by say 100 people -> 100 transactions ).

Unless those 100 transactions are complete, we will be make sure out T1 table keeps a record of what goes on and off. If something is wrong, it can log the exceptions catched by the CI.

Any comments on this approach would be appreciated. Thanks in advance!

@Sandeep, it is common to add the Process Instance to rows processed by an App Engine. I'm not sure that sleeping will help you much. If you have a PeopleCode subscription processing the message and updating the table, that will happen in the app server, not the process scheduler, and will be in a different session. In fact, if you are writing the process instance in the App Engine, but don't commit, and then try to update the same row through IB, then the IB process will likely fail because it can't lock the row for update.

I am wondering if it would be better to publish your messages, like you intend and just let your App Engine finish. Schedule your app engine to run periodically. If it sees rows that already have a Process Instance and value of N, then those are your problem rows and you can address them.

You are right, not committing the data would result in locking on the tables.

Even if we are able to validate the data on those tables before app engine completes, the whole idea to send the messages asynchronously is of no use. In that case, using synchronous messages would be better and run the processes in parallel.

So, we decided to let the application engine complete and publish all the chunks of data through messages and make sure the messages are completely consumed in the same node.

1. We will be updating the table T1, for all the processed / successful / failed rows as we keep consuming the messages and use them as needed.

2. We will keep an audit or counter for all the rows published and consumed. Since exposing the same component to multiple transactions would be a huge performance impact. We want to make sure how it would be helpful if say 50 users are updating the same tables behind component using the same CI ( of course different instances ). I will completing mu proof of concept and hopefully it will be much better than running the processes in parallel.

Thank you for your precious time to look at my question and providing your feedback.

Hi Jim, I am trying to publish the message by populating the message through LoadXMLstring. Below is the code I have used. I am able to generate the XML string with the required fields but I am unable to execute LoadXML string (error message -Message name W_PS_TEST_MSG not in message data. The expected message name was not found in the message data at the correct location. Examine the raw XML message data in the Integration Broker Monitor.")Please note the message-W_PS_TEST_MSG exists in Service Operation-W_PS_TEST. Could you please help me to rectify this issue.

@Vinusaravanan, I noticed a few things in your code that I am wondering about:

1. Is your message an unstructured message?

2. Did you know that you can copy the XmlDoc from the SOAPDoc directly into the Message by using the SOAPDoc.XmlDoc property and the Message.SetXmlDoc methods? You don't need to convert to a string in the middle.

3. It is unusual to publish a SOAP asynchronous message. Usually SOAP is synchronous, where you send a request and expect a response. You can see an example of using SOAPDoc in this manner in PeopleBooks here.

@Sandeep, I'm a little confused. Are you expecting FT_RECEIVE to process data from FT_SEND? If so, that is not how it works. In a local to local routing, it is the same service operation. A service operation doesn't necessarily communicate direction. The routing communicates direction. So if you want to process FT_SEND locally, then you need to add the handler to FT_SEND along with a local to local routing.

You guessed it right. I was expecting FT_RECEIVE to receive those messages and process them because earlier I had tried adding the onNotify Handler to the same service operation FT_SEND instead of FT_RECEIVE and it seems like the message is stuck in New Status once published.

And as soon as I remove the handler from FT_SEND, it publishes the messages and the messages go the success on publish or resubmission.

Also, I checked when I looked at the auto generated routing for FT_RECEIVE the routing type was generated as 'Outbound Request'

@Sandeep, add a local to local routing on FT_SEND and configure your handler on FT_SEND. If the message is stuck in new status, that is different. There are actually 3 places it could be in new status: instance, publication, and subscription. Whichever queue is stuck, it shouldn't be caused by the existence of a handler on FT_SEND.

You are correct, Jim. Now, I implemented the handler on FT_SEND and it worked fine. The only thing I had to do is to cancel those messages and resubmit those and those messages flowed through the PUB/SUB and processed the business logic as needed.

They were stuck as opreation instances.

Why they got stuck in New Status, is something I have to investigate further.

Jim We are sending a request from Peoplesoft to sharepoint. We are getting a default response everytime we send a request and the 3rd party receive no data it shows as getting blank xml content value. I gotto deliver this in a day and i am still stuck with it. Please any suggestion would be highly appreciated.

Hello Jim, thanks for all the tips and techniques over the years. I have a JMS-related question that maybe only you can answer. I'm using JMS Connector to get to MQ for sending asynchronous payment messages. Do you know if JMS Connector sends back a transaction id if connection property JMSAcknowledgement is set to Auto.Acknowledgement? My goal is to get a confirmation that the target JMS connector has received this message. Thanks a lot!!LH

Can you please help me capture a fault string exception. I am working on FSCM 9.1 and tools 8.52 Integration broker . I am sending a request through the webservices to a third party service. If everything is OK with the XML, it returns the response message. But when something wrong with the XML, it is giving me HTTP 500 error. Where as the same request when i send through the SOAPUI I am getting fault string which gives me an indication of where my XML request is wrong. I want to be able to capture that fault string and display in error/log files which I am unable to do when I invoke the service from peoplesoft. Did anyone come across this kind of situation before, Please help me with the sample code. The request I am generating is by using XML doc classes.

@Mohd, I think your question is a great question. I just don't know the answer. My experience is mostly with PeopleSoft as a provider, not as a consumer. This is why I think you may want to ask your question of the post's author on the author's blog.

I work on tools V 8.52 doing an integration with Fusion Middleware wherein i subscribe async messages. i am able to recieve the messages but the messages are going in error state with the error message: "Error occured while parsing the XML. XML is empty or not an XML." i have set the authentication type as null. please help me find a solution

hi Jim,we are trying to test a synchronous inbound message in development environment using both send master and handler.Handler tester will return confirmation 0 and do not hit synchronous services in monitor. where as send master hit synchronous services in error below.SOAP-ENV:ServernullIntegration Broker Response20968

I'm working on CRM 8.48. i am consuming a web service from a third party system. i was facing issues while generating a request XML so i have generated an XML by concatenating various strings via peoplecode. this XML is exactly identical to the request XML in SOAP UI. I now need to pass that very XML as my request XML during consumption. could you help me out with the coding aspect of that? cuz i feel the one i generated is probably not being considered as an XML- its being taken as a string

We are trying to send a request to a 3rd party (non-peoplesoft system). The 3rd party requires us to digitally sign the request with a certificate, which we are able to do. However, PeopleSoft automatically appends a Username Token to the request, which causes the 3rd party to not accept the request. We tried setting the "Exclude PSFT Auth Token" option for our service operation, but since the request is going to a non-peoplesoft system, the token is included anyway. Do you know of a way to exclude the token? Oracle has confirmed that our settings are correct, but because the 3rd party is a non-peoplesoft system, the token is included, but we are wondering if there is a way to exclude it.

Yes, our sending node is configured as an external node. Oracle has said that the UsernameToken is always included in the request if the request is sent to a non-PeopleSoft system, even if the "Exclude PSFT Auth Token" option is selected for that operation.

To clarify, we are on PT 8.53 and this is being sent from ELM 9.2. The specific xml node we are trying to remove is below.

Hello Jim,I am using IB Sync to transmit an XML file that's already formatted. Part of the XML file was created in UNIX using PERL and carriage returns are replaced with in the script. This is then appended to the rest of the message created using XMLDOC in peoplecode. But when I use SetXMLDoc and call a Sync message, IB (as expected) tries to format the XML and escapes the & in "" to &#xd; - which invalidates the message now. So 1)how to make the IB not to replace the & in or 2) how to generate the as its not being done automatically for Carriage return as of now..

I noticed in my earlier message my ampersands were taken out by the site. so let me try to use the literal ampersand for "&".

so basically I would like to know if IB can leave a XML which has a valid escape value "ampersand#xd;" for carriage return as is and not to escape the "ampersand" in that value to "ameprsandamp;#xd;" or can we have IB generate that escape value "ampersand#xd;" for carriage return. Also The receiver will not accept tags for this node as we are sending a signature in that node. (we are generating the signature using PERL script in UNIX and passing it in the XML message)

I have one question , how to notify / get notification as soon as some IB message struck in error. Because we are facing some issues like we are unable to come to know the failures in html email approvals?

@Viswanathareddy, there is a delivered notification process that you can schedule, but that isn't immediate. Alternatively, you can create an App Engine daemon process to check the IB tables for messages in error status.

Jim, love your book (PPT&T). We have a web service that times out on synchronous on large messages due to the component processing being large (BI_ENTRY). Upping the timeout is not an option according to our Admins. If we switch to asynchronous and deliver the keys in a separate process, would we still have timeout issues on the DoSave() not finishing in time? In other words, is the 50 second CI processing timeout applicable to sync *and* async messages?

@Jeff, the large amount of data pushed through a CI within a web service will cause you problems. The apps FullSync messages have a similar problem. The way they handle it is to insert the received data into a staging table and then use the ProcessRequest API to schedule an App Engine to process the received data. The web service can then return a result before the App Engine finishes (and maybe even before it starts).

@Jim. Thanks for the info. Does that web service CI limitation issue apply to Asynch messages as well? We don't mind if it takes longer as long as it runs. The staging table via web service is they way I am definitely leaning (even before your reply) but I have to answer the asynch option question that was posed to me. Thanks!

@Jeff, I am not sure. Usually a timeout is on the sender's side, not the side doing the processing. The timeout is just a resource management technique. It frees up resources on the sender's side if the receiver hangs onto a connection indefinitely.

I know I can use encryption profile PS_CREDIT_CARD_Decrypt to decrypt a field that is encrypted using PS_CREDIT_CARD_encryp on an other PeopleSoft system like HR and sent to finance through ib(I tried it and it worked). can we use the same decrypt function to decrypt a base64 encrypted value from third party?

@Vinjas, as you probably know, Base64 is not encryption, but encoding. What this means is there are no public or private keys. Anyone can encode or decode someone else's base64 data. There are a good dozen ways to encode and decode base64 with PeopleCode. You can find examples in these posts on my blog.

We are working on Customers CI interface through Asyn messaging. We are receiving the Customer data as a message from third party system. We have the subscription app package written on handler class. The App package calls a CI to validate the data. But the problem here is when Insert fails due to CI validation we are unable to know that it failed to load a customer and the service operation monitor still shows the status as DONE.. Any suggestions to handle this scenario??

@Mohd, there are 3 IB queues. The subscription queue should show an error if the CI fails. I have seen CI errors in the IB queue many times. The instance queue will show as DONE, but the subscription queue should say ERROR.

I am trying to send messages from Peoplesoft 8.52 to weblogic JMS Queues, the messages are in new status. Created JMS Server/Connection Factory/JMS Queue on weblogic server. Created an external node in Peoplesoft with Connector ID as JMSTARGET and used the JMS queue. Ping node is working and the ping messages are visible in JMS Queue. Created a Peoplesoft non-rowset based message and Service operation(Asynchronous one way) and provided a routing from local node to the external node. I tried to publish messages to the service operation from peoplecode, the meesages are all in new status. Please provide your inputs to resolve this issue.

We are receiving messages from a third party through JMS queue. We wanted to capture the transaction ID of the inbound message that we get through the OnNotify handler peopleCode.I used the IB class property &msg.transactionid but that generates some new Id which does not match with the transaction ID I see in the Asynchronous monitor for that message. Could you please help me understand if there is Any different way to Capture the transaction ID for the Aynchronous inbound message I get from the third party?

@Mohd, when I look at an async service in the service operation monitor, I notice that each instance has at least 2 transaction IDs: The initial instance transaction ID and one transaction ID for each publication or subscription contract. Did you check the transaction ID against the appropriate queue to see if the ID matches one of the other queues?

As you said there are a couple Transaction IDS. One being initial and other being the Subscription Transaction ID. The one that &msg.Transactionid fetching me is the Subscription. Thanks I dint realize that its atleast matching the Subscription ID, but is there a way to Capture the initial Trasaction Id? because if we want to search for ab Ib transaction we would do it using the Initial ID right? because if i search using the Subscription Transaction Id it does not find the transaction. Any hint from your end regarding this would be a lot help me to me. Thanks you again.

Hi JimI am working on a requirement where a custom request-id property has to be set on the response header in a REST synchronous transaction. While I am able to do this over the response message when all is good using the below code snippet, i am unable to do the same on the fault message.&resMessage.IBInfo.IBConnectorInfo.AddConnectorProperties("Request-id", &requestid, %HttpHeader);When onError method is invoked by IB, it just returns a string and we dont have a hold of the response object to set any property on it. Can you please share any possible way to do this?Thanks in advance.Vivek

Hope you are doing great. We are getting the xml messages to our jms queue. However, under some circumstances qhen there is a an issue with the structure of the xml the subscription contract goes to error. Is there a way to fire a custom peoplecode if a subscription contract is in error ??

@Mohd, there is delivered app engine program which notifies you of any messages in error. You need to have a permission list assigned to get this notification. It will also place them in your worklist to view the error messages.

Hope you are doing well. I have a question around IB message delivery. I am publishing an XML message using the %INTBROKER.Publish(&msg) function. and Once the message is sent I am required to delete some data from PeopleSoft tables. The Service operation is Async One way. So my question is , is there a way to make sure that the target system received my message before I delete any data from PeopleSoft. Does changing the Service operation type to Async request response will help? If yes do I need to tell to third party to send some response or it happens automatically?? Please advise.

@Mohd, there are a couple of things to think about here. Yes, having the recipient send an async response that identifies the batch that was sent will definitely give you assurance that the recipient received the data. Another is to convert to synchronous. The final thought is non repudiation.

1) Peoplesoft publish data to TIBCO . Then TIBCO provides data to 3rd party application. (Outbound)2) 3rd party publishes data to TIBCo, then TIBCO in turn publishes data to Peoplesoft.(Inbound).3)Can we sent/Publish Document from Peoplesoft to Sharepoint.

Hi Jim, I am trying to configure IB for client authentication using certificates. I can establish connection with secured Third Party Vendor using SSL at the transport layer, but they require a second layer client authentication certificate. I am trying to attach a certificate to a SOAP message request. I have tried non-repudiation from the default local node, but that does not seem to be working. I have also tried importing a private key into PeopleSoft for the local node.

I was wonder if you have tried anything like this. I have a signed private & public key from a trusted CA stored in a ".pfx" file , PKCS#12 archive. I wish to import this private/public key combination into PeopleSoft and attach to a soap message to be used in client authentication with a third party vendor.

Hi Jim, thanks for the blog. We having been using SOAP messaging to non-PS systems for years but we are now asked to call 3rd party web services using REST. On the SOAP messages we are able to easily capture the attribute values from the response. With REST, we have it setup as a message using a document (not a rowset and unstructured) so we call a GET as shown below. We can see the response xml fine but how do we get the attribute values from the xml elements since I can't use xml class methods? I'm not sure if there is something obvious I'm missing or if I need to possibly do a transform. Thanks and hope it makes sense...

@John, in my opinion, the documents module is somewhat limiting. If you know the structure of the response document, I would be tempted to specify the integration point as a non-rowset, no document message (possibly unstructured?) and then use XPath with the XmlDocument PeopleCode object to identify the important pieces.

Hi Jim,I am facing a very strange issue. I am trying to expose my peoplesoft functionality through Integration Broker. My code is working fine when tested through handler tester. But when I am trying to consume the generated WSDl through SoapUI, the request message is not appearing in it while the response message is appearing in the input window and the output window( where response message appears) is blank. I have thoroughly checked my service operation. The response and request message appears fine. Even the services that were already working are also showing same behavior when using SoapUI. I am not quite sure where the problem lies. Is it with SoapUi or the Configuration setup at gateway level. Any solution?

Hi Jim,I am trying to expose my logic through Web Service. The web service is responding fine when tested with Handler Tester. But when I am trying to test it with SoapUI, one of the tags is showing 'False'. This tag basically handles the error message that pops up during online testing. I have captured this message in a string and it prints perfectly with Handler tester but why not SoapUI. Also the data is not being pushed to DB even when the case is right. What is the difference between testing through SoapUI and Handler tester except that SoapUI being a 3rd party.

How can we implement Security while sending data (secure data) to 3rd party.I know using Web Services Security. But can you help me to implement in a simple way, with less complexity and min customization involved.

Hi JimWe have a requirement to integrate our PeopleSoft Application with 3rd Party 3rd party provides Http Post urlI chose to use http target connectors with in PeopleSoftConfigured Services,Service Operations,Messages,Nodes,Routing (Outbound)I was able to call their Post Method and interact with their application

Problem:3rd Party Application expects Authorization Header to be send across along with XML Message

@Ravi, that is a great question. There are plenty of options including using Async messaging, but I'm sure you have a reason for using sync. I suggest you ask this question on the PeopleSoft General Discussion OTN forum where you can get answers from a lot more people than just me.

I'm implementing a new service operation in a existing service. I'm testing it through soapUI. when I'm testing with a already existing response message, I'm output message with needed details. But, I want to test it with a new response message which I created. When I'm testing with new message, no tags are added to output message. I'm seeing only the header message and no child nodes are added in output message. Please suggest how to fix this issue.

Hi Jim,Can we have multiple Listening Connectors (e.g. HTTP listening connector,JMS listening connector,AS2 listening connector etc) configured for the same Gateway as in the Gateway Set up page I am able to see that I will be able to load multiple Target Connectors (using "Load Gateway Connectors") but in the URL I will be able to add only one Listening Connectors.

@Arnab, you can have as many connectors as you want, even custom connectors. There is only one Gateway URL, but there can be multiple connectors. For example, PeopleSoft comes with HttpListeningConnector and RestListeningConnector all configured on the same server with slightly different URL patterns. Some of those protocols you mentioned don't have the concept of a URL.

Thank you Jim for the quick response,but could you please give me a brief idea of how I would be able to add multiple distinct Listening Connector's URLs (e.g. HttpListeningConnector, RestListeningConnector, PeopleSoftListeningConnector etc.) when all of them would be active as I am able to see only one Gateway URL can be added for any listening Connector in the Gateway Configuration page.

@Arnab, the gateway and the listener are two different things. The gateway holds the configuration information, but may or may not be the listener. Likewise, most connectors do NOT use HTTP or URL's, so having a URL doesn't make sense. The PeopleSoftListeningConnector is a great example. It is app server to app server. When you configure that connector, you are really configuring the app server connection information for each node that will communicate through integration points. No URL is involved. the Http style connectors, such as RestListeningConnector and HttpListeningConnector work as servlets configured and installed in the PSIGW web app. You don't have to install or configure those delivered servlets. That is out of the box. From here you will find information on configuring each of the different types of connectors: PeopleBooks > Understanding Listening Connectors.

Thanks for your reply Jim, could you please address my following concerns,

1.When multiple request are coming from an external system at the same time how the Gateway Manager will be able to know which Listening Connectors needs to be utilized, e.g. in the Gateway Configuration page I am mentioning my Listening connectors as PeopleSoftListeningConnector, but when a request is coming from an external system as REST/HTTP/Peoplesoft Based Service how it is able to pick the correct listening connector.

2.For PeopleSoftListeningConnector when it is connected through app server to app server, I hope the request is not coming from an external system.

@Arnab, I think maybe the confusion is that the requests don't actually go to the gateway URL. The gateway holds the configurations and the gateway itself is usually the first stopping point for a message when routing, but that URL that you see at the top of the gateway configuration page is NOT necessarily the URL the source system will use. A gateway is an IB instance and IB uses more than just URLs to communicate. Incoming traffic for JMS, PeopleSoftListeningConnector, etc does not use URLs. Every one of those items you mentioned, REST, HTTP, and PeopleSoft use a different URL or protocol. The PeopleSoftListeningConnector doesn't use URLs.

Jim,Good day. I have a requirement to monitor a process request and when it errors out it should automatically invoke a 3rd party web service to create a service ticket. I was trying to invoke the 3rd party sync web service on the OnNotify method of the the PSFT_REPORTING_FOLDERS which is failing as I am trying to invoke a non rowset based message from a Async handler. I am looking for other alternative to achieve this. Any help is appreciated. We aren't going to have a separate AE to monitor the process request.

I need your valuable inputs on exposing the webservice from peoplesoft.can we expose any peoplesoft webservice with out their version numbering in any of message, service, service operation, xsds and wsdl?I have just provided a peoplesoft generated wsdl file to our customer but they are not accepting it because it doesn't suit their existing SOA format like targetnamespaces, the inclusion of versions of message, service, service operations, xsds and doesn't contain ws addressing, wsam-action elements? can it be done?If I modify the wsdl manually as per their criteria by removing versioning and adding some extra elements can I invoke our peoplesoft webservice?

Sorry for not consolidating all the queries at one time.Here are few more queries.In PeopleSoft when we expose a service the esdl file has service, service operations namespaces are actually type URL but can we make it as urn?For example: from http://XML.com/service/ to urn:companyname:service

Is it possible to expose a service/ service operation without a version number in wsdl file? If I modify the wsdl file by removing the version number can PeopleSoft identify that service routings for its message?

We are in PT8.55 and imported a wsdl from third party using wizard and got ServOP(Syncnorous WS) created with Request message of type Document. The document created says autogenerated and is not editable. Can it be made editable? I need to make changes to prefix as PS is generating as "common:Element". Also, I am trying to send SOAP msg using this Document msg and not sure how to Copy the Document populated with data onto SOAPDoc before calling SyncRequest menthod. I have tried converting document into XML String using GenXMLString function and converting to XMLdoc using CreateXMLdoc and copy to SOAPdoc inside SOAP-Body. Getting Fatal error Parsing XML String error. Is this the right way to do? Any help is much appreciated. Thanks.

@Raj, I'm sure there are several ways to handle this. One would be to forget PeopleTools has a wizard and create all of the metadata yourself. Another is to use an XSL Transform on the routing to replace the node name with the appropriate name. I would likely opt for the XSL transform so you can retain all of the metadata created by PeopleTools.

As far as populating the XML document, it has been a really long time since I had to do this, but I thought the service operation had a method to get the XML doc. You would then populate the XML doc directly. About your Parsing error when trying to load XML from a string, that should only happen if the XML is really invalid. I believe the error you are seeing is at a very low level inside the XML parser (Xerces). What I would do is print the GenXMLString to file and confirm that the generated content is valid XML. It should be since it is a DOM document coming in and going out, but that is what I would do to confirm

Thank you Jim,I am able to complete the WS successfully with one issue left to resolve. Everything works fine when I send good xml request and I receive response (&ResponseMsg = %IntBroker.SyncRequest(&ReqMsg);) And when Fault occurs, the 3rd party SOA middle ware system is sending http 500 error and I don't get a response i.e. &ResponseMsg is null. I tested with SOAPUI and get the fault message with 500 error. Do you know why the PSIB is not returning the fault msg in response? I see the fault msg in the app server log.

Thanks for all your help. Currently, we are having this issue related to sending files segments(MTOM) with the SOAP response in an Synchronous WS. We are providing a Synchronous service where in the 3rd party requests a file in the Request and we are sending Binary file as a segment using &responseMessage.CreateNextSegment() method and while testing in SOAPUI we are getting just the body and not getting any segments. I wrote the &responseMessage.GetContentString before returning the &responseMessage and the Segment is there but is missing in the Gateway logfile(msglog.html). I believe the segment is getting stripped by IB. In People books it only talks about sending or Receiving in Async WS only. I am wondering, can we even do this in Synchronous model? Also the routing that is automatically generated does not allow me to change the receiving node(PSFT_HR which has PSFTTARGET COnnector) to any other HTTP connector, if that is the problem, but not sure? Please help in making me understanding how to send segments as MIME (MTOM)in the response of a Synchronous WS which I am providing to a 3rd party. Thanks for your help. Here is what I have in my OnRequest handler. And the Auto generated Routing is ANY to PSFT_HR Inbound.

Just an Update on my issue with Sending binary files(segments) in MIME(MTOM). Oracle said that it can not be done in Synchronous response. It is only possible in Async model. I am still somewhat skeptical about oracle's response as the document says it can be used in synchronous, but it doesn't say it clearly. Any thoughts about this? Also can anyone explain me how psftxopinclude works in XOP processing? there is not much in Pbooks. Thanks for all your help!

We are trying to invoke 3rd party rest service to peoplesoft. As part the header we need to pass some header values with the rest URL.

One of the header in that needs to be "HMAC SHA256 digest of the entire HTTP request using auth string as the encrypted key"Note: Auth string is computed as Base 64 encoded string as “username:password”

My question is how I need to pass auth string key value for HMAC SHA256 in peoplesoft pluggable encryption.

in rest service One of the header needs to be "HMAC SHA256 digest of the entire HTTP request using auth string as the encrypted key"Note: Auth string is computed as Base 64 encoded string as “username:password”.

how I need to pass auth string as key value to HMAC SHA256 in peoplesoft?

@Nagesh, there are a few options. First, if it is possible to transform the XML from one format to the other, then you can use XSL or PeopleCode to perform the transformation and attach the transform App Engine to you integration routing.

You don't have to transform the XML, however. You can write subscription PeopleCode to read the XML and process the information through a Component Interface.

I am trying to consume an external REST based api into Peoplesoft. I followed all the steps in peoplebooks on how to create a REST service and service operation, but every time it's creating an inbound routing automatically and, I am not able to change the REST base url in the service operation (I guess because it's assuming the api is inbound).

Somehow it doesn't look like as straight forward as consuming a SOAP based webservice. Can you please suggest any ideas on how to overcome this?

@Narender, you are correct. I may be mistaken, but I believe all of the REST configuration information allows external applications to connect to PeopleSoft using REST. I don't believe there are options for connecting to a REST service. I'm not sure you need any because you can just invoke %IntBroker.ConnectorRequestUrl to make a REST request.

We are trying to create a dedicated Messaging Server for Workflow approvals. Could you please help me with what service operation queues need to be added to the new messaging server? Is EOAW_APPROVALS the right service operation queue to be added?

Is there any difference between testing a Synchronous CI based web service (where third party integration is involved) using SOAPUI and handler tester (Peoplesoft Delivered), as for me handler tester was working fine, but the same was being tested with SOAPUI, the WSDL was not working.

The views expressed on this blog are my own and definitely reflect the views of JSMPros, my employer. The views and opinions expressed by visitors to this blog, however, are theirs and do not necessarily reflect my opinions or the opinions of JSMPros.

Please be advised: this site contains code snippets and examples that may require modifications to delivered PeopleSoft objects. Before modifying delivered code, make sure your development team approves of your modification. Likewise, ensure that you have properly documented your modification according to your organization's best practices. You and your organization will be responsible for maintaining your modifications through patches and upgrades.

The author provides development tips and modification ideas for informational purposes only. Tips and techniques presented on this site should be considered proof of concepts only. Neither the author or his employer assume any liability for problems resulting from the implementation of these ideas.