You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@uima.apache.org by "Jerry Cwiklik (JIRA)" <de...@uima.apache.org> on 2018/10/01 20:06:00 UTC

[jira] [Created] (UIMA-5877) UIMA-DUCC: Pull service not failing fast on initialization error

Jerry Cwiklik created UIMA-5877:
-----------------------------------

             Summary: UIMA-DUCC: Pull service not failing fast on initialization error
                 Key: UIMA-5877
                 URL: https://issues.apache.org/jira/browse/UIMA-5877
             Project: UIMA
          Issue Type: Bug
          Components: DUCC
            Reporter: Jerry Cwiklik
            Assignee: Jerry Cwiklik
             Fix For: 2.2.3-Ducc


With multiple threads initializing, the protocol handler serializes call to processor.initialize() so that only one thread is allowed to initialize at a time.

If initialization fails the design goal is for the remaining threads to fail-fast if a previous thread failed. The check for error was in the wrong place in the DefaultServiceProtocolHandler.initialize(). Modify to do the check *after* a thread acquires a lock as in the below snippet:

try {
    // use a lock to serialize initialization one thread at a time
    initLock.lock();
    if (initError) {
        return;
    }
    processor.initialize();

...

 

 

 

 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)