Creating a Dashboard to Monitor Oracle B2B

24-2 Oracle Fusion Middleware Users Guide for Oracle B2B ■ Control number, group control number, transaction control number, Trading Partner name, and document type ■ Date range and Trading Partner ■ Date range, direction, and Trading Partner ■ Message ID ■ Message state ■ Protocol message ID ■ Trading Partner ■ Trading Partner and direction ■ Trading Partner and document type ■ Trading Partner and message state ■ Xpath expression can be evaluated on one or two XPath expressions ■ XPath value can be evaluated on one or two XPath expressions ■ Conversation ID For more information about the Instance Message API, see Oracle Fusion Middleware B2B Instance Message Java API Reference.

24.2 Instance Message Java API Examples

You can write your logic based on the out put of Vector messages = Vector imUtil.getInstanceMessagesForTPGlobalChips as shown in Example 24–1 . Another similar exposed method is getInstanceMessagesForMsgIdString messageId. All of the methods are documented in Oracle Fusion Middleware B2B Instance Message Java API Reference. Example 24–1 Retrieval based on Trading Partner Name import java.util.Vector; import oracle.tip.b2b.utility.InstanceMessageUtil; public class MyInstanceData { public static void mainString[] args throws Exception { InstanceMessageUtil imUtil = new InstanceMessageUtil; Vector messages = Vector imUtil.getInstanceMessagesForTPGlobalChips; System.out.printlnmessages.size; } }

24.3 Troubleshooting Instance Message Java API

See the following topics for troubleshooting information: ■ Section 24.3.1, Handling a Large Number of Messages ■ Section 24.3.2, Handing Large Payloads Programmatically Accessing Instance Message Data 24-3 ■ Section 24.3.3, Executing Queries Remotely Using Weblogic.jar

24.3.1 Handling a Large Number of Messages

If the query returns a large number of messages then the weblogic.socket.MaxMessageSizeExceededException may occur. To recover from this issue, increase weblogic.MaxMessageSize, and pass -Dweblogic.MaxMessageSize=100000000 in the client command line. This parameter setting will allow you to receive 100 MB messages. For example: java -cp .:ORACLE_HOMEwlserver_10.3serverlibwlthint3client.jar:SOA_HOME soamodulesoracle.soa.b2b_11.1.1b2b.jar -Dweblogic.MaxMessageSize=100000000 TestInstanceMsg

24.3.2 Handing Large Payloads

Rather than return the payload itself, a large inbound or outbound payload will return as a reference to the location of the payload. For example: tmpGlobalChips_1_custnonxml_largepayload.dat9844C4341297D3EB7B60000011A0CC9D .dat See Appendix A, Handling Large Payloads for more information about how Oracle B2B handles large payloads.

24.3.3 Executing Queries Remotely Using Weblogic.jar

If while using weblogic.jar and executing queries remotely you may see classpath issues for Oracle WebLogic Server, and the java.lang.ClassNotFoundException:weblogic.security.subject.Abstr actSubject exception. To recover, execute queries using wlthint3client.jar. For example: java -cp .:ORACLE_HOMEwlserver_10.3serverlibwlthint3client.jar:SOA_HOME soamodulesoracle.soa.b2b_11.1.1b2b.jar TestInstanceMsg