Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Process Manager (Stardust) » Inspect message transformation activity mappings at runtime
Inspect message transformation activity mappings at runtime [message #949486] Thu, 18 October 2012 22:48 Go to next message
Robert Emsbach is currently offline Robert Emsbach
Messages: 115
Registered: October 2011
Location: Singapore
Senior Member

Is it possible to know the outcome of a message transformation activity in a subsequent activity? For instance to know that of a possible 100 fields in a structured data type, only 3 were mapped in a transformation ?


Re: Inspect message transformation activity mappings at runtime [message #949490 is a reply to message #949486] Thu, 18 October 2012 22:49 Go to previous message
Robert Emsbach is currently offline Robert Emsbach
Messages: 115
Registered: October 2011
Location: Singapore
Senior Member

You can try something like this:
ServiceFactory sf = ServiceFactoryLocator.get("motu","motu");
QueryService qs = sf.getQueryService();
ProcessDefinition pdef = qs.getProcessDefinition("MTAProcess");
Activity activity = pdef.getActivity("Transform");
Application application = activity.getApplication();
if(application.getAllAttributes().keySet().contains("messageTransformation:TransformationProperty")) { //MTA
String[] fields = ((String)application.getAttribute("messageTransformation:TransformationProperty")).split("fieldMappings");
for(String field: fields) {
      if(field.contains("fieldPath")) {
        System.out.println(field.trim().split("fieldPath=")[1].split("\\s+")[0]); //print target of xform
      }
}
Previous Topic:Migration of Participants
Next Topic:Unable to deploy stardust in weblogic 10.3.3
Goto Forum:
  


Current Time: Wed Jul 30 19:31:48 EDT 2014

Powered by FUDForum. Page generated in 0.01487 seconds