[
https://issues.apache.org/jira/browse/UIMA-5877?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jerry Cwiklik closed UIMA-5877.
-------------------------------
Resolution: Fixed
Fails fast now
> 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
> Priority: Major
> 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)