Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Error when mapping a node with multiple occurence

Hi,

When I try to run my process where I have countries defines in a drop down box in the UI. I get the following error when completing this step. The target in the mapping is a dataobject which should be able to occure multiple times.

Here is the mapping:

Source: Target:

Country(Node) Country(Node)

Country(String)

Code(String)

com.sap.glx.adapter.api.AdapterException: com.sap.glx.core.kernel.api.TransitionRollbackException: Exception during prepare, rolling back

at com.sap.glx.process.adapter.bpmn.impl.BPMNAdapter.startProcesses(BPMNAdapter.java:1444)

at com.sap.glx.process.adapter.bpmn.impl.BPMNAdapter.startProcesses(BPMNAdapter.java:1540)

at com.sap.glx.process.impl.ProcessManagerImpl.startProcess(ProcessManagerImpl.java:938)

at com.sap.glx.process.impl.ProcessManagerBean.startProcess(ProcessManagerBean.java:372)

at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

at java.lang.reflect.Method.invoke(Method.java:585)

at com.sap.engine.services.ejb3.runtime.impl.RequestInvocationContext.proceedFinal(RequestInvocationContext.java:46)

at com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed(AbstractInvocationContext.java:166)

at com.sap.engine.services.ejb3.runtime.impl.Interceptors_StatesTransition.invoke(Interceptors_StatesTransition.java:19)

at com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed(AbstractInvocationContext.java:177)

at com.sap.engine.services.ejb3.runtime.impl.Interceptors_Resource.invoke(Interceptors_Resource.java:71)

at com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed(AbstractInvocationContext.java:177)

at com.sap.engine.services.ejb3.runtime.impl.Interceptors_Transaction.doWorkWithAttribute(Interceptors_Transaction.java:38)

at com.sap.engine.services.ejb3.runtime.impl.Interceptors_Transaction.invoke(Interceptors_Transaction.java:22)

at com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed(AbstractInvocationContext.java:177)

at com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed(AbstractInvocationContext.java:189)

at com.sap.engine.services.ejb3.runtime.impl.Interceptors_StatelessInstanceGetter.invoke(Interceptors_StatelessInstanceGetter.java:16)

at com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed(AbstractInvocationContext.java:177)

at com.sap.engine.services.ejb3.runtime.impl.Interceptors_SecurityCheck.invoke(Interceptors_SecurityCheck.java:21)

at com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed(AbstractInvocationContext.java:177)

at com.sap.engine.services.ejb3.runtime.impl.Interceptors_ExceptionTracer.invoke(Interceptors_ExceptionTracer.java:16)

at com.sap.engine.services.ejb3.runtime.impl.AbstractInvocationContext.proceed(AbstractInvocationContext.java:177)

at com.sap.engine.services.ejb3.runtime.impl.DefaultInvocationChainsManager.startChain(DefaultInvocationChainsManager.java:133)

at com.sap.engine.services.ejb3.runtime.impl.DefaultEJBProxyInvocationHandler.invoke(DefaultEJBProxyInvocationHandler.java:164)

at $Proxy453.startProcess(Unknown Source)

at com.sap.tc.bpem.wdui.procstarter.procstarter.comp.ProcStarterComp.startProcess(ProcStarterComp.java:377)

at com.sap.tc.bpem.wdui.procstarter.procstarter.comp.wdp.InternalProcStarterComp.startProcess(InternalProcStarterComp.java:175)

at com.sap.tc.bpem.wdui.procstarter.procstarter.comp.ProcStarterCompView.onActionStartProcess(ProcStarterCompView.java:626)

at com.sap.tc.bpem.wdui.procstarter.procstarter.comp.wdp.InternalProcStarterCompView.wdInvokeEventHandler(InternalProcStarterCompView.java:325)

at com.sap.tc.webdynpro.progmodel.generation.DelegatingView.invokeEventHandler(DelegatingView.java:131)

at com.sap.tc.webdynpro.progmodel.controller.Action.fire(Action.java:72)

at com.sap.tc.webdynpro.clientserver.phases.ProcessingEventPhase.doHandleActionEvent(ProcessingEventPhase.java:156)

