Posted: Wed Jul 19, 2006 8:04 am Post subject: Java Compute Node, Exception Handling and Resource Bundles
Apprentice
Joined: 31 May 2006 Posts: 40
I'm trying to create a user defined message catalog for storing exception messages. I'm trying to get around having to create a DLL and Unix XPG4 catalog by using a Java Resource Bundle. I think I'm close but I'm having the following problem.
1. I created the following MYCatalog.properties file with the contents:
1002: MYCatalog1002I: \
Exception Event generated during message transformation. Additional information : ''{0}'' ''{1}''.
2. I added the properties file to the \IBM\MQSI\6.0\messages directory and to the jplugin2.jar file.
3. I excecute the following code from a Java Compute Node:
throw new MbUserException(this.getClass().getName), "evaluate", "MYCatalog", "1002", "Error", new Object[] {"Test","Test Data"});
5. Based on the following Text from the Exception List I can see that the broker is able to load my properties file and format the message correctly: (0x03000000):Text = '<com.ibm.broker.plugin.MbUserException class:ExceptionCatalogTest_JavaCompute method:evaluate source:MYCatalog key:1002 message: [MYCatalog:1002]MYCatalog1002I: Exception Event generated during message transformation. Additional information : 'Test' 'Test Data'.: >'
So my question is why is this being shown as an unhandled exception in plugin method? The catalog is still showing as BIPVv600 instead of MYCatalog so I'm assuming I'm missing something here.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum