• Welcome to KonaKart Community Forum. Please login or sign up.
 

Invocation Target + Unknown Source Exception in quartz scheduler

Started by HappyHippo, April 12, 2016, 09:55:25 am

Previous topic - Next topic

HappyHippo

Hi Guys,
I have created a quartz scheduler job.   It runs perfectly fine; but as soon as i call third party API call, i get InvocationTargetException - null  and Unknown Source  error. 
For example this simple Stripe code retrieves customer info. It works fine in konakart front end but not in konakart quartz scheduler.

com.stripe.Stripe.apiKey = "sk_XXXXXXXXXXXXXXXX";
com.stripe.model.Customer cu  = com.stripe.model.Customer.retrieve("cus_YYYYYYYYYYY");



I get following error:
WARN<?:execute:?> Problem executing getStripeCustomerInfo on com.konakartadmin.bl.StripePaymentsBatchMgr.
Exception: exception message = <java.lang.reflect.InvocationTargetException> - null
Exception stack trace=
at sun.reflect.NativeMethodAccessorImpl.invoke0<NativeMethod>
at sun.reflect.NativeMethodAccessorImpl.invoke0<NativeMethodAccessorImpl.java:57>
at sun.reflect.DelegatingMethodAccessorImpl.invoke<DelegatingMethodAccessorImpl.java:43>
at java.lang.reflect.Method.invoke<Method.java:606>
at com.konakartadmin.bl.AdminExecuteMgr.execute<Unknown Source>
at com.konakartadmin.bl.KKAdmin.execute<Unknown Source>
at com.konakartadmin.bl.ExecuteBatchEE.execute<Unknown Source>
at org.quartz.core.JobRunShell.run<JobRunShell.java:202>
at org.quartz.core.simpl.SimpleThreadPool$WorkerThread.run<SimpleThreadPool.java:573>
Exception Cause = <br />
at com.konakartadmin.bl.StripePaymentsBatchMgr.getStripeCustomerInfo<Unknown Source>

I have been trying to solve it for two days but no luck :(

What am i missing here? Please help.





julie

QuoteException Cause = <br />
at com.konakartadmin.bl.StripePaymentsBatchMgr.getStripeCustomerInfo<Unknown Source>


It looks like the exception is in your own code (StripePaymentsBatchMgr) so I'm not quite sure why you can't analyze the problem.

HappyHippo

Sorry for late reply.

Yes, problem was in my code. I had forgot to add gson library in my classpath.

Many thanks.