Part I of the series compiled the Java APIs that were generated for the component Interface. Now, open the component Interface and generate a Java template for that. When you take the Java file and compile it, PeopleSoft will prompt for the following values:
Enter Application Server Machine Name:
Enter Application Server Port Number:
Enter PeopleSoft UserID:
Enter PeopleSoft UserID Password:
Note that the Java template can be edited and these values can be hardcoded in the class files. Basically, this class file will use all the four class files that we have built as a part of Part I for setting the values. The four class files will inturn use the PSJOA.jar file to connect to the PeopleSoft database.
Now, when I tried executing the Java template given by PeopleSoft, I ended up with the following error:-
Unable to Connect to Application Server.
(0,0) : PeopleTools release (8.46) for web server '' is not the same as Application Server PeopleTools release (8.46.08). Access denied.
:)…tricky. I was using 8.46 in my desktop and the server was in 8.46.08..To resolve this problem, take the PSJOA.jar from the application server machine and recompile the class files. That would resolve this issue.
Once this error was fixed, I got one more error
No rows exist for the specified keys.
Failed to get the Component Interface.
(91,91) : Cannot find record. {TESTER_CI.CS_FLD_CAPTID} (91,30)
This is a straight forward one. I had modified the key values of the component interface and did not compile the four class files (generated in part 1). ..Setting the proper field names resolved this value.
After this, I tried setting the value to the field and saving the component interface. It worked like a miracle!..We have now successfully connected PeopleSoft to Java program externally. This opens up a whole lot of possibilities!..It can even substitute the integration broker component of PeopleSoft and help in seamless logging..
Keep watching this space for more..
No comments:
Post a Comment