The information in this article applies to:
Product: MIM
Version: 8.5
Platform: UNIX, Windows
Discussion
The Java Workflow Servlet Engine (Java WSE) can support multiple servlets running under one servlet context. This enables the processing to be dynamic, based on a specific tag that is set in the workflow, and reduces the number of queues that need to be configured and managed by Websphere MQ. This also allows similar functionality to be packaged in a single Jar package.
An example configuration for setting up multiple servlets under a single context is as follows:
reject-queue="MIM.REJECTED.MESSAGES" minworkers="1" maxworkers="10"
addressfield="translate" mapallrequeststo=""
classpath="file:///C:\\Program Files\\Metastorm\\MIM/java/wse/Translator.jar">
In this example, only one queue needs to be defined for the Java Servlet Engine to monitor: MIM.WSE.TRANSLATOR. Note that addressfield has been set to “translate” and mapallrequeststo has been set to “” (empty string).
Once the Java WSE reads the workflow message, it will determine which servlet should be invoked based on the value associated with the tag named translate.
Example workflow:
EnglishToSpanish
Hello, I am your translator
This workflow indicates that the EnglishToSpanish servlet should be invoked to process the workflow. In this case, the servlet EnglishToSpanish would be programmed to process the textToTranslate tag in the workflow and convert the text to Spanish.