TIBCO EMS provide an extension to the JMS standard that is message compression.
In the context of Integration Projects where large messages in text, XML or JSON format are processed this is sometimes useful to use this feature to limit usage of resources on the EMS server (memory and disk space), to limit the load on the storage layer and to reduce network bandwith usage.
This article explain how to use this features in BusinessWorks and BusinessWorks Container Edition.
JMS_TIBCO_COMPRESS JMS application property
In recent BusinessWorks versions you can use the DynamicProperties list available in the input of the 'JMS Send Message activity' which is convenient. In that approach just just have to add a property named 'JMS_TIBCO_COMPRESS' and set its value to true and its type to "boolean".
You may also use the the approach to create a JMS application property schema with one field of type Boolean called JMS_TIBCO_COMPRESS.
After creation the JMS application properties schema should like this:
Explanations on the two approaches mentioned above are available in this previous article:
Use of the property in the JMS Send Message activity
In the Advanced tab of the activity you need to refer to the JMS application property schema created in the previous step, like this :
Then in the Input tab you have to set the property to true() to enable compression :
There is nothing else to do (including on the Consumer application side).
Messages handling when compression is enabled
The behaviour is the following:
. While sending a message it will be compressed by the EMS client library and sent to the EMS server in compressed format saving network bandwith
. The message will be stored in the EMS server in compressed format saving memory, disk space and reducing load on the storage layer
. The message will then be sent to the consumer application in compressed format saving network bandwith, the EMS client library will automatically decompress the message and deliver it to the Consumer application (nothing to do at this level)
Useful things to know
The compression rate to be expected is similar to what you can get using zip in a Linux environment with default configuration.
One thing to keep in mind in a BusinessWorks context is that compression and decompression will occur on the BusinessWorks server and this will use cpu resources on these servers.
Use of Message compression can be very useful in a context where routing between EMS instances is managed over WAN links.
Example of two messages carrying the same text body the first one being in compressed format the second one being in text format:
The same approach can be used in BusinessWorks 5.X.
Reference elements
EMS documentation :
https://docs.tibco.com/pub/ems/10.2.1/doc/html/Default.htm#users-guide/setting-message-comp.htm
Useful Knowledge base article :
https://support.tibco.com/s/article/Tibco-KnowledgeArticle-Article-33803
Additional elements
You can refer to the attached sample project.
- 1
Recommended Comments
There are no comments to display.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now