Page 1 of 1

[Fixed in 0.2.0] NullReferenceException in revertDeviceTaskToNone

Posted: Sat Jul 30, 2016 7:51 am
by X-Cubed
Just noticed this in the logs:

Code: Select all

java.lang.NullPointerException: null
        at net.unimus.business.backup.handler.CoreRequestBuilder.revertDeviceTaskToNone(CoreRequestBuilder.java:119) ~[unimus-server-0.1.3.jar!/:0.1.3]
        at net.unimus.business.backup.handler.CoreRequestBuilder$$FastClassBySpringCGLIB$$faffceaf.invoke(<generated>) ~[unimus-server-0.1.3.jar!/:0.1.3]
        at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204) ~[spring-core-4.2.7.RELEASE.jar!/:4.2.7.RELEASE]
        at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:720) ~[spring-aop-4.2.7.RELEASE.jar!/:4.2.7.RELEASE]
        at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:157) ~[spring-aop-4.2.7.RELEASE.jar!/:4.2.7.RELEASE]
        at org.springframework.transaction.interceptor.TransactionInterceptor$1.proceedWithInvocation(TransactionInterceptor.java:99) ~[spring-tx-4.2.7.RELEASE.jar!/:4.2.7.RELEASE]
        at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:281) ~[spring-tx-4.2.7.RELEASE.jar!/:4.2.7.RELEASE]
        at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96) ~[spring-tx-4.2.7.RELEASE.jar!/:4.2.7.RELEASE]
        at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179) ~[spring-aop-4.2.7.RELEASE.jar!/:4.2.7.RELEASE]
        at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:655) ~[spring-aop-4.2.7.RELEASE.jar!/:4.2.7.RELEASE]
        at net.unimus.business.backup.handler.CoreRequestBuilder$$EnhancerBySpringCGLIB$$5be58eb8.revertDeviceTaskToNone(<generated>) ~[unimus-server-0.1.3.jar!/:0.1.3]
        at net.unimus.business.backup.handler.BackupJobExecutor.execute(BackupJobExecutor.java:29) ~[unimus-server-0.1.3.jar!/:0.1.3]
        at net.unimus.business.backup.container.BackupJobImpl.start(BackupJobImpl.java:47) ~[unimus-server-0.1.3.jar!/:0.1.3]
        at net.unimus.business.backup.container.BackupJobImpl.run(BackupJobImpl.java:53) ~[unimus-server-0.1.3.jar!/:0.1.3]
        at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54) ~[spring-context-4.2.7.RELEASE.jar!/:4.2.7.RELEASE]
        at org.springframework.scheduling.concurrent.ReschedulingRunnable.run(ReschedulingRunnable.java:81) [spring-context-4.2.7.RELEASE.jar!/:4.2.7.RELEASE]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [na:1.8.0_91]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_91]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) [na:1.8.0_91]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) [na:1.8.0_91]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_91]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_91]
        at java.lang.Thread.run(Thread.java:745) [na:1.8.0_91]

Re: NullReferenceException in revertDeviceTaskToNone

Posted: Sat Jul 30, 2016 9:41 am
by Tomas
I have seen that a few times before actually when running HSQL (file based) database. Can you confirm if you are also running HSQL?

But you can actually ignore that exception, Unimus will continue working.
Currently, the database layer is being completely rewritten (will be released in the next release 0.2.0), it should be fixed after the rewrite.

Re: NullReferenceException in revertDeviceTaskToNone

Posted: Sun Jul 31, 2016 12:27 am
by X-Cubed
Yes, I'm running HSQL, and it doesn't appear to have any impact on the functionality, just thought I'd mention it.

Re: [Fixed in 0.2.0] NullReferenceException in revertDeviceTaskToNone

Posted: Tue Oct 25, 2016 6:29 am
by antoniosarco
The message "Object not set to instance of Object" means that you are trying to use an object which has not been initialized. That is, you either set it to null, or you never set it to anything at all. The runtime throwing a NullReferenceException always means the same thing: you are trying to use a reference. The reference is not initialized (or it was initialized, but is no longer initialized).

Antonio