[
https://issues.jboss.org/browse/ISPN-2717?page=com.atlassian.jira.plugin....
]
Galder Zamarreño commented on ISPN-2717:
----------------------------------------
Anna, are you sure about this? If the executable is invoked locally, any throwable should
be logged:
https://github.com/infinispan/infinispan/blob/master/core/src/main/java/o...
Even if the execution is remote, logging happens:
https://github.com/infinispan/infinispan/blob/master/core/src/main/java/o...
That test does not wait for the execution to finish, so it could happen that the JVM stops
before it's executed the code and it's printed the exception.
Rejecting this for the moment until more proof is provided on the existence of a bug.
execute(Runnable) of DistributedExecutorService doesn't show
exception message in case of failure of Runnable
-------------------------------------------------------------------------------------------------------------
Key: ISPN-2717
URL:
https://issues.jboss.org/browse/ISPN-2717
Project: Infinispan
Issue Type: Bug
Components: Distributed Execution and Map/Reduce
Affects Versions: 5.2.0.CR2
Reporter: Anna Manukyan
Assignee: Galder Zamarreño
Fix For: 5.2.0.Final
Assume, that we have a runnable which run() method throws RuntimeException.
In case if the runnable is executed using void execute(Runnable command) for
DistributedExecutorService, the execution of runnable fails - but there is no any
stacktrace printed in the logs.
So it is really hard to find, what was wrong in your Runnable.
The sample test which does this is:
{code}
public void testRunnableExecution() throws InterruptedException {
//assuming cache initialization is done
DistributedExecutorService des = new DefaultExecutorService(cache);
SampleRunnable runnable = new SampleRunnable();
des.execute(runnable);
}
static class SampleRunnable implements Runnable, Serializable {
public SampleRunnable() {
}
@Override
public void run() {
System.out.println("Running runnable");
int i = 5 / 0;
}
}
{code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:
http://www.atlassian.com/software/jira