at com.sap.tc.webdynpro.clientserver.phases.ProcessingEventPhase.execute(ProcessingEventPhase.java:91)

at com.sap.tc.webdynpro.clientserver.window.WindowPhaseModel.processRequestPartly(WindowPhaseModel.java:162)

at com.sap.tc.webdynpro.clientserver.window.WindowPhaseModel.doProcessRequest(WindowPhaseModel.java:110)

at com.sap.tc.webdynpro.clientserver.window.WindowPhaseModel.processRequest(WindowPhaseModel.java:97)

at com.sap.tc.webdynpro.clientserver.window.WebDynproWindow.processRequest(WebDynproWindow.java:468)

at com.sap.tc.webdynpro.clientserver.cal.AbstractClient.executeTasks(AbstractClient.java:52)

at com.sap.tc.webdynpro.clientserver.cal.ClientApplication.doExecute(ClientApplication.java:1505)

at com.sap.tc.webdynpro.clientserver.cal.ClientApplication.doProcessing(ClientApplication.java:1319)

at com.sap.tc.webdynpro.serverimpl.core.sessionctx.AbstractExecutionContextDispatcher.delegateToApplicationDoProcessing(AbstractExecutionContextDispatcher.java:154)

at com.sap.tc.webdynpro.serverimpl.wdc.sessionctx.DispatchHandlerForAppProcessing.doService(DispatchHandlerForAppProcessing.java:35)

at com.sap.tc.webdynpro.serverimpl.wdc.sessionctx.AbstractDispatchHandler.service(AbstractDispatchHandler.java:116)

at com.sap.engine.services.servlets_jsp.server.deploy.impl.module.IRequestDispatcherImpl.dispatch(IRequestDispatcherImpl.java:95)

at com.sap.tc.webdynpro.serverimpl.wdc.sessionctx.ExecutionContextDispatcher.dispatchToApplicationDoProcessing(ExecutionContextDispatcher.java:114)

at com.sap.tc.webdynpro.serverimpl.core.sessionctx.AbstractExecutionContextDispatcher.dispatch(AbstractExecutionContextDispatcher.java:80)

at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.dispatch(ApplicationSession.java:571)

at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.dispatch(ApplicationSession.java:602)

at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.doApplicationProcessingStandalone(ApplicationSession.java:523)

at com.sap.tc.webdynpro.clientserver.session.ApplicationSession.doProcessing(ApplicationSession.java:270)

at com.sap.tc.webdynpro.clientserver.session.ClientSession.doApplicationProcessing(ClientSession.java:729)

at com.sap.tc.webdynpro.clientserver.session.ClientSession.doProcessing(ClientSession.java:256)

at com.sap.tc.webdynpro.clientserver.session.RequestManager.doProcessing(RequestManager.java:258)

at com.sap.tc.webdynpro.serverimpl.core.sessionctx.AbstractExecutionContextDispatcher.delegateToRequestManager(AbstractExecutionContextDispatcher.java:202)

at com.sap.tc.webdynpro.serverimpl.wdc.sessionctx.DispatchHandlerForRequestManager.doService(DispatchHandlerForRequestManager.java:38)

at com.sap.tc.webdynpro.serverimpl.wdc.sessionctx.AbstractDispatchHandler.service(AbstractDispatchHandler.java:116)

at com.sap.engine.services.servlets_jsp.server.deploy.impl.module.IRequestDispatcherImpl.dispatch(IRequestDispatcherImpl.java:95)

at com.sap.tc.webdynpro.serverimpl.wdc.sessionctx.ExecutionContextDispatcher.dispatchToRequestManager(ExecutionContextDispatcher.java:140)

at com.sap.tc.webdynpro.serverimpl.core.sessionctx.AbstractExecutionContextDispatcher.dispatch(AbstractExecutionContextDispatcher.java:92)

at com.sap.tc.webdynpro.serverimpl.core.sessionctx.AbstractExecutionContextDispatcher.dispatch(AbstractExecutionContextDispatcher.java:104)

at com.sap.tc.webdynpro.serverimpl.core.AbstractDispatcherServlet.doContent(AbstractDispatcherServlet.java:87)

