Hi all,
I'm calling a Service by using the returnData method in a model. This service performs a long background task.
While this task is running, it seems that no other wave is processed. Once the ServiceTask is done, the pending waves are processed.
Here are the relevant stacktraces:
The ServiceTask running in the JTP:
JTP Slot 2@1716 daemon, prio=5, in group 'main', status: 'RUNNING'
at com.dooapp.dsdk.component.loading.Service1.doIt(Service1.java:38)
at sun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethodAccessorImpl.java:-1)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.jrebirth.core.service.ServiceTask.call(ServiceTask.java:126)
at javafx.concurrent.Task$TaskCallable.call(Task.java:1259)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)
The JIT waiting for the ServiceTask to be done (by a blocking call to FutureTask.get()
JIT@812 daemon, prio=5, in group 'main', status: 'WAIT'
at sun.misc.Unsafe.park(Unsafe.java:-1)
at java.util.concurrent.locks.LockSupport.park(LockSupport.java:186)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.parkAndCheckInterrupt(AbstractQueuedSynchronizer.java:834)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.doAcquireSharedInterruptibly(AbstractQueuedSynchronizer.java:994)
at java.util.concurrent.locks.AbstractQueuedSynchronizer.acquireSharedInterruptibly(AbstractQueuedSynchronizer.java:1303)
at java.util.concurrent.FutureTask$Sync.innerGet(FutureTask.java:248)
at java.util.concurrent.FutureTask.get(FutureTask.java:111)
at org.jrebirth.core.concurrent.JRebirthThread.runIntoJTP(JRebirthThread.java:117)
at org.jrebirth.core.concurrent.JRebirth.runIntoJTP(JRebirth.java:117)
at org.jrebirth.core.service.AbstractService.runTask(AbstractService.java:134)
at org.jrebirth.core.service.AbstractService.returnData(AbstractService.java:95)
at org.jrebirth.core.link.NotifierBase.returnData(NotifierBase.java:139)
at org.jrebirth.core.link.NotifierBase.sendWave(NotifierBase.java:86)
at org.jrebirth.core.link.AbstractWaveReady$3.runInto(AbstractWaveReady.java:207)
at org.jrebirth.core.concurrent.AbstractJrbRunnable.run(AbstractJrbRunnable.java:56)
at org.jrebirth.core.concurrent.JRebirthThread.run(JRebirthThread.java:202)
This is not the behavior that I would expect. I thought that the JIT would be running and processing waves while a Service is running, is this right?
I'm I doing something wrong to when calling the Service?
Regards,
--
Antoine Mischler