I created a record boundNode and it looks like:
(record) boundNode
-(record) ORDERS05
–(record) IDOC
—(string) @BEGIN
—(record) EDI_DC40
—(record) E1EDK01
but now I get the following exception in transformHierarchyToFlat
java.lang.ClassCastException: com.wm.util.Values
and the details to the exception show the Call Stack with pub.sap.idoc:transformHierarchyToFlat and myService in it.
When I trace the service, I get the following message after the exception occurs.
java.lang.ClassCastException: com.wm.util.Values
at com.wm.pkg.sap.idoc.Transformer.toIDoc(Transformer.java:381)
at pub.sap.idoc.recordToIDoc(idoc.java:271)
at pub.sap.idoc.transformHierarchyToFlat(idoc.java:234)
at java.lang.reflect.Method.invoke(Native Method)
at com.wm.app.b2b.server.JavaService.baseInvoke(JavaService.java:281)
at com.wm.app.b2b.server.ServiceManager.invoke(ServiceManager.java:693)
at com.wm.app.b2b.server.BaseService.invoke(BaseService.java:140)
at com.wm.lang.flow.FlowInvoke.invoke(FlowInvoke.java:292)
at com.wm.lang.flow.FlowState.invokeNode(FlowState.java:559)
at com.wm.lang.flow.FlowState.stepIncremental(FlowState.java:482)
at com.wm.lang.flow.FlowState.invoke(FlowState.java:373)
at wm.server.flow.stepFlow(flow.java:183)
at java.lang.reflect.Method.invoke(Native Method)
at com.wm.app.b2b.server.JavaService.baseInvoke(JavaService.java:288)
at com.wm.app.b2b.server.ServiceManager.invoke(ServiceManager.java:693)
at com.wm.app.b2b.server.comm.DefaultServerRequestHandler.handleMessage(DefaultServerRequestHandler.java:80)
at com.wm.app.b2b.server.HTTPMessageHandler.process(HTTPMessageHandler.java:166)
at com.wm.app.b2b.server.HTTPDispatch.run(HTTPDispatch.java:457)
at com.wm.util.pool.PooledThread.run(C:/NT/Perforce/basis/4.1.0-terra/module/core/source/com/wm/util/pool/PooledThread.java:103)
at java.lang.Thread.run(Unknown Source)
EDIT:
I added the services recordToDocument (boundNote->xmldata), stringToDocument (xmldata->node) and documentToRecord (node->boundNode) before I call transformHierarchyToFlat and it doesn’t throw the exception now, but the IDocList is still empty.
#Flow-and-Java-services#webMethods#Integration-Server-and-ESB