Fix string index out of bounds exception calculating executor name when nested nodes executing on multiple threads
git-svn-id: http://svn.us.apache.org/repos/asf/tuscany@938129 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
4daf732a9b
commit
9a9d00ad2a
1 changed files with 1 additions and 2 deletions
|
@ -38,7 +38,6 @@ import org.apache.tuscany.sca.invocation.MessageFactory;
|
|||
import org.apache.tuscany.sca.runtime.DomainRegistryFactory;
|
||||
import org.apache.tuscany.sca.runtime.EndpointRegistry;
|
||||
import org.apache.tuscany.sca.runtime.ExtensibleDomainRegistryFactory;
|
||||
import org.oasisopen.sca.NoSuchServiceException;
|
||||
import org.oasisopen.sca.ServiceRuntimeException;
|
||||
import org.w3c.dom.Document;
|
||||
import org.w3c.dom.Node;
|
||||
|
@ -93,7 +92,7 @@ public class ReferenceInvoker implements Invoker {
|
|||
*/
|
||||
private ExecutorService getExecutorService() {
|
||||
String threadName = Thread.currentThread().getName();
|
||||
if (!threadName.startsWith("hz.executor.")) {
|
||||
if (!threadName.startsWith("hz.executor.") || threadName.indexOf("binding.sca.") == -1) {
|
||||
return hzRegistry.getHazelcastInstance().getExecutorService("binding.sca.1");
|
||||
} else {
|
||||
String oldName = threadName.substring(threadName.lastIndexOf("binding.sca."), threadName.lastIndexOf(".thread-"));
|
||||
|
|
Loading…
Add table
Reference in a new issue