Jump to content
  • BW6.X - BWCE - Using TIBCO EMS message compression in BusinessWorks and BusinessWorks Container Edition


    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".
    image.png.bf114ed327b15d1d17fd66dd113a44dc.png

    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:

    1*X7aeiqih8hy1xfKnz77tBA.png

    Explanations on the two approaches mentioned above are available in this previous article:

    https://community.tibco.com/articles/tibco-activematrix-businessworks/bw6x-bwce-how-to-use-jms-application-properties-in-businessworks-6x-and-businessworks-container-edition-r3384/

    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 :

    1*0sEIy4L_6Ddm8XrUDPqrnw.png

    Then in the Input tab you have to set the property to true() to enable compression :

    1*tJ4vS5o67FjVvtO7c70uoA.png

    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:

    1*xrvwcNW1OyDN8MqSFtrKcA.png

    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.

    JMSCompressDemo.zip

    • Like 1

    User Feedback

    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 account

    Sign in

    Already have an account? Sign in here.

    Sign In Now

×
×
  • Create New...