DataPower

DataPower

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  MQ Handler and "Header to extract Content-Type" option

    Posted Mon December 15, 2025 02:24 AM
    Edited by D@viiid Mon December 15, 2025 09:18 AM

    Hello every body

    I try to undestand how this option can be used for extracting Content-Type from MQRFH2 header through MQ Handler

    I set MQRFH2 header testHeader with 'application/json' but no Content-Type header is visible in the probes.

    This header is well set because i can get this value through this xslt 

    <xsl:variable name="testHeader" select="string(dp:parse(dp:http-request-header('MQMP'))/MQMP/Property[@name='testHeader'])"/>

    I've tried many differents xpath expression, but nothing works.

    Does anyone have the documentation ?

    Thanks

    #DataPower

    #IBMMQ

    ------------------------------
    D@viiid
    ------------------------------



  • 2.  RE: MQ Handler and "Header to extract Content-Type" option

    Posted Wed January 28, 2026 09:15 AM

    It is not working because it is not an HTTP header. It is an MQ header. A quick fix. Enable probe on MPGW and catch the MQ header. It is an XML. Use xPath tool and point to the element that you want to extract. This should achieve your task. 



    ------------------------------
    Ajitabh Sharma
    ------------------------------



  • 3.  RE: MQ Handler and "Header to extract Content-Type" option

    Posted Wed January 28, 2026 09:20 AM

    Yes, in fact, it works perfectly.
    The slight difference is that you need to populate the MQRHH2.testHeader part and not MQRFH2.usr.testHeader



    ------------------------------
    D@viiidD@viiid
    ------------------------------