Additional Blogs by Members
cancel
Showing results for 
Search instead for 
Did you mean: 
Former Member
   As the need arose in a customer's PI scenario to have a parameterized XSLT mapping, I started trying to get this to work. Searching the PI forum on SDN showed that I wasn't the only one struggling with this, so I decided to write this blog for the community. Hope you like it, it's my first 😉   The concept of this alternative to pass a parameter to an XSLT mapping is simple: we can access the +DynamicConfiguration+ object in an XSLT mapping is, so we need to pass the desired parameters to this object. This is done by a Java mapping. This said, you can now go on to an overview of the complete solution, a detailed description, and the necessary code. Configure.. and go !    h3. the Design: Operation Mapping   We prepend a Java mapping to the XSLT mapping to which we want to pass parameters, the +PutDynConfMapper+. This class passes the payload untouched to the next step, and puts the parameters in the XI Context. image   We define 4 import parameters in the Operation Mapping. These are: ** InputParameterNames: a meta-parameter containing the Binding names of the parameters we want to pass **  InputParameterNamespace: a second optional meta-parameter, containing the Namespace to use for the +DynamicConfigurationKey+image    These parameters need to be bound to the Java mapping step. Notice that the names here do not have to be the same, but take a note of the +Mapping Step parameter names +on the left-hand as you will need them in the next step.image    Here the names of the Java Mapping Step mapping parameters become important. +The ParameterNames parameter is obligatory, and must contain the literal names for this solution to work+. You can see the example in the Operation Mapping test scenario below. image
4 Comments