at com.sap.tc.webdynpro.serverimpl.core.AbstractDispatcherServlet.doPost(AbstractDispatcherServlet.java:61)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

at com.sap.engine.services.servlets_jsp.server.Invokable.invoke(Invokable.java:140)

at com.sap.engine.services.servlets_jsp.server.Invokable.invoke(Invokable.java:37)

at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.runServlet(HttpHandlerImpl.java:466)

at com.sap.engine.services.servlets_jsp.server.HttpHandlerImpl.handleRequest(HttpHandlerImpl.java:291)

at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:396)

at com.sap.engine.services.httpserver.server.RequestAnalizer.startServlet(RequestAnalizer.java:385)

at com.sap.engine.services.servlets_jsp.filters.DSRWebContainerFilter.process(DSRWebContainerFilter.java:48)

at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

at com.sap.engine.services.servlets_jsp.filters.ServletSelector.process(ServletSelector.java:76)

at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

at com.sap.engine.services.servlets_jsp.filters.ApplicationSelector.process(ApplicationSelector.java:240)

at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

at com.sap.engine.services.httpserver.filters.WebContainerInvoker.process(WebContainerInvoker.java:78)

at com.sap.engine.services.httpserver.chain.HostFilter.process(HostFilter.java:9)

at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

at com.sap.engine.services.httpserver.filters.ResponseLogWriter.process(ResponseLogWriter.java:60)

at com.sap.engine.services.httpserver.chain.HostFilter.process(HostFilter.java:9)

at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

at com.sap.engine.services.httpserver.filters.DefineHostFilter.process(DefineHostFilter.java:27)

at com.sap.engine.services.httpserver.chain.ServerFilter.process(ServerFilter.java:12)

at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

at com.sap.engine.services.httpserver.filters.MonitoringFilter.process(MonitoringFilter.java:29)

at com.sap.engine.services.httpserver.chain.ServerFilter.process(ServerFilter.java:12)

at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

at com.sap.engine.services.httpserver.filters.MemoryStatisticFilter.process(MemoryStatisticFilter.java:43)

at com.sap.engine.services.httpserver.chain.ServerFilter.process(ServerFilter.java:12)

at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

at com.sap.engine.services.httpserver.filters.DSRHttpFilter.process(DSRHttpFilter.java:42)

at com.sap.engine.services.httpserver.chain.ServerFilter.process(ServerFilter.java:12)

at com.sap.engine.services.httpserver.chain.AbstractChain.process(AbstractChain.java:78)

at com.sap.engine.services.httpserver.server.Processor.chainedRequest(Processor.java:457)

at com.sap.engine.services.httpserver.server.Processor$FCAProcessorThread.process(Processor.java:250)

at com.sap.engine.services.httpserver.server.rcm.RequestProcessorThread.run(RequestProcessorThread.java:45)

at com.sap.engine.core.thread.execution.Executable.run(Executable.java:109)

at com.sap.engine.core.thread.execution.CentralExecutor$SingleThread.run(CentralExecutor.java:314)

Caused by: com.sap.glx.core.kernel.api.TransitionRollbackException: Exception during prepare, rolling back

at com.sap.glx.core.kernel.mmtx.AbstractTransactionBase.rollback(AbstractTransactionBase.java:517)

at com.sap.glx.core.kernel.mmtx.AbstractTransaction.do_prepare(AbstractTransaction.java:174)

at com.sap.glx.core.kernel.mmtx.AbstractTransaction.commit(AbstractTransaction.java:77)

at com.sap.glx.process.adapter.bpmn.impl.BPMNAdapter.startProcesses(BPMNAdapter.java:1429)

... 100 more

Caused by: com.sap.glx.core.kernel.api.TransitionRollbackException: Exception during prepare, rolling back

at com.sap.glx.core.kernel.mmtx.AbstractTransactionBase.rollback(AbstractTransactionBase.java:517)

at com.sap.glx.core.kernel.mmtx.AbstractTransaction.do_prepare(AbstractTransaction.java:174)

at com.sap.glx.core.kernel.mmtx.AbstractTransaction.commit(AbstractTransaction.java:77)

at com.sap.glx.core.kernel.mmtx.PrimaryTransaction.inPrepare(PrimaryTransaction.java:88)

