Customizing the transformed responses from InfoSphere MDM

Use the InfoSphere® MDM Workbench and the Adaptive Services Interface (ASI) to customize the way that the Kafka processor transforms responses from InfoSphere MDM.

About this task

By default, InfoSphere MDM transaction responses are provided in an XML format, and then the Kafka processor uses XSLT to transform the response to either target XML or JSON, depending on the configuration. Customize the transformation using the MDM Workbench and ASI to generate a custom XSLT file.

Procedure

  1. Create a new transformation XSL file using ASI mapping in the MDM Workbench.
  2. Copy the new XSL file to the folder <MDM_INSTALL_HOME>/KafkaProcessor/templates.
  3. Open <MDM_INSTALL_HOME>/KafkaProcessor.
  4. Edit kafkaruntime.properties and kafkabatch.properties to update the following property:
    #Target xsl mapping file
    <entity type>.transformerXSLT=TargetResponse.xsl
    Note: <entity type> is the entity type defined in the property InquiryEntities, and for which you have modified the transformation.
  5. Optionally, you can also set the output format to be either XML or JSON using the following property:
    #Target response format xml or json
    <entity type>.outputFormat=json
  6. Optionally, modify the default templates that are used to create the inquiry transaction requests.
    The templates are stored in the folder <MDM_INSTALL_HOME>/KafkaProcessor/templates. If required, you can edit:
    • the InquiryLevel
    • the namespace
    Note: The current framework provides com.ibm.mdm.kafka.interfaces.ITransformData<K,V> and com.ibm.mdm.kafka.interfaces.IMDMRequestCreator<T> interfaces for transforming responses and building request XML. If required, you can provide a custom implementation extending these interfaces and set the following properties:
    #Implementation of getParty request xml creator
    mdmGetEntityRequestCreator=<Custom implementation for IMDMRequestCreator>
    
    #Implementation of Party Response Transformer
    mdmGetEntityResponseTransformer=<Custom implementation for ITransformData>