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)" <ui...@incubator.apache.org> on 2008/11/25 17:57:44 UTC

[jira] Created: (UIMA-1237) Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step

Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step
------------------------------------------------------------------

                 Key: UIMA-1237
                 URL: https://issues.apache.org/jira/browse/UIMA-1237
             Project: UIMA
          Issue Type: Bug
          Components: Async Scaleout
            Reporter: Jerry Cwiklik


There is an exception when processing a secondary reply from a delegate in a parallel step. The exception indicates that the CAS id received in a reply message from one of the delegates in the parallel step does not exist in the cache. The exception happens in the testcase that tests disable of one of the delegates in the parallel step. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (UIMA-1237) Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step

Posted by "Jerry Cwiklik (JIRA)" <ui...@incubator.apache.org>.
     [ https://issues.apache.org/jira/browse/UIMA-1237?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jerry Cwiklik updated UIMA-1237:
--------------------------------

    Attachment: uimaj-as-core-UIMA-1237-patch-02.txt

> Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step
> ------------------------------------------------------------------
>
>                 Key: UIMA-1237
>                 URL: https://issues.apache.org/jira/browse/UIMA-1237
>             Project: UIMA
>          Issue Type: Bug
>          Components: Async Scaleout
>            Reporter: Jerry Cwiklik
>         Attachments: uimaj-as-core-UIMA-1237-patch-02.txt, uimaj-as-core-UIMA-1237-patch.txt
>
>
> There is an exception when processing a secondary reply from a delegate in a parallel step. The exception indicates that the CAS id received in a reply message from one of the delegates in the parallel step does not exist in the cache. The exception happens in the testcase that tests disable of one of the delegates in the parallel step. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (UIMA-1237) Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step

Posted by "Jerry Cwiklik (JIRA)" <ui...@incubator.apache.org>.
    [ https://issues.apache.org/jira/browse/UIMA-1237?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12651141#action_12651141 ] 

Jerry Cwiklik commented on UIMA-1237:
-------------------------------------

Added additional fix that may cause a hang. This fix handles a a race condition when two threads are processing replies from delegates in a parallel step. There is a chance than more than one thread is allowed to call invokeProcess() with the same CAS. Also, moved cancelTimer() to the top of handleProcessResponseFromRemoteDelegate() method to cancel timer immediately. Added synchronized method that determines if the thread should call invokeProcess(). Only one thread is allowed to call this now.  

> Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step
> ------------------------------------------------------------------
>
>                 Key: UIMA-1237
>                 URL: https://issues.apache.org/jira/browse/UIMA-1237
>             Project: UIMA
>          Issue Type: Bug
>          Components: Async Scaleout
>            Reporter: Jerry Cwiklik
>         Attachments: uimaj-as-core-UIMA-1237-patch-02.txt, uimaj-as-core-UIMA-1237-patch.txt
>
>
> There is an exception when processing a secondary reply from a delegate in a parallel step. The exception indicates that the CAS id received in a reply message from one of the delegates in the parallel step does not exist in the cache. The exception happens in the testcase that tests disable of one of the delegates in the parallel step. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (UIMA-1237) Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step

Posted by "Jerry Cwiklik (JIRA)" <ui...@incubator.apache.org>.
     [ https://issues.apache.org/jira/browse/UIMA-1237?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jerry Cwiklik updated UIMA-1237:
--------------------------------

    Attachment: uimaj-as-core-UIMA-1237-patch.txt

The "Cas Not In Cache" exception is caused by error handler removing CAS from the cache while handling exception that leads to a disable of a delegate in a parallel step. The Flow Controller is configured to not continue with the CAS therefore the CAS was being dropped. The secondary reply coming later, finds that the entry in the cache for the CAS id in the reply no longer exists. 

The code was modified to drop the CAS only if all replies are received from delegates in a parallel step. 

Also, since replies from delegates in parallel step may come in almost at the same time there is a race condition. One of the replies may contain an exception from one delegate while the other reply may contain good reply. Both of the replies go through reply handlers at the same time in different threads. Both decrement the number of delegates responded count associated with the parallel step. Now one of the threads (handling an exception) releases the CAS due to Flow Controller configuration. The other thread may try to lookup the entry in the cache using the if of the CAS just released. The "CAS Not In Cache" may be the result. Added code
silently handle this exception and treat it as stale reply. A message is logged at INFO level and the message is discarded.


> Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step
> ------------------------------------------------------------------
>
>                 Key: UIMA-1237
>                 URL: https://issues.apache.org/jira/browse/UIMA-1237
>             Project: UIMA
>          Issue Type: Bug
>          Components: Async Scaleout
>            Reporter: Jerry Cwiklik
>         Attachments: uimaj-as-core-UIMA-1237-patch.txt
>
>
> There is an exception when processing a secondary reply from a delegate in a parallel step. The exception indicates that the CAS id received in a reply message from one of the delegates in the parallel step does not exist in the cache. The exception happens in the testcase that tests disable of one of the delegates in the parallel step. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (UIMA-1237) Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step

Posted by "Jerry Cwiklik (JIRA)" <ui...@incubator.apache.org>.
     [ https://issues.apache.org/jira/browse/UIMA-1237?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jerry Cwiklik closed UIMA-1237.
-------------------------------

    Resolution: Fixed

> Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step
> ------------------------------------------------------------------
>
>                 Key: UIMA-1237
>                 URL: https://issues.apache.org/jira/browse/UIMA-1237
>             Project: UIMA
>          Issue Type: Bug
>          Components: Async Scaleout
>            Reporter: Jerry Cwiklik
>         Attachments: uimaj-as-core-UIMA-1237-patch-02.txt, uimaj-as-core-UIMA-1237-patch.txt
>
>
> There is an exception when processing a secondary reply from a delegate in a parallel step. The exception indicates that the CAS id received in a reply message from one of the delegates in the parallel step does not exist in the cache. The exception happens in the testcase that tests disable of one of the delegates in the parallel step. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (UIMA-1237) Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step

Posted by "Burn Lewis (JIRA)" <ui...@incubator.apache.org>.
    [ https://issues.apache.org/jira/browse/UIMA-1237?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12651151#action_12651151 ] 

Burn Lewis commented on UIMA-1237:
----------------------------------

Another way to do this that I think will be safe is to make the synchronized incrementHowManyDelegatesResponded() return a boolean when all have responded ... then only one thread will actually get the all-done flag.

> Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step
> ------------------------------------------------------------------
>
>                 Key: UIMA-1237
>                 URL: https://issues.apache.org/jira/browse/UIMA-1237
>             Project: UIMA
>          Issue Type: Bug
>          Components: Async Scaleout
>            Reporter: Jerry Cwiklik
>         Attachments: uimaj-as-core-UIMA-1237-patch-02.txt, uimaj-as-core-UIMA-1237-patch.txt
>
>
> There is an exception when processing a secondary reply from a delegate in a parallel step. The exception indicates that the CAS id received in a reply message from one of the delegates in the parallel step does not exist in the cache. The exception happens in the testcase that tests disable of one of the delegates in the parallel step. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (UIMA-1237) Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step

Posted by "Jerry Cwiklik (JIRA)" <ui...@incubator.apache.org>.
     [ https://issues.apache.org/jira/browse/UIMA-1237?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jerry Cwiklik updated UIMA-1237:
--------------------------------

    Fix Version/s: 2.3AS

> Fix "Cas Not Found In CasManager Cache" Error in the Parallel Step
> ------------------------------------------------------------------
>
>                 Key: UIMA-1237
>                 URL: https://issues.apache.org/jira/browse/UIMA-1237
>             Project: UIMA
>          Issue Type: Bug
>          Components: Async Scaleout
>            Reporter: Jerry Cwiklik
>             Fix For: 2.3AS
>
>         Attachments: uimaj-as-core-UIMA-1237-patch-02.txt, uimaj-as-core-UIMA-1237-patch.txt
>
>
> There is an exception when processing a secondary reply from a delegate in a parallel step. The exception indicates that the CAS id received in a reply message from one of the delegates in the parallel step does not exist in the cache. The exception happens in the testcase that tests disable of one of the delegates in the parallel step. 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.