ClassCastException

Hi,

While running our graph we are getting the below exception. This is happening intermittently and we are not able to find out the root cause since there is no regular pattern of failure.

Both fields are String only.
We have the dictionary entry in the graph which is having the job’s run id passed as input from the Job:

And RunId is part of the output metadata.

For some more context, we are doing a web service call in phase 2 and once we get the data, we are starting phase 3 where this error is happening. Getting the response might vary from 2 to several minutes.

Due to client’s confidentiality, we won’t be able to post the graph and job. I will provide more information if needed.

2014-11-04 06:03:04,770 INFO 71230 [WatchDog_71230] Execution of phase [2] successfully finished - elapsed time(sec): 179
2014-11-04 06:03:04,770 INFO 71230 [WatchDog_71230] Starting up all nodes in phase [3]
2014-11-04 06:03:04,771 INFO 71230 [WatchDog_71230] Successfully started all nodes in phase!
2014-11-04 06:03:04,773 ERROR 71230 [WatchDog_71230] Component [Reformat:REFORMAT] finished with status ERROR. (In0: 70 recs, Out0: 69 recs)
Message: Transform failed!
Interpreter runtime exception on line 16 column 19
Caused by: java.lang.ClassCastException → null
----------------------- CTL2 snippet -----------------------
16: $out.0.RunId =“-”+dictionary.feedRunId;
^^^^^^^^^^^^^^^^^^^^^^^^
----------------------- CTL2 snippet -----------------------
2014-11-04 06:03:04,773 ERROR 71230 [WatchDog_71230] Error details:
org.jetel.exception.JetelRuntimeException: Component [Reformat:REFORMAT] finished with status ERROR. (In0: 70 recs, Out0: 69 recs)
at org.jetel.graph.Node.createNodeException(Node.java:566)
at org.jetel.graph.Node.run(Node.java:542)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: org.jetel.exception.TransformException: Message: Transform failed!
at org.jetel.component.CTLRecordTransformAdapter.transformOnError(CTLRecordTransformAdapter.java:110)
at org.jetel.component.Reformat.execute(Reformat.java:273)
at org.jetel.graph.Node.run(Node.java:505)
… 3 more
Caused by: org.jetel.ctl.TransformLangExecutorRuntimeException: Interpreter runtime exception on line 16 column 19
Caused by: java.lang.ClassCastException → null
----------------------- CTL2 snippet -----------------------
16: $out.0.RunId =“-”+dictionary.feedRunId;
^^^^^^^^^^^^^^^^^^^^^^^^
----------------------- CTL2 snippet -----------------------
at org.jetel.ctl.ASTnode.CLVFAddNode.jjtAccept(CLVFAddNode.java:52)
at org.jetel.ctl.TransformLangExecutor.evaluateRHS(TransformLangExecutor.java:1810)
at org.jetel.ctl.TransformLangExecutor.visit(TransformLangExecutor.java:1689)
at org.jetel.ctl.ASTnode.CLVFAssignment.jjtAccept(CLVFAssignment.java:52)
at org.jetel.ctl.TransformLangExecutor.executeAndCleanup(TransformLangExecutor.java:2648)
at org.jetel.ctl.TransformLangExecutor.visit(TransformLangExecutor.java:1514)
at org.jetel.ctl.ASTnode.CLVFBlock.jjtAccept(CLVFBlock.java:44)
at org.jetel.ctl.TransformLangExecutor.executeFunction(TransformLangExecutor.java:2503)
at org.jetel.ctl.TransformLangExecutor.executeFunction(TransformLangExecutor.java:2560)
at org.jetel.component.CTLRecordTransformAdapter.transformImpl(CTLRecordTransformAdapter.java:121)
at org.jetel.component.CTLRecordTransformAdapter.transform(CTLRecordTransformAdapter.java:102)
at org.jetel.component.Reformat.execute(Reformat.java:271)
… 4 more
Caused by: org.jetel.exception.JetelRuntimeException
at org.jetel.ctl.TransformLangExecutorRuntimeException.(TransformLangExecutorRuntimeException.java:53)
at org.jetel.ctl.TransformLangExecutorRuntimeException.(TransformLangExecutorRuntimeException.java:75)
… 16 more
Caused by: java.lang.ClassCastException

Thanks and regards,
SCL

Hi SCL,

could you please check using which component you write into dictionary entry feedRunId (e.g. mapping within some particular component etc.)?

Thank you!

Hi Jan,

We are using the ExecuteJobflow component which is calling a graph… :? (do you think this might affect? :roll: :roll: )
And we are using the input mapping to write into the dictionary value which is in the graph ($out.2.feedRunId).

function integer transform() {

$out.2.syncFrom = dictionary.syncFrom;
$out.2.feedRunId = getParamValue(“RUN_ID”);

return ALL;
}

Thanks and regards,
SCL

Hi SCL,

Well we are trying to find out what might have caused the exception. Could you please provide us with some more information:

  • What CloverETL version you use

  • What Java version you use

  • Full stack trace (or even log if possible) - at least we need to see the part that follows the exception.

Thanks a lot!

SCL,

It would also be very helpful to see your graph. We do not need to see your data of course, so you may delete all sensitive information from the graph.

Thanks!