IBM BPM, V8.0.1, All platforms > Authoring services in Integration Designer > Defining and transforming data > Transforming data > Transforming data using a business object map
Limitations of the business object map editor
There are current limitations that you should be aware of when using the business object map editor.
- If you need to use extra logic in assigning values from one array to another array (other than Move), you can use Submap or Custom. Submap iterates every element in the array and performs Submap. Custom, Custom Assign, and Custom Callout enables more complicated computation written in Javaâ„¢.
- Business object mapping cannot make a SCA callout to another component at a non-Java level when mapping. As a workaround for this limitation, you can either:
- write Java code using Custom mapping to make a callout. In order to call a SCA component in Java code, you can pass the component name to the servicemanager.locateService(); or
- call an operation in WSDL by taking the required WSDL file and generating a web service Java proxy for it in. You can do this by clicking New > Other > Show All Wizards > Web Services Client. Click Next. In a custom text mapping in a business object map, try to make a web service call to an operation in the WSDL file.
- Transforms with type Move Event Summary, Assign Event Summary, Move Change Summary, Assign Change Summary do not create a child business object instance. Ensure that a business object map does not only contain transforms with these four types. If Event Summary/Change Summary Move/Set is used in the map, it cannot be used as transformation #1. It has to be preceded by at least one of the basic transforms that will guarantee that target child business object is created first.
You can either expand the business object contained in the business graph and do some basic mappings - Move, Set, or call a Submap.
- In the business object map editor, if the transform involves a top-level business object and is of the type Custom, Custom Assign, or Custom Callout, the casting code generated by default does not contain the top level business object. You may have difficulties finding the variable used for the top-level business object. You will see this problem if you have the following conditions:
- The transform type is Custom, Custom Assign or Custom Callout
- In the Details tab, you select Java (not Visual)
- The output or the input of the transform involves a top-level business object
There is some generated code existing in the text editor that casts the type of the input or output for you, but if it satisfies these three conditions, the casting code will not be displayed. A workaround is to use the Code Assist window. Press Ctrl + Spacebar to get a list of variables available for selection in the code snippet.
- For Move transforms, there is a restriction for data type pairs. For these cases, hexBinary can only move from/to hexBinary/Integer data types.
- When working with large business objects, you may encounter difficulty scrolling when dragging a connection from a source to a target (by clicking and holding down the mouse button and releasing when hovering over the target). The editor will not automatically scroll down to accommodate the connection. However, this problem only occurs when using the editor's scroll bars to find the destination. The dragging event will not enable you to interact with scroll bars at the same time. However, the preferred interaction can be easily achieved by single-clicking the source wire handle, or right-clicking the source field and selecting Add Connection:
This will initiate the transform creation action while still giving you the ability to make use of the scroll bars. This way, you can make use of the scroll bars to find the target, whereby an additional click at the destination will complete the transform.
- A Move transform is valid between different simple type fields, however, there is the possibility of a runtime exception occurring if the input simple type cannot be converted to the output simple type. Also, a Move transform is only valid between complex types that are the same.
- If a business object is created using Enterprise Service Discovery (ESD), its elements are always simpleType with restrictions even though the attribute is of primitive type. A simpleType with restrictions is treated as a DataObject by EMF (this is an EMF limitation). A complexType is treated as a child business object inside a parent business object. Therefore, join operation on two business objects cannot be supported without custom code in the current implementation of the IBM BPM framework. A workaround for this problem is to use a Java custom code parameter mediation to mediate between the two types.
- Custom, Custom Assign, and Custom Callout transforms cannot directly work with anonymous complex types within the Java Snippet editor. As a result of this limitation, inputs or outputs on a custom transform that directly reference anonymous complex types will instead reference the top-level business object within the Java Snippet editor.
The following example shows a Custom transform that directly references anonymous complex types for both its input and output:
complex types for both its input and output" />As a result, working with these anonymous complex types within the Visual Snippet editor in the Details property tab would be performed as follows:
Alternatively, working with these anonymous complex types within the Java text editor in the Details property tab would be performed as follows:
commonj.sdo.DataObject inputBO1 = (commonj.sdo.DataObject)BO1; commonj.sdo.DataObject outputBO3 = (commonj.sdo.DataObject)BO3; // create BO1 used on the target side com.ibm.websphere.bo.BOFactory factory = (com.ibm.websphere.bo.BOFactory) new com.ibm.websphere.sca.ServiceManager().locateService("com/ibm/websphere/bo/BOFactory"); commonj.sdo.DataObject outputBO1 = factory.create("http://NewModule","BO1"); outputBO3.set("field2", outputBO1); commonj.sdo.DataObject inputAnonType = inputBO1.getDataObject("anonType"); outputBO3.getDataObject("field2").set("anonType", inputAnonType);- Submap transforms cannot exist between inputs or outputs that involve anonymous complex types. Inputs and outputs to Submap transformations must be well defined and for this reason, the business object mapping editor will prevent Submap transforms involving anonymous complex types.
- Cardinality support is limited to only iterate over the last arrayed element involved in inputs and outputs of a transform. IBM BPM does not allow transforms to iterate over multiple levels of an input or multiple levels of an output. To satisfy this constraint, only the deepest nested arrayed field of an input or output to a transform can optionally provide an index. All other arrayed fields must be specified with an index.
As an example, the following example illustrates a Move transform that is involved with an input arrayed field containing multiple levels of arrayed parent fields, and an output arrayed field that is a direct child of the output business object:
As a result, within the Cardinality tab of the Properties view, indexes must be specified at each of the arrayed fields down to the deepest nested arrayed field associated with the Move transform for both inputs and outputs. It is optional to specify an index on the deepest nested arrayed field, however, if an index is omitted the transformation will iterate over all elements of the array when being executed on IBM Process Server:
If you want to iterate over multiple levels of arrayed fields, consider using Submap transforms.
Transforming data using a business object map