One Star

NullPointer in child job (when executed indepentently the job works)

Hello,
i am getting a NullPointerException in the tHDFSPut component, when i run the job as a child of a another job (via tRunJob).
When i run the job seperatly, it works fine.
What can be the cause for this?
The first screenshot shows the child job (after a successful run).
The second screenshot shows the parent job (after a failed run).
Kind regards,
Christian
7 REPLIES
One Star

Re: NullPointer in child job (when executed indepentently the job works)

Hi,
NullPointerException error usually occurs when context parameter(variable)/column is not assigned with any value.
Have you defined any context parameter in tRunJob, or are you trying to pass any value from child to parent? if so make sure that you logic should assign some value to it.
Best Regards,
Mayur
One Star

Re: NullPointer in child job (when executed indepentently the job works)

I deleted all context variables and replaced them with constants.
Nevertheless i get the same NullPointer.
One Star

Re: NullPointer in child job (when executed indepentently the job works)

The stack trace tells you where it's failing. Look at the code there.
One Star

Re: NullPointer in child job (when executed indepentently the job works)

Thank you, that helped me to identify the error!
I'm using a tHDFSConnection component.
When executing the job as a child of another job, the connection-parameters from the tHDFSConnection-component cannot be read.
When i enter them manually in every hdfs-component instead of refering to the connection component, it works.
Is this a bug?
Seventeen Stars

Re: NullPointer in child job (when executed indepentently the job works)

hi,
did you try "transmit whole context" in your trunjob ?
regards
laurent
One Star

Re: NullPointer in child job (when executed indepentently the job works)

Yes, but the error persists, when using tHDFSConnection.
Seventeen Stars

Re: NullPointer in child job (when executed indepentently the job works)

I'm not able to read your tRunJob error in previous snapshop.
could you post it ?
thanks
laurent