App Connect

App Connect

Join this online user 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.


#Applicationintegration
#App Connect
#AppConnect
#Integration
#Automation
 View Only
  • 1.  Parameterising namespaces

    Posted 04/13/21 07:26 AM
    I'm currently writing flows to translate messages from Swift format to ISO80022 xml. The IBM ACE Swift support pac covers 3 different versions of Swift, currently 2018, 2019 and 2020. Different namespaces for each and there will be different namespaces for different ISO variants. I'm trying to figure out how to switch easily between versions and it would make things much easier if I could somehow pass namespaces into flows as parameters. 
    Not sure how to do this, a UDP would be a string, that doesn't work. I need to be able to pass in the namespace that a compute node will use to read the Swift DFDL and write the ISO xml and vice versa. 
    Any ideas?

    ------------------------------
    Guy Clarke
    ------------------------------


  • 2.  RE: Parameterising namespaces

    Posted 04/15/21 05:43 PM
    Outside the scope of the support pacs, I would have plenty of ideas.
    Working with UDP should work, but it is not that flexible.
    Converting strings into code works.
    What is the starting point of your flow?
    Does your input message know what version of swift/iso to work with?
    You can configure the DFDL parser at design time, deployment time and run time.


    ------------------------------
    Matthias Jungbauer
    ------------------------------



  • 3.  RE: Parameterising namespaces

    Posted 04/16/21 04:33 AM
    Hi Matthias,
    Thanks for the response. I have tried UDP but as its a string it doesn't work as a namespace, or am I missing a trick?
    How do you convert strings into code? Is that how you would use a UDP, convert it to a namespace?
    Yes at the start of the flow we know what version of the message we want. The Swift support pac supports 3 different versions, when a new pac is available with the Swift for the latest year I want to deploy that but continue to support the current year. The pac has UDPs to tell it which year we are working with. So if I can parameterise the namespaces in the ESQL, and we are not using new fields, then we can switch to the next version without code changes. Obviously if you want to take advantage of new features you may have to change code, but if the differences are simply validation then you want to avoid code changes ideally.

    ------------------------------
    Guy Clarke
    ------------------------------



  • 4.  RE: Parameterising namespaces

    Posted 04/16/21 04:46 AM
    Hi Guy,

    Please forgive me if I did not get your requirement correctly... but, I guess you want to make your ESQL code independent on a namespace value, isn't it? If so, you can declare namespace variables initializing them as strings, as in:

    DECLARE myNS NAMESPACE 'http://schemas.myCompany.com/corporate/headers/v1_0';

    and so, you could either read the namespace from the input message:

    SET inputNamespace = FIELDNAMESPACE(InputRoot.SOAP.Body);

    or from a UDP... just save the string it contains into a namespace variable (dunno if that's a game changer or just a trick, but I guess that did it for me), and then make your ESQL read it from a variable as in:

    SET OutputRoot.SOAP.Body.{inputNamespace}:Fault.(XMLNSC.NamespaceDecl)xmlns:soap = inputNamespace;

    I hope this helps! :)

    ------------------------------
    Victor Garcia
    IBM
    ------------------------------