at com.sap.glx.core.kernel.mmtx.AbstractTransaction.do_prepare(AbstractTransaction.java:172)

... 102 more

Caused by: com.sap.glx.core.kernel.api.TransitionException: An exception occurred while executing the script "_Create_Customer:START_CONTROL_EVENT_Start_0(

com.sap.glx.adapter.BPMNAdapter:Request request,

com.sap.glx.adapter.BPMNAdapter:Event_0_Start_0_be1d130db236787f7569b7e757e720a8 event){

initiator=request:initiator;

kicker=request:kicker;

parent=new com.sap.glx.adapter.BPMNAdapter:Instance_0_prcMido_be1d130db236787f7569b7e757e720a8(initiator, null, kicker, false);

token=new com.sap.glx.adapter.BPMNAdapter:Token_0_prcMido_be1d130db236787f7569b7e757e720a8(parent, 0);

exit=new com.sap.glx.adapter.BPMNAdapter:Exit();

exit:addParameter(request);

exit:addParameter(event);

exit:onActivation("48EDB5A6AD6960C095D511DDA4DA0013E88242DB", parent, token);

delete exit;

controller=new com.sap.glx.adapter.internal.ExceptionAdapter:ExceptionController();

controller:setContext(token);

delete controller;

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_8_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

role_2=new com.sap.glx.adapter.internal.ContainerAdapter:View_0_Approver_PotentialOwners_be1d130db236787f7569b7e757e720a8(parent, scope, -1, false);

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_0_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

role_3=new com.sap.glx.adapter.internal.ContainerAdapter:View_1_Enhance_PotentialOwners_be1d130db236787f7569b7e757e720a8(parent, scope, -1, false);

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_10_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

role_4=new com.sap.glx.adapter.internal.ContainerAdapter:View_2_Administrators_be1d130db236787f7569b7e757e720a8(parent, scope, -1, false);

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_1_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

role_5=new com.sap.glx.adapter.internal.ContainerAdapter:View_3_Creator_ExcludedOwners_be1d130db236787f7569b7e757e720a8(parent, scope, -1, false);

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_3_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

role_6=new com.sap.glx.adapter.internal.ContainerAdapter:View_4_Approver_ExcludedOwners_be1d130db236787f7569b7e757e720a8(parent, scope, -1, false);

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_2_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

context_0=new com.sap.glx.adapter.internal.ContainerAdapter:Context_0_DO_Customer2_be1d130db236787f7569b7e757e720a8(parent, scope, 0, false);

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_4_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

role_7=new com.sap.glx.adapter.internal.ContainerAdapter:View_5_Create_Customer_In_MDM_PotentialOwners_be1d130db236787f7569b7e757e720a8(parent, scope, -1, false);

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_5_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

role_9=new com.sap.glx.adapter.internal.ContainerAdapter:View_7_Enhance_ExcludedOwners_be1d130db236787f7569b7e757e720a8(parent, scope, -1, false);

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_12_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

role_8=new com.sap.glx.adapter.internal.ContainerAdapter:View_6_Creator_PotentialOwners_be1d130db236787f7569b7e757e720a8(parent, scope, -1, false);

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_7_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

view_11=new com.sap.glx.adapter.internal.ContainerAdapter:View_9_TextVariables_be1d130db236787f7569b7e757e720a8(parent, scope, -1, false);

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_14_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

role_10=new com.sap.glx.adapter.internal.ContainerAdapter:View_8_Create_Customer_In_MDM_ExcludedOwners_be1d130db236787f7569b7e757e720a8(parent, scope, -1, false);

scope=new com.sap.glx.adapter.internal.TypeRegistry:Scope_6_Create_Customer_be1d130db236787f7569b7e757e720a8(parent);

context_1=new com.sap.glx.adapter.internal.ContainerAdapter:Context_1_DO_Customer_be1d130db236787f7569b7e757e720a8(parent, scope, 0, false);

message=request:getData();

mapper=new com.sap.glx.adapter.internal.Transformer:DataMapper();

yves_in=new com.sap.glx.adapter.internal.Transformer:Data();

yves_out=new com.sap.glx.adapter.internal.Transformer:Data();

yves_in:setData("http://mido.se/", "$http://mido.se/:StartProcess2", message, "61302BDB06E4BB8B9F557FC1D1D2ACC9");

data=context_1:getData();

scope=new com.sap.glx.adapter.internal.TypeRegistry:GenericScope(null, "872ED00C5EA0B74AE6F92027833B9366");

copy=scope:copy(data);

delete scope;

yves_out:setData("sap.com/glx/", "$sap.com/glx/:DO_Customer", copy, "872ED00C5EA0B74AE6F92027833B9366");

mapper:map("48EDB5A6AD6960C395D511DD84C80013E88242DB_be1d130db236787f7569b7e757e720a8", yves_in, yves_out);

data=yves_out:getData("sap.com/glx/", "$sap.com/glx/:DO_Customer", "872ED00C5EA0B74AE6F92027833B9366");

context_1:setData(data);

delete yves_in;

delete yves_out;

delete mapper;

delete event;

}"

at com.sap.glx.core.kernel.execution.transition.ScriptTransition.execute(ScriptTransition.java:69)

at com.sap.glx.core.kernel.execution.transition.Transition.commence(Transition.java:241)

at com.sap.glx.core.kernel.mmtx.DirectNestedTransaction.inPrepare(DirectNestedTransaction.java:57)

at com.sap.glx.core.kernel.mmtx.AbstractTransaction.do_prepare(AbstractTransaction.java:172)

... 105 more

Caused by: com.sap.glx.core.kernel.api.TransitionException: An exception occurred while executing the script command "mapper:map("48EDB5A6AD6960C395D511DD84C80013E88242DB_be1d130db236787f7569b7e757e720a8", yves_in, yves_out)"

at com.sap.glx.core.kernel.trigger.config.Script.execute(Script.java:675)

at com.sap.glx.core.kernel.execution.transition.ScriptTransition.execute(ScriptTransition.java:64)

... 108 more

Caused by: java.lang.IllegalStateException: Occurrence violated

at com.sap.glx.mapping.execution.implementation.node.SdoNode$PrimitiveItemContainer.appendNode(SdoNode.java:372)

at com.sap.glx.mapping.execution.implementation.assignment.SetAssignment.assign(SetAssignment.java:23)

at com.sap.glx.mapping.execution.implementation.Interpreter.mapPart(Interpreter.java:145)

at com.sap.glx.mapping.execution.implementation.Interpreter.mapPart(Interpreter.java:151)

at com.sap.glx.mapping.execution.implementation.Interpreter.mapPart(Interpreter.java:151)

at com.sap.glx.mapping.execution.implementation.Interpreter.mapMapping(Interpreter.java:140)

at com.sap.glx.mapping.execution.implementation.Interpreter.map(Interpreter.java:135)

at com.sap.glx.core.internaladapter.Transformer$ClassRegistry$MapperClassManager$MapperClassHandler$MapperInvocationHandler.invoke(Transformer.java:1797)

at com.sap.glx.core.internaladapter.Transformer$TransformerInvocationHandler.invoke(Transformer.java:399)

at com.sap.glx.core.dock.impl.DockObjectImpl.invokeMethod(DockObjectImpl.java:459)

at com.sap.glx.core.kernel.trigger.config.Script$MethodInvocation.execute(Script.java:247)

at com.sap.glx.core.kernel.trigger.config.Script.execute(Script.java:670)

replied

Hi Michael,

could you provide much more details about the source and target structures and the mappings you need to define?

Something like :

Source:

Country (single or multiple? )

..Country (single or multiple? )

..Code (single or multiple? )

Target

Country (single or multiple? ) --> does it have the same type as the source node?

In general If you try to assign a list of values to target which accepts single value you are most likely to get exception like the one given in your post.

In other words let's assume :

Country[] Country

..Country------>Country

..Code

this will throw exception at runtime in most of the cases.

The reason is that the result of select Country/Country is a list with all Countries. And then the engine will try to assign this list to the single valued target node.

Is this what you have described or it si something different?

BTW for the example above there is a fix in SP1 and such kind of mappings are marked as erroneous.

Best Regards,

Boris